🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #12761

Re: [PATCH net-next 2/2] net sysfs: simplify creating empty wireless directory

#12761
From: Greg Kroah-Hartman
Date: Sun, 08 Nov 2026 14:21
42 lines
9434 bytes
On Sun, Nov 08, 2026 at 03:12:04PM +0100, Heiner Kallweit wrote:
> On 08.11.2026 15:06, Greg Kroah-Hartman wrote:
> > On Sun, Nov 08, 2026 at 02:46:03PM +0100, Heiner Kallweit wrote:
> >> Now that an empty directory can be created with attrs being NULL,
> >> make use of this new functionality and remove the dummy attribute list.
> >>
> >> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> >> ---
> >>  net/core/net-sysfs.c | 5 -----
> >>  1 file changed, 5 deletions(-)
> >>
> >> diff --git a/net/core/net-sysfs.c b/net/core/net-sysfs.c
> >> index 5c0402389c6..f58b59e1126 100644
> >> --- a/net/core/net-sysfs.c
> >> +++ b/net/core/net-sysfs.c
> >> @@ -910,13 +910,8 @@ static const struct attribute_group netstat_group = {
> >>  	.attrs  = netstat_attrs,
> >>  };
> >>  
> >> -static struct attribute *wireless_attrs[] = {
> >> -	NULL
> >> -};
> >> -
> >>  static const struct attribute_group wireless_group = {
> >>  	.name = "wireless",
> >> -	.attrs = wireless_attrs,
> > 
> > Why does this want to create an empty directory?  Surely you aren't
> > adding attributes later to it, right?  If so, that's not ok either...
> > 
> 
> For compatibility reasons. See 38c1a01cf10c ("wireless: add back sysfs directory")

How long do we have to keep that?  That was a very long time ago, 2012,
why not just remove it entirely now?  And if the sysfs core hasn't
needed this since then, why give other people the opportunity to abuse
it this way as well?  That doesn't feel like a good idea to me.

thanks,

greg k-h
Technical Details
Message-ID: <2026110812-angles-guru-473b@gregkh>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-358756-linux-kernel-netdev=dewy.ru
References: <0a0a7987-abb2-49c8-bc16-3938233ae9c5@gmail.com> <675f4353-125e-4168-a617-c0d1fb519045@gmail.com> <2026110816-crate-tightly-8560@gregkh> <d85b02e5-d9ab-4535-ab82-9b8184fbd1a8@gmail.com>

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-358756-linux-kernel-netdev=dewy.ru
From: gregkh@linuxfoundation.org (Greg Kroah-Hartman)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net-next 2/2] net sysfs: simplify creating empty wireless
 directory
Date: Sun, 8 Nov 2026 09:21:08 -0500
Organization: Usenet Network
Message-ID: <2026110812-angles-guru-473b@gregkh>
References: <0a0a7987-abb2-49c8-bc16-3938233ae9c5@gmail.com>
 <675f4353-125e-4168-a617-c0d1fb519045@gmail.com>
 <2026110816-crate-tightly-8560@gregkh>
 <d85b02e5-d9ab-4535-ab82-9b8184fbd1a8@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Info: usenet.network;
	logging-data="139469"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:wPPLe+3bxZgE1jClGf5fDWhiIUI= sha256:6kt1+LD+juRaqm1WNInmyeA95q8R1CUyMv+4MK5Kxqo=
	sha1:zW8tJF3wG1oDBwQyIRZHiShUHo8= sha256:zWVRq4RWn5/0fpUR+ZOIN4QuX9GAsBC0iyy7vC+AjG4=
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 EE7E3113597; Sun,  8 Nov 2026 17:22:33 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.051
X-Spam-Status: No, score=-3.051 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,
	HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1,
	RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001,
	URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (1024-bit key)
	header.d=linuxfoundation.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 BUALKxVh61hs;
	Sun,  8 Nov 2026 17:22:31 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-358756-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=linuxfoundation.org
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id B0FEB113587; Sun,  8 Nov 2026 17:22:22 +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 0415660A65; Sun,  8 Nov 2026 14:21:11 +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=1794147670;
	b=O2ESE81LdftjZNGlRTNXcjuNtgrkkxDMmIaYAImKgoEY8Mhwkij6wIE6t0NpLqn6pQpq
	 esOlhkfsl4fNaJhlyoLStpIRvOSzDVo6oxLsU0fKkgCFuyTFllkqsgoLv1kItRK25n0y9
	 u0+go8GBy8xkhyi+wxi5sqfWVR5xMBEqdJ2DFadfsQDk6PdHJnsAxFLOhu688/meNjvx1
	 uEpOMGv1JmBmmE2CxrqjJYdvm7QYi0PrQ7IM+/LT96SuEl2Xjo5aErS3Bnms2uMxBINCv
	 9qr/72RR2y6muk4JI/kNX3DURHGD50TSNc2/it2iB9e9IFCms+LIRGew9rJ46OIatVA==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794147670;
	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:In-Reply-To;
	bh=kQtf2YGeartcwb3E5bs7hWbnN6qZi5AsGs3oh/sS15M=;
	b=p8sL27SFw3WID6WXkyQ+91rk5vMUVrlK0v6+VEA0EgRkxkiuLJO3cOMMvH6Yu79pHW9d
	 GEJ6pGbeBxaNuZvT6tLgq+/DqyEqx0Qh+hYmpAgdlolBiYXcJI3PN1kP8Zr6imAysf8jk
	 vAabS6vppgeQYo6Weg0amg2K28n4OX0NhXk/L83XviLK2bNL9XZo7PcNVzbEX0bt515AK
	 OaneM4bMmOY+wGnX+UsRwzUP+zhnGn2DRHe91Dq76jaTooqa9dXnhhZ4KVOLgX6DtaVQh
	 8SlVUVguzn/v1/41XIx4e+ln12D2HEbshsIAJ/R1KlkXl8kJ0cqisHvwQPsFJxgIBsw==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b="bXjH0l/D";
	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 CCD57606A330;
	Sun,  8 Nov 2026 14:21:10 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=bXjH0l/D
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=1794147670;
	b=bH3NstSz/o39NHf60aGNKox7x7GPLLYh/+Ax8kPT/8dNPrp7jUZ33XqOEJdO5HY6STX4
	 fVPBkS3jqvD4fO6bPST3mhD5r84qo+/COT0XLOdkmJ3p06lObNxLVg7R4o7jyszHU/O2+
	 Epc631yZUyBBvLoHOXfQZp0KlyHjRBtUqIupPZD37BgIS8l1LwRqyMUTPslZ2k7K798Ko
	 akzhLC6Am1iVNC6k53JtbVh3AZt+Kf5RPboYItUI1/Dur0dJOFuzxcCDmXVeBCwImS0e2
	 bzs5BDdcJcBzn+c0j4Qprri/ppswe116EN4y/rc3XiNqbxihFh/hy9nxbFYR0E61Klw==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794147670;
	h=Received:DKIM-Signature:Date:From:To:Cc:Subject:Message-ID:
	 References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To;
	bh=kQtf2YGeartcwb3E5bs7hWbnN6qZi5AsGs3oh/sS15M=;
	b=ODMIJczeo160WIlzQWBi7u3lPZ0wXuvjzGYauTYRdpv5L7hOe/9Ttgl0f6/PXn5JhUR3
	 oc7vTbAFS6I/9TvMdxXYnEnsQirLcagjnw3pJmKCueoJMaBXTrz+oIZYrs4AFqr/nYZBo
	 ZDxK4GzvhN7q8GA54TZHyo6yUV11GRPfOnnV/LaIFDl2tDVm1mzVGXuUCKxi7IcUKVrEy
	 2qRRZgoN3jAtd7RHOyTM3o9yksUoN/4ockFuzqlg4VZuhfiKH4Q6gFMiDR+Dy8GggYFPl
	 oRD2P+UYZYbPNfbNmrQKNkoWoiOwaiJGcODq0qJ0+ZY+6+CTCR4pyM4SEhjlb9BNKxA==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b="bXjH0l/D";
	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 9EFA0606A31C;
	Sun,  8 Nov 2026 14:21:09 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id EDD191F0089F;
	Sun,  8 Nov 2026 14:21:08 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org;
	s=korg; t=1794147669;
	bh=kQtf2YGeartcwb3E5bs7hWbnN6qZi5AsGs3oh/sS15M=;
	h=Date:From:To:Cc:Subject:References:In-Reply-To;
	b=bXjH0l/DRRa0mduKHwWjZwmw9uFcEyQzx+MFRVVe8sDNtDoXlWfbN7GL4R/VGETnF
	 /w0UYUadX/uchHJamEVmQL5gl52L+OpUKt7saublI3UEtknGe6TQwmC/JVJZwfY8Sw
	 Zbyh9mf3d+gGYnj7EL+jTl8rlbuwITy1Bp+ODT6E=
X-Cc: David Miller <davem@davemloft.net>, Andrew Lunn <andrew+netdev@lunn.ch>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Simon Horman <horms@kernel.org>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Danilo Krummrich <dakr@kernel.org>, Johan Hovold <johan@kernel.org>,
	Paolo Abeni <pabeni@redhat.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	driver-core@lists.linux.dev
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: <d85b02e5-d9ab-4535-ab82-9b8184fbd1a8@gmail.com>