From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jiri Pirko Subject: Re: [patch net-next v2 00/20] net: sched: convert cls ndo_setup_tc offload calls to per-block callbacks Date: Fri, 27 Oct 2017 09:27:30 +0200 Message-ID: <20171027072730.GB1980@nanopsycho.orion> References: <20171019135048.4306-1-jiri@resnulli.us> <20171021.030446.967534081159629805.davem@davemloft.net> <20171025121503.GA1910@nanopsycho> <2e4baa66-35e3-0259-6228-ab05ec826345@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Cc: Alexander Duyck , David Miller , Netdev , Jamal Hadi Salim , Cong Wang , mlxsw@mellanox.com, Andrew Lunn , Vivien Didelot , Florian Fainelli , Michael Chan , Ganesh Goudar , Jeff Kirsher , Saeed Mahameed , Matan Barak , Leon Romanovsky , idosch@mellanox.com, Jakub Kicinski , Alexei Starovoitov , Daniel Borkmann , Simon Horman , To: "Nambiar, Amritha" Return-path: Received: from mail-wr0-f180.google.com ([209.85.128.180]:51839 "EHLO mail-wr0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752230AbdJ0H1c (ORCPT ); Fri, 27 Oct 2017 03:27:32 -0400 Received: by mail-wr0-f180.google.com with SMTP id j15so5312349wre.8 for ; Fri, 27 Oct 2017 00:27:32 -0700 (PDT) Content-Disposition: inline In-Reply-To: <2e4baa66-35e3-0259-6228-ab05ec826345@intel.com> Sender: netdev-owner@vger.kernel.org List-ID: Thu, Oct 26, 2017 at 10:24:31PM CEST, amritha.nambiar@intel.com wrote: >On 10/25/2017 5:15 AM, Jiri Pirko wrote: >> Tue, Oct 24, 2017 at 06:01:34PM CEST, alexander.duyck@gmail.com wrote: >> >> [...] >> >>> 1. To offload filter into HW, the hw-tc-offload feature flag has >>> to be turned on before creating the ingress qdisc. >>> >>> Previously, this could also be turned on after the qdisc was created >>> and the filters could still be offloaded. Looks like this is because, >>> previously the offload flag was checked as a part of filter >>> integration in the classifier, and now it is checked as part of qdisc >>> creation (ingress_init). So, if no offload capability is advertised at >>> ingress qdisc creation time then hardware will not be asked to offload >>> filters later if the flag is enabled. >> >> I have patchset that fixes this in my queue now. Will do some smoke >> testing and send later today. >> >> >>> >>> 2. Deleting the ingress qdisc fails to remove filters added in >>> HW. Filters in SW gets deleted. >>> >>> We haven’t exactly root-caused this, the changes being extensive, but >>> our guess is again something wrong with the offload check or similar >>> while unregistering the block callback (tcf_block_cb_unregister) and >>> further to the classifier (CLS_U32/CLS_FLOWER etc.) with the >>> DESTROY/REMOVE command. >> >> Hmm. How does this worked previously. I mean, do you see change of >> behaviour? I'm asking because I don't see how rules added only to HW >> could be removed, driver should care of it. Or are you talking about >> rules added to both SW and HW? > >These are rules added to both SW and HW. Previously all cls_* had >ndo_setup_tc calls based on the offload capability. > >commit 8d26d5636d "net: sched: avoid ndo_setup_tc calls for >TC_SETUP_CLS*" removed this bit to work with the new block callback. Is >there something similar in the block callback flow while acting on the >tcf_proto destroy call initiated when the qdisc is cleared? Yes, it is the same.