🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #23151

Re: [PATCH net v4] octeontx2-af: Fix BPID leaks in NIX backpressure enable/disable

#23151
From: Simon Horman
Date: Thu, 26 Nov 2026 15:22
31 lines
9198 bytes
On Mon, Nov 23, 2026 at 09:08:58AM +0000, netdev-bot+sashiko@kernel.org wrote:
> Thank you for your contribution! Sashiko AI review found 5 potential
> issue(s) to consider.
> 
> Critical: 0 · High: 1 · Medium: 3 · Low: 1
> 
> If you believe none of the issues are legitimate, please reply to each
> issue of Medium severity or higher and explain why the AI is wrong.
> If any of them are legitimate and you plan to respin, please let patchwork
> know by including "pw-bot: cr" as a separate line at the end of your reply
> (one such reply per series is enough).
> 
> - [High] The new channel range checks in nix_bp_disable()
>   (rvu_nix.c:672-677) and nix_bp_enable() (rvu_nix.c:822-827) validate…
> - [Medium] nix_bp_enable() (rvu_nix.c:832-857) still leaks an LBK BPID
>   whenever NIX_BP_ENABLE or NIX_CPT_BP_ENABLE is sent for a channel that…
> - [Medium] nix_bp_chan_disable() (rvu_nix.c:624-639) passes 'cfg &
>   GENMASK_ULL(8, 0)' to nix_bp_free_lbk_bpid() without checking that…
> - [Medium] nix_bp_enable() now saves each allocated BPID in
>   rsp->chan_bpid[i] (line 844) and later reads it back from rsp to…
> - [Low] The commit message undersells one of the problems this patch
>   fixes.

The above concerns look legit to me, especially the mailbox TOCTOU and the
BPID lifetime issues.

-- 
pw-bot: changes-requested

...
Technical Details
Message-ID: <20261126152221.GC31322@horms.kernel.org>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372198-linux-kernel-netdev=dewy.ru
References: <20261119085434.2598197-1-nshettyj@marvell.com> <179542493892.3135.7516887793037759713@kernel.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372198-linux-kernel-netdev=dewy.ru
From: horms@kernel.org (Simon Horman)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net v4] octeontx2-af: Fix BPID leaks in NIX backpressure
 enable/disable
Date: Thu, 26 Nov 2026 15:22:21 +0000
Organization: Usenet Network
Message-ID: <20261126152221.GC31322@horms.kernel.org>
References: <20261119085434.2598197-1-nshettyj@marvell.com>
 <179542493892.3135.7516887793037759713@kernel.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="496005"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:lx/OwnzwkRkRsNWRO2ipIR1ZDU8= sha256:n6pAM92TFUJXqrWr5oRYW+rdt1uk9d4gFoJShNKCx3o=
	sha1:NOXq14FSPhdWKIwNUfanQ0fr7Kg= sha256:uUuK5DVcE46i8gfiAHK1MBwvae9lUvxczC3CRbD4GF8=
Content-Disposition: inline
List-ID: <netdev.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
	by mail.dewy.ru (Postfix) with ESMTP id 895FB125EE3; Thu, 26 Nov 2026 18:22:43 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.401
X-Spam-Status: No, score=-3.401 tagged_above=-9999 required=6.31
	tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1,
	DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
	MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
	SPF_PASS=-0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
	header.d=kernel.org
X-Received: from mail.dewy.ru ([127.0.0.1])
	by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id iuEce3hJ9WNh;
	Thu, 26 Nov 2026 18:22:40 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-372198-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id 06300125EDC; Thu, 26 Nov 2026 18:22:30 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sea.lore.kernel.org (Postfix) with ESMTP id 9BA24313A3; Thu, 26 Nov 2026 15:22:27 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
	t=1795706547;
	b=cZd+6TbwvZdCUEBik6MEBNCVxaV/Uvj3Y9ACNUbIONbxoZjeEGLl7UbiMVfhZ4Sp2v3f
	 rX8AOQ0c/tlA834GrF2cO+oI0SkYUadO3jR+Q+LltWGrZZpq3TeEJsrz3TlXjaXK2J6E3
	 d2/7z8/NTJ4/m+OCd/XpZ0zgvJ7wdpchRW5PNojJF1xWZAb7ghiHdsXgSaie1CYe3S7Ss
	 hbBpWIwib7XVt7ps7RA9MopfCVxQli3syHgxrSAhuetxoZ2LZxwJYYEoL3OwtyYD4aqnD
	 YzpRDQl1hBjCsrd5CtbMZMr626OQ2QZqpufpJeUhyJkbsuPea3RcMNKMeUhzsI/3KLQ==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795706547;
	h=X-Original-To:Received:Received:DKIM-Signature:Date:From:To:Cc:
	 Subject:Message-ID:References:X-Mailing-List:List-Id:List-Post:
	 List-Help:List-Subscribe:List-Unsubscribe:List-Owner:Precedence:
	 MIME-Version:Content-Type:Content-Disposition:
	 Content-Transfer-Encoding:In-Reply-To;
	bh=VpEu+mJf+gvKieDmE+OajqJCgi0lHVmWfASEOdaIKk8=;
	b=CeCRoUW/PN2MuBD6S3w6ovQXYd2xAyjmSUn4t2vMs2lRsPhngDpjGsEy93o9g/d6qtKo
	 S/LT/UFBI2JYIrfdUqSeMKH2lVCUemwVeQ5qabaVFJYJoIJAxDCeZ3qh3CyyJPFN1pMLI
	 RT5k43eypJdk4r7KGYTx5DxVqKQjEU+aHqNDEj5UKNjIIwpyEIiJ85CXleho6JNK6co5D
	 6jA0po5I+c5dAc08UUL4/6EcZjKvJVykTuV4TsUv4c/Rw/MD0L34OBnqgmlvefZBujy8+
	 vt8lzRpqFVGwWDNI9CdMY2O+uYGMbSR43PmS9fqyRyEZ2SuBWicFNQaTyNh36IwM0QQ==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OEc9OpLr;
	arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
	by smtp.subspace.kernel.org (Postfix) with ESMTP id 73D61606A330;
	Thu, 26 Nov 2026 15:22:27 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OEc9OpLr
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1795706546;
	b=32veDFKiik4iqvrYkHw9bDGPblfQIoheIAlYBNRecVUK/s6eMaNpSSOBuQkm+03dJU1V
	 F/VUZ586NKSgz30wkLbkAaAKqcjRUKrDQGHByA0RmDL9jcP5eppK7I8p/0Tin1Qt9/u4j
	 vPar/G0Rs4JnMu+J0BQqJFSFKTf3Y9R4DjUBwpDSKm1Sey7IqC3gY2gRobrQ2+/9itGbz
	 Sf4K9E608OkWOm5M1q4KIkbZzxsfVDlmUsE6LP19wMwDzaCHqrblCLKbC/UJtMchjLC+q
	 9/hf0RhdQx4va7mghuyVlaPUUUPdFfHnnsW3245A3gMkPbcv3RiLT3IyXHCPvD+QXZQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795706546;
	h=Received:DKIM-Signature:Date:From:To:Cc:Subject:Message-ID:
	 References:MIME-Version:Content-Type:Content-Disposition:
	 Content-Transfer-Encoding:In-Reply-To;
	bh=VpEu+mJf+gvKieDmE+OajqJCgi0lHVmWfASEOdaIKk8=;
	b=hOq1hWKyW/i8ZzWF06F/qfnCQN6bCUEOoGUYXUMNOKPTd3biWDGDEAfHzjZSoQRFanMu
	 Q8RpQLQcAYtbEprvuon3kYzInZmlEgx5WUpfmmY35zR8FvLSu8e6AwyvKYK7295t6XHc4
	 qpSn5ndGazcYLkW9i0XwcTVl7UDNAXUYN5zaYriWanfEkeJPdvbvtLx2NFZWWTR89WhYS
	 GoX1PBupjPaZpTgQbzeqTRm8eJQuitVTqDVqS9hsyigQniLfVY4MYDoKemq+hZEgjM0KG
	 2WwvCrI8s0c25E5VVfJxO5RK0sTqVJfwUB8sGzybIlsNW1+y/vw0X/TNIJ1bUQRZm1Q==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=OEc9OpLr;
	arc=none smtp.remote-ip=100.103.45.18
X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1))
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9068D606A31C;
	Thu, 26 Nov 2026 15:22:26 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id E89BB1F000CA;
	Thu, 26 Nov 2026 15:22:23 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org;
	s=k20260515; t=1795706546;
	bh=VpEu+mJf+gvKieDmE+OajqJCgi0lHVmWfASEOdaIKk8=;
	h=Date:From:To:Cc:Subject:References:In-Reply-To;
	b=OEc9OpLrRQryRwxV8IddLVdgynynt92DYumKR2IFn+vEihjjtYB7gIC7tpDqjcXDy
	 msJawpHjoufAASZpyAquIdGLtwwtMxgMiZshHvrKnCs76sBngY1nQcXcVQp9NbNY1x
	 0obQ+bxUiA2AgXRJwr8zSPHYTWnvhOxoQlI+vJcOAOFo/qeTmkht8z29lYWZT4CLGd
	 szmFmNtTipN5uQ8EeSOA0Bk8ZFS25blwR1Sloo9giQ2aA+b8fPYqFQjWJe1RMA3R6d
	 qXBGLnhth2wbY4e3/93sXIHKfEKpiTJGOMLZlS8NIJQi9uQVWH59r83oYNTb4AAdgN
	 wMntd0bjG+mag==
X-Cc: nshettyj@marvell.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, rkudurumalla@marvell.com,
	sgoutham@marvell.com, rkannoth@marvell.com, gakula@marvell.com,
	sbhatta@marvell.com, andrew+netdev@lunn.ch, davem@davemloft.net,
	edumazet@kernel.org, kuba@kernel.org, pabeni@redhat.com
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list
X-In-Reply-To: <179542493892.3135.7516887793037759713@kernel.org>