Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next] net sysfs: remove deprecated empty wireless directory
@ 2026-11-08 20:39 Heiner Kallweit
  2026-11-09 20:40 ` netdev-bot+sashiko
  0 siblings, 1 reply; 3+ messages in thread
From: Heiner Kallweit @ 2026-11-08 20:39 UTC (permalink / raw)
  To: Jakub Kicinski, David Miller, Simon Horman, Andrew Lunn,
	Eric Dumazet, Paolo Abeni
  Cc: netdev@vger.kernel.org

Last known user of this deprecated feature was Fedora, until 2012.
See also 38c1a01cf10c ("wireless: add back sysfs directory").
This was 14yrs ago, let's remove the feature.

Link: https://github.com/fedora-sysv/initscripts/commit/4e96fcecee7ab70295a5f2c52748cd57cbab60bb
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
 include/linux/netdevice.h |  2 +-
 net/core/net-sysfs.c      | 25 -------------------------
 2 files changed, 1 insertion(+), 26 deletions(-)

diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 435be7880d7..ac943798abc 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -2484,7 +2484,7 @@ struct net_device {
 	struct dm_hw_stat_delta __rcu *dm_private;
 #endif
 	struct device		dev;
-	const struct attribute_group *sysfs_groups[5];
+	const struct attribute_group *sysfs_groups[4];
 	const struct attribute_group *sysfs_rx_queue_group;
 
 	const struct rtnl_link_ops *rtnl_link_ops;
diff --git a/net/core/net-sysfs.c b/net/core/net-sysfs.c
index 5c0402389c6..cb8c82d1a4d 100644
--- a/net/core/net-sysfs.c
+++ b/net/core/net-sysfs.c
@@ -910,28 +910,6 @@ 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,
-};
-
-static bool wireless_group_needed(struct net_device *ndev)
-{
-#if IS_ENABLED(CONFIG_CFG80211)
-	if (ndev->ieee80211_ptr)
-		return true;
-#endif
-#if IS_ENABLED(CONFIG_WIRELESS_EXT)
-	if (ndev->wireless_handlers)
-		return true;
-#endif
-	return false;
-}
-
 #else /* CONFIG_SYSFS */
 #define net_class_groups	NULL
 #endif /* CONFIG_SYSFS */
@@ -2370,9 +2348,6 @@ int netdev_register_kobject(struct net_device *ndev)
 
 	*groups++ = &netstat_group;
 	*groups++ = &netdev_phys_group;
-
-	if (wireless_group_needed(ndev))
-		*groups++ = &wireless_group;
 #endif /* CONFIG_SYSFS */
 
 	/* Hold back the KOBJ_ADD uevent until the device is listed. */
-- 
2.56.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-11-09 21:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-08 20:39 [PATCH net-next] net sysfs: remove deprecated empty wireless directory Heiner Kallweit
2026-11-09 20:40 ` netdev-bot+sashiko
2026-11-09 21:07   ` Heiner Kallweit

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox