Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp948787ybx; Tue, 5 Nov 2019 08:01:21 -0800 (PST) X-Google-Smtp-Source: APXvYqxDxc7LZ9igxXaJemzSjdk0+XUV/A15xuNkK/cqLd7AQlOnQW8eIx4xXnTPrBOOFkK4sRW8 X-Received: by 2002:adf:dbd2:: with SMTP id e18mr28911901wrj.268.1572969681241; Tue, 05 Nov 2019 08:01:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1572969681; cv=none; d=google.com; s=arc-20160816; b=vKRipyuR9jo7r6i4PYdHxfW3V7+pRLPCg7tzoKEu29DnvZ5lviN9iDx/LT2lxynekm qhToQP7wJb3jUQrpPK9MP11rMvCUlPZNHfDnMOl5qLZORtSNouDzuKb9UMb5FVNCyUz0 2HWNxYdGkR/l1i8eA7+e1rpfO0jPiFFtFNz5u3o2t0/t/padJvIANOEF/GE5+aYbyUM3 Dnfl3nBYOLki23BkHcvGIZQHHU+J6ddG1nQAS5hBUjJnBpWneZutm6/TBhIB3OBxTqxl jb9QsRZtv7/0AarjKhHGeHAhpAQRJjs0eMF30UpWDCRgEtc6JvweukMPiZYoLSSNTGgj IPBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=M6wh6jqbqRIdXmd1bC6JTsPk8LafWc1uYKqnOR4Fy6w=; b=LbzUpJ7IEFGuDTqnqYR8nZMyZQElpCXt8fyRJVNwHdrM1fdI1KMj5WftPBuzZObqTl +cWldK6DU1KzI6JIxMo8C9lptx2ECwU1kok7LKXXZHEzFbdvDE0UU7A4UNNE7OEMtuE9 xffgGzN+o7ld/IogGACEM4kjhIx/XGzXpQReahEC7h6k4L99CpUupIQrpF2A/ftJCtTZ dahi1W+Le/rSRCV0x73lBgxpThFTurOO6/IOAfvSt60IOU1tssdrmr13m1lTPTZn3cBr JSKW8FZopiKWen6WfkHyYmA4AmyUf4GugJI5vl7d/zwtahD9Dj45yHo1gxX3ulEB+czq 9Arg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@lunn.ch header.s=20171124 header.b=td+Wxj2i; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b9si10167540eda.115.2019.11.05.08.00.55; Tue, 05 Nov 2019 08:01:21 -0800 (PST) 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=fail header.i=@lunn.ch header.s=20171124 header.b=td+Wxj2i; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390001AbfKEQAC (ORCPT + 99 others); Tue, 5 Nov 2019 11:00:02 -0500 Received: from vps0.lunn.ch ([185.16.172.187]:49982 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389843AbfKEQAB (ORCPT ); Tue, 5 Nov 2019 11:00:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=M6wh6jqbqRIdXmd1bC6JTsPk8LafWc1uYKqnOR4Fy6w=; b=td+Wxj2iB7RRCP2UQiQYGq7A1c bLgegAl+A9wVz1p4HProK0kUYgUOjXga0p2LWvgYRFh1zvj1ELRlUd/Fb6+5xyqnLlMRstLAm3MaK C40gV1/wsZdUw6wQhPGda/PD0CHAR8JlUSKweWNkcqGNK+OmSGSopZ2r3lTCohXy+9Do=; Received: from andrew by vps0.lunn.ch with local (Exim 4.92.2) (envelope-from ) id 1iS1FK-0002fM-Fe; Tue, 05 Nov 2019 16:59:54 +0100 Date: Tue, 5 Nov 2019 16:59:54 +0100 From: Andrew Lunn To: Ioana Ciornei Cc: "gregkh@linuxfoundation.org" , "linux-kernel@vger.kernel.org" , "f.fainelli@gmail.com" Subject: Re: [PATCH 06/12] staging: dpaa2-ethsw: add ACL entry to redirect STP to CPU Message-ID: <20191105155954.GE17620@lunn.ch> References: <1572957275-23383-1-git-send-email-ioana.ciornei@nxp.com> <1572957275-23383-7-git-send-email-ioana.ciornei@nxp.com> <20191105142202.GC7189@lunn.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > The control queues do not form an actual interface in the sense that > the CPU does not receive unknown unicast, broadcast and multicast > frames by default. For each frame that we want to direct to the CPU > we must add an ACL entry. So this appears to be one of the dumbest switches so far :-( Can you add an ACL which is all L2 broadcast/multicast? That would be a good first step. Does the ACL stop further processing of the frame? Ideally you want the switch to also flood broadcast/multicast out other ports, if they are in a bridge. If it cannot, you end up with the software bridge doing the flooding. So i also assume it does not perform learning on CPU frames? That probably means you need to connect up the fdb add/remove calls to add in ACLs. And you will need to implement ndo_set_rx_mode. Each unicast and multicast address needs to be turned into an ACL. What i don't know is if the network stack will automatically add the interfaces own MAC address. You might have to handle that special case. Andrew