Received: by 2002:a05:6358:53a8:b0:117:f937:c515 with SMTP id z40csp3505819rwe; Sun, 16 Apr 2023 22:02:37 -0700 (PDT) X-Google-Smtp-Source: AKy350aB7Gz4j/rWyhsIBVP8IHNLO6xUePmUUbWARxN5sRh6bF1YOWYtYmcrVLmsfudaJujP9xg/ X-Received: by 2002:a17:903:32c2:b0:1a6:a375:cb49 with SMTP id i2-20020a17090332c200b001a6a375cb49mr12250154plr.39.1681707757383; Sun, 16 Apr 2023 22:02:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681707757; cv=none; d=google.com; s=arc-20160816; b=mm5x6pKenXHI7/6rCN/KI6zuZEEvhWj0Aai9WB8MAQTCC5dta3FqwmdifLp80lp4YD WynAEMIZ3W9BmhwQAxlRFsjCCN/BOnTw+ssTb4ACgl8WfLZCATZBbdqE5+t08VAcGZOM X1Qh2tg4d0tsR3MCIj45AK5YBzgYmmHMJSFcgKqU9XQRW8WVNlroq0PNXNVnccMjSIPs /9w9q+VQo7P+7GjV5mDV+XoH3rluaYb1qVhuChQR9dBumbY2Xjcp5/SjYQD5IdsHd+yl DOsJT7R+1bobOPCubja1G/KgGzD+sJDeqX1gf9e0FJdyENOxsngZQL62olcwIPxJt+Vp JBRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=Gn2qzGuJvKgB83alcAXNhF5Xu6Z5ZDX3NIKSo3GZRAs=; b=w8mUr6XRcC3qYT1AczJ0dMEC3IBGYo2z+pngtcSulnFbtKxpQSF/Rn1gnBQMceMJgU E9qOTRzwtnbLr7MhgETMjPer2O8rGTfBFI+XmtowApCOPchK+HJQjY2ZiNUuiTApbMDC ezsc3xvAqNDEk4A6ouYMeitrx0ooL4+HhJ0F+FXwww/iRLsqKhXVjd7wqUh5mhjWiLWz 1LYlLjcS5tosC+lCShb57nAdkYn++9TNYBdfSOi4cSKOEtN+NN13r5w0QJp2cZmTONsD bhgKGyDCQqgeDmf1voDqyxUK9afKvkTv6eVNek3MktZ2Ih8gEPcnOexWTge/xlYOGIdl jTbw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ij30-20020a170902ab5e00b001a66c2f479asi10234355plb.219.2023.04.16.22.02.19; Sun, 16 Apr 2023 22:02:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229838AbjDQE52 (ORCPT + 99 others); Mon, 17 Apr 2023 00:57:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45168 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229717AbjDQE51 (ORCPT ); Mon, 17 Apr 2023 00:57:27 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C0C2C2D69 for ; Sun, 16 Apr 2023 21:57:25 -0700 (PDT) Received: from ptx.hi.pengutronix.de ([2001:67c:670:100:1d::c0]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1poGvQ-0003PV-EK; Mon, 17 Apr 2023 06:57:12 +0200 Received: from ore by ptx.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1poGvO-0006SM-Ob; Mon, 17 Apr 2023 06:57:10 +0200 Date: Mon, 17 Apr 2023 06:57:10 +0200 From: Oleksij Rempel To: Vladimir Oltean Cc: "David S. Miller" , Andrew Lunn , Eric Dumazet , Florian Fainelli , Jakub Kicinski , Paolo Abeni , Woojung Huh , Arun Ramadoss , kernel@pengutronix.de, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, UNGLinuxDriver@microchip.com Subject: Re: [PATCH net-next v1 2/2] net: dsa: microchip: Add partial ACL support for ksz9477 switches Message-ID: <20230417045710.GB20350@pengutronix.de> References: <20230411172456.3003003-1-o.rempel@pengutronix.de> <20230411172456.3003003-1-o.rempel@pengutronix.de> <20230411172456.3003003-3-o.rempel@pengutronix.de> <20230411172456.3003003-3-o.rempel@pengutronix.de> <20230416165658.fuo7vwer7m7ulkg2@skbuf> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20230416165658.fuo7vwer7m7ulkg2@skbuf> X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-Accept-Language: de,en X-Accept-Content-Type: text/plain User-Agent: Mutt/1.10.1 (2018-07-13) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c0 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Vladimir, On Sun, Apr 16, 2023 at 07:56:58PM +0300, Vladimir Oltean wrote: > Hi Oleksij, > > I only took a superficial look, and hence, here are some superficial comments. > > On Tue, Apr 11, 2023 at 07:24:55PM +0200, Oleksij Rempel wrote: > > The ACL also implements a count function, generating an interrupt > > instead of a forwarding action. It can be used as a watchdog timer or an > > event counter. > > Is the interrupt handled here? I didn't see cls_flower_stats(). No, it is not implemented in this patch. It is generic description of things ACL should be able to do. Is it confusing? Should I remove it? > > The ACL consists of three parts: matching rules, action > > rules, and processing entries. Multiple match conditions can be either > > AND'ed or OR'ed together. > > > > This patch introduces support for a subset of the available ACL > > functionality, specifically layer 2 matching and prioritization of > > matched packets. For example: > > > > tc qdisc add dev lan2 clsact > > tc filter add dev lan2 ingress protocol 0x88f7 flower skip_sw hw_tc 7 > > > > tc qdisc add dev lan1 clsact > > tc filter add dev lan1 ingress protocol 0x88f7 flower skip_sw hw_tc 7 > > Have you considered the "skbedit priority" action as opposed to hw_tc? I had already thought of that, but since bridging is offloaded in the HW no skbs are involved, i thought it will be confusing. Since tc-flower seems to already support hw_tc remapping, I decided to use it. I hope it will not harm, to use it for now as mandatory option and make it optional later if other actions are added, including skbedit. Regards, Oleksij -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |