🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #7955

[PATCH] net: octeontx2: fix building without DEBUGFS

#7955
From: Arnd Bergmann
Date: Tue, 27 Oct 2026 15:17
45 lines
9188 bytes
From: Arnd Bergmann <arnd@arndb.de>

This error came up on my randconfig tests this week:

drivers/net/ethernet/marvell/octeontx2/af/cn20k/debugfs.c: In function 'npc_cn20k_debugfs_init':
drivers/net/ethernet/marvell/octeontx2/af/cn20k/debugfs.c:392:55: error: 'struct rvu' has no member named 'rvu_dbg'; did you mean 'rvu_dl'?
  392 |         debugfs_create_file("mcam_layout", 0444, rvu->rvu_dbg.npc,

The problem here is that the rvu_dbg member is hidden in an #ifdef
block, but the reference to it is not.

Remove the #ifdef and waste the 8 bytes in the structure in this
config. Note that the debugfs_create_file() call end up ignoring
the arguments, so the actual debugfs implementation is still
ignored here.

Fixes: 45229e9a9ab5 ("octeontx2-af: Extend debugfs support for cn20k NIX")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
I cannot tell why this showed up now and not earlier, so maybe the
'Fixes' line is misplaced. In randconfig builds, debugfs is almost
always selected by something else, while the octeontx2 driver is
usually disabled, so it does make some sense that this config
would be rate.
---
 drivers/net/ethernet/marvell/octeontx2/af/rvu.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/ethernet/marvell/octeontx2/af/rvu.h b/drivers/net/ethernet/marvell/octeontx2/af/rvu.h
index fb4870cd18e9..3b647e7b4bc2 100644
--- a/drivers/net/ethernet/marvell/octeontx2/af/rvu.h
+++ b/drivers/net/ethernet/marvell/octeontx2/af/rvu.h
@@ -649,9 +649,7 @@ struct rvu {
 	int			mcs_blk_cnt;
 	int			cpt_pf_num;
 
-#ifdef CONFIG_DEBUG_FS
 	struct rvu_debugfs	rvu_dbg;
-#endif
 	struct rvu_devlink	*rvu_dl;
 
 	/* RVU switch implementation over NPC with DMAC rules */
-- 
2.53.0
Technical Details
Message-ID: <20261027151737.386155-1-arnd@kernel.org>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-352511-linux-kernel-netdev=dewy.ru

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-352511-linux-kernel-netdev=dewy.ru
From: arnd@kernel.org (Arnd Bergmann)
Newsgroups: linux.kernel.netdev
Subject: [PATCH] net: octeontx2: fix building without DEBUGFS
Date: Tue, 27 Oct 2026 16:17:21 +0100
Organization: Usenet Network
Message-ID: <20261027151737.386155-1-arnd@kernel.org>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="1568018"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:Zhe216Q1PrcApAaT8t+1HcQPEgU= sha256:SPy7JrOR0t7nGywlbZe4widB+1+qid4OAgo+gQX+DlA=
	sha1:zXEBklcI+8yVgEUdlSzxGnP6KeE= sha256:1Z+KQ3UEIGK3AK+I89wPktizeZhj68Z2w9hZS1xMKgo=
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 49C1B125C09; Tue, 27 Oct 2026 18:24:55 +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 ofKoZqpFC43p;
	Tue, 27 Oct 2026 18:24:52 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-352511-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 tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114])
	by mail.dewy.ru (Postfix) with ESMTPS id 40C5B125C06; Tue, 27 Oct 2026 18:24:44 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by tor.lore.kernel.org (Postfix) with ESMTP id 373562C95F; Tue, 27 Oct 2026 15:18:02 +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=1793114272;
	b=zUR1HPX2Dc0BqQs/ZN8DoDuKBkamD9JD7pe1qRu7Cd4QiLtxAYzde9ErFlBmAJ+Eka2U
	 VSP7KWPl1jE0sMkj2pZWUFJd2x3cyQResQLyRIQwdHjohF779TlknuTSCpPMgh1z5R+Ys
	 7hzfSjEWt7qrViUSYgyDo4b7DJVx3sywbkGaNpyZP18ynA4B8xGQx1RTeFmWylYayfZA9
	 5cdUhZlwdQO75tEGYWzggWYnT0+F0FVW27dk/dIN2Eb3/ND2Bjjwgk1UPqhdH3WKs2tZW
	 csNy3PVTihr3Sj4MtH4T9lEGpN31dbjn/Y0iG54xGOlFWgAmam7JdMan3LXI0uMkRlA==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1793114272;
	h=X-Original-To:Received:Received:DKIM-Signature:From:To:Cc:Subject:
	 Date:Message-ID:X-Mailer:X-Mailing-List:List-Id:List-Post:List-Help:
	 List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version:
	 Content-Transfer-Encoding;
	bh=47NP/PYX9H8WhXFGuiSEfQYgXCHwbDC0hNK6ORbtpNU=;
	b=r1sYjSUdRuLSLEtsTSN0g/2hfbkj9lP9DQ4D83q0c6eTt+QGy6ck0s0o2to6PEhA6PLu
	 yjR52gK58Xy2x767Io8VRGJtCAYZrVEzVls1Fi5nkB/Hj3z9g4ArYDUrIksVP3ndwUGz5
	 0YwRXzgJ0SkzcFOAjlJjNRUJa48uiJBoR0tm/558zd7U6j+XD9kMyvaWGbpVntHVER3fk
	 qDWm12v29c1exYsctV1w1d3RbbFcY+N8qHtf3/f+a8bpJHRruZMEm8OjfYzIfZTuKQRkq
	 ef+5pPA+xrAR0Hd+O58aWrluXyQImcg5/kRutPUdJOdMys9kGIYi5BV+ojHl7/aSdHA==
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="oMTa/ju9";
	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 EC0F0606A320;
	Tue, 27 Oct 2026 15:17:51 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key, unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=oMTa/ju9
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=1793114266;
	b=ypPxK2n1NwLdBrZ01BCi/PIo9DtzNePLvgI75rojOU88ZEiSqUHnJHTgR1MuB2L94g4w
	 0xscQWGBtfl9+5uyFnQeWjZMqKFub7owHuTReRJNwmoJGjuS0eVnULt4O2F+I5hhG1GwW
	 IMy4Jhm8sUvtxGaGyJdMV4mK3Z6jLW45iu8cEpc0Vw5Eyu5s5Eu3VvyA/Y3UviM/H4nT1
	 YI7O/z7C6inIabDPzVwL3r7drpy2C6lXZI3KMe/w4g8N2VipZz4PeDgWvTNjaQTDyiekr
	 yCh9IukfBEbCgFQtvT1ExCbHEBwT18xEQ1Kr9VMcYLgAsi3yAl5nTquxOUsKX1JGp4g==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1793114266;
	h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer:
	 MIME-Version:Content-Transfer-Encoding;
	bh=47NP/PYX9H8WhXFGuiSEfQYgXCHwbDC0hNK6ORbtpNU=;
	b=Z2qK+uNwBYQm0k8fwYjZ9gedWFOn1mR9AlyRlRvuzpBiifvslYzIeIC1P2UBxbdqpnhc
	 hcX5vZYMLPq8cPhIKA5Mli7/lbhOjmPjyiuHKv6rcOcd8t+oDIYDv+ii7ZKSJWCQmOrij
	 V1JV7fpt04M6COGrI2Puh+TBTdKow5vYInrWGbohYY/ukhW0Pf9w60iRwmRH9zU9ZF2ta
	 Lp6NCsjzSitTVhod3CsR3SlPcqyXiRq0fcYmkgOfduXxUMXAQF6gWk7O5Oev+Z6RTbHso
	 0GJKAYdyRUVJe8yw5lEiEF+nnLPOyUjKYDw1ataFHBqeH41jWshaesDnZKw4aCskaIQ==
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="oMTa/ju9";
	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 CE5B9606A31A;
	Tue, 27 Oct 2026 15:17:45 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id EBF831F031E2;
	Tue, 27 Oct 2026 15:17:41 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org;
	s=k20260515; t=1793114265;
	bh=47NP/PYX9H8WhXFGuiSEfQYgXCHwbDC0hNK6ORbtpNU=;
	h=From:To:Cc:Subject:Date;
	b=oMTa/ju9Ixd+kJ9VWqX275nUfLHjQf3HaZ/Svrw9+zkX6n2Z3YkZuAppFYezCNXI/
	 xaAi6IcoATVevxfqrFOqn8WR5L+F96+uVe5CEOQWngysqqY5UxJLPDibZTAJcoRccU
	 7wE/txWnaZ0l2mFFp6byoPKkAoihXit2fud8z09xFa5Rc06SB6r914rQoqtZLxsg/e
	 yTFHoHVuVozzfld7fC3DSFivC77MqiWQhOF6VLBUq1fPJkhqZ+/ZLVSj0MAF59b0cz
	 +JunLM9NXVBCNyCqR3iBBhqYhKB2TNAsWB819Lr8e3bv9QdXGmAB9nB/m9J7rl84rn
	 sNuAE7cBLfOnA==
X-Cc: Arnd Bergmann <arnd@arndb.de>,
	Suman Ghosh <sumang@marvell.com>,
	Nitin Shetty J <nshettyj@marvell.com>,
	Hariprasad Kelam <hkelam@marvell.com>,
	Jiangshan Yi <yijiangshan@kylinos.cn>,
	netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
X-Mailer: git-send-email 2.53.0
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