From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8C39C271FD for ; Tue, 16 May 2023 21:50:11 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C0371C433EF; Tue, 16 May 2023 21:50:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684273811; bh=yKkl+O+uwemVUkRqo3YT8W36ra+vpuQRbPNcizoUogE=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=fVWIMxwdFdnveGr0Eu1f+wb2bNaPbs0KhmFzgzLq704feoxQL0vucOiJjQUONdpmh dr5/MV75n/TuMO2OihaPfcn6cHE3Zg14Ap7UpvvBRVeMGp4CmsDRBcukl8yGM5TaKA azfMmCrsroyXZ+oM6Tjw2puCtKmyBqgvdXnDdz9ssNWjBi5C8CFXHoHUXspB2u/30V FCwN5x41wuOa42vanctEHH1taIIVqRcBkSC5wLJuTzAFCwc16RaNESgkKG+c+NxMTT /9R4ylh9qWb8PHSXVoM2CfA/hGw41Eo2q1k4zeCbBJUKGsr7YaZUr9WjEamy3Vkujb UrEvX4+wuO1qQ== Date: Tue, 16 May 2023 14:50:10 -0700 From: Jakub Kicinski To: Vlad Buslov Cc: Peilin Ye , Jiri Pirko , "Daniel Borkmann" , "David S. Miller" , Eric Dumazet , Paolo Abeni , "Jamal Hadi Salim" , Cong Wang , "Peilin Ye" , John Fastabend , Pedro Tammela , Hillf Danton , , , Cong Wang Subject: Re: [PATCH net 6/6] net/sched: qdisc_destroy() old ingress and clsact Qdiscs before grafting Message-ID: <20230516145010.67a7fa67@kernel.org> In-Reply-To: <87y1lojbus.fsf@nvidia.com> References: <20230508183324.020f3ec7@kernel.org> <20230510161559.2767b27a@kernel.org> <20230511162023.3651970b@kernel.org> <20230516122205.6f198c3e@kernel.org> <87y1lojbus.fsf@nvidia.com> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Tue, 16 May 2023 22:35:51 +0300 Vlad Buslov wrote: > > Vlad, could you please clarify how you expect the unlocked filter > > operations to work when the qdisc has global state? > > Jakub, I didn't account for per-net_device pointer usage by miniqp code > hence this bug. I didn't comment on the fix because I was away from my > PC last week but Peilin's approach seems reasonable to me. When Peilin > brought up the issue initially I also tried to come up with some trick > to contain the changes to miniqp code instead of changing core but > couldn't think of anything workable due to the limitations already > discussed in this thread. I'm open to explore alternative approaches to > solving this issue, if that is what you suggest. Given Peilin's investigation I think fix without changing core may indeed be hard. I'm not sure if returning -EBUSY when qdisc refcnt is elevated will be appreciated by the users, do we already have similar behavior in other parts of TC?