Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp5658379ybl; Tue, 27 Aug 2019 07:56:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxyBTs4UMtEEZbt1MH/SLKqkXVuNpUiNCYBPGWtvV8PRWtVfMr6QoSDvLFpDV3pEEqQnv+k X-Received: by 2002:a17:902:3204:: with SMTP id y4mr25265489plb.156.1566917805131; Tue, 27 Aug 2019 07:56:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566917805; cv=none; d=google.com; s=arc-20160816; b=OM08hFSQxUw/XZQ9Pl3rPuwwq6vfm2jQ/GXWH8Tlf/F9cyMr1+6CJmQ6O+O8Bx3CKn mJXRDm/jcUTGLHvU+6H6rZFmOxNWCs2dCZRcJ9kZt/e3iAE9JbWkDHpwR7QI3kSf70cI DdNOZ4PeeqYy9jxyYnpScN2icDznHEGXloj62AB0kbaZPJokGfYamwnrKQ2Jw3w4zX+Y CdRnsjMqNOHmsNA2P3Oy1HdcuuD+/Fk3Fd4YhhKx/vdS1I0rIuFFt9f0vlB/nG3faowq vPE8wy1xg68uiYZ86BavRfv++VZfycxl9ylpEr0sLTQiqV1a24zehMXXNW3t/sGit4C9 KB2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=J28up6uPKD34qaYuEApixR8UwpIcwgN+tKjvn/kdwk8=; b=yi0mRmnVslegRJp6vx234/sfsMoOd0m2NFn6NkLgrNJ0BBXwbpngSfwea9xjRWY5OR Y4ERJiTnOIdL9TyRKm0zoxHeAistWNud1zO9Qzey06zst6JAyQZLw5RoTCV2UxULha1L 3bB3g8Z1Wp+1Qkvtj9fnmwwTWDxIRRn/FqP0ae/TefldEpMHC+6rfyykM6dxOmUvUXdj EuQ96H7tokB+JQuvdiK0RuD/HV4wvj8cnn0X78SFIWPrCfhIC/cu6Ra/ojX6C6Ut0kTV U+8YGpexJ/2CXN6wviVpg79oAnaUNOzy7fDdt2LGsg1tkeGqHKhBcSYGwxVJzHeFKaJs tHvg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=pMVrBsv0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u6si13789221pfm.135.2019.08.27.07.56.29; Tue, 27 Aug 2019 07:56:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=pMVrBsv0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730184AbfH0OzO (ORCPT + 99 others); Tue, 27 Aug 2019 10:55:14 -0400 Received: from mail-ed1-f67.google.com ([209.85.208.67]:38925 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727089AbfH0OzO (ORCPT ); Tue, 27 Aug 2019 10:55:14 -0400 Received: by mail-ed1-f67.google.com with SMTP id g8so31761913edm.6; Tue, 27 Aug 2019 07:55:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=J28up6uPKD34qaYuEApixR8UwpIcwgN+tKjvn/kdwk8=; b=pMVrBsv09u5KWA+6vj2Cr0qR0GSZe6r8BMU1JSA+mY2m8bDJ+IdYJXV+hJDfmP273h 03KsR0CTQqVWzTM8EllBHW37q99IulCpwRlLntm1wh7QpBeheqcUWjdGcF92vEjKdwGe JWg1stYWqsmHKwaAOkhxXnI4at6LB104kKnM4BFKCBSqOUYTlJLleTaPM+cWFcES1i88 zXTO9JvkAZyanLSswiDgGLU/w5Lg9OUsu2V4nZRlg9a47CKLJgik6d2SfwFNb8UzzLdP TduGiWMz2vDnqLl/Tjwin5PPv0YyzSGJtEK4Qh0lsI17GPFMi0jTeoxn4o37yhTPsYs/ Yajw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=J28up6uPKD34qaYuEApixR8UwpIcwgN+tKjvn/kdwk8=; b=ZqxUsczPBiPFBMK5XZlZPVniX1hsWyMq3pzntgIbxB1hH70yGkODme5tXDJbS87Y4o U93W3dBXWldkcqz8tiNYJMuitURVfOu3xgfA2NwbSVQXN+Mi8c31DNSUdIhEna4dRbaX OfChr0VM6VtAsXFaAZezwiGIgky0HT6xwhLnXt8pHDaXs7d95ZTrW9bDXHajhc2jQZ05 heCOI74UlRmC5NgLNPAf7c/uc4ezQf/PxdJ8BQLXeFYxA4K5NNK/2kE3qvkC7i5e0VpR IDtj8qpeqN7JwaOL7lDjSkQoptYJSKqauEjQs0xku0/xyRFhgbfcyS6mZoqAs0Gr2Nii lecg== X-Gm-Message-State: APjAAAUtey+eXkR7Iq91j9H48jW3SvqmodP63Iqf2SZo42Tp55DI00iM uWiyKDEZAspKhCoOGVvvrxo0Pku9xcGPH1DnbhQ= X-Received: by 2002:a17:906:9607:: with SMTP id s7mr21872991ejx.300.1566917712168; Tue, 27 Aug 2019 07:55:12 -0700 (PDT) MIME-Version: 1.0 References: <1566807075-775-1-git-send-email-horatiu.vultur@microchip.com> <20190826123811.GA13411@lunn.ch> <20190827101033.g2cb6j2j4kuyzh2a@soft-dev3.microsemi.net> <20190827131824.GC11471@lunn.ch> In-Reply-To: <20190827131824.GC11471@lunn.ch> From: Vladimir Oltean Date: Tue, 27 Aug 2019 17:55:00 +0300 Message-ID: Subject: Re: [PATCH v2 0/3] Add NETIF_F_HW_BR_CAP feature To: Andrew Lunn Cc: Horatiu Vultur , Roopa Prabhu , nikolay@cumulusnetworks.com, "David S. Miller" , UNGLinuxDriver@microchip.com, Alexandre Belloni , "Allan W. Nielsen" , Florian Fainelli , netdev , lkml , bridge@lists.linux-foundation.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 27 Aug 2019 at 16:20, Andrew Lunn wrote: > > > That sounds like a great idea. I was expecting to add this logic in the > > set_rx_mode function of the driver. But unfortunetly, I got the calls to > > this function before the dev->promiscuity is updated or not to get the > > call at all. For example in case the port is member of a bridge and I try > > to enable the promisc mode. > > Hi Horatiu > > What about the notifier? Is it called in all the conditions you need > to know about? > > Or, you could consider adding a new switchdev call to pass this > information to any switchdev driver which is interested in the > information. > > At the moment, the DSA driver core does not pass onto the driver it > should put a port into promisc mode. So pcap etc, will only see > traffic directed to the CPU, not all the traffic ingressing the > interface. If you put the needed core infrastructure into place, we > could plumb it down from the DSA core to DSA drivers. > > Having said that, i don't actually know if the Marvell switches > support this. Forward using the ATU and send a copy to the CPU? What > switches tend to support is port mirroring, sending all the traffic > out another port. A couple of DSA drivers support that, via TC. > But the CPU port is not a valid destination for port mirroring in DSA, I might add. > Andrew Regards, -Vladimir