Skip to contentSkip to conversation

cfg80211: remove unused callback

PATCH RESEND Superseded Matteo Croce 2 participants 2 messages Feb 6, 2021 – Feb 8, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 cfg80211: remove unused callback

From: Matteo Croce <[email protected]>

The ieee80211 class registers a callback which actually does nothing. Given that the callback is optional, and all its accesses are protected by a NULL check, remove it entirely.

---
 net/wireless/sysfs.c | 7 -------
 1 file changed, 7 deletions(-)
net/wireless/sysfs.c +0 -7
index 3ac1f48195d2..41cb4d565149 100644
@@ -81,12 +81,6 @@ static void wiphy_dev_release(struct device *dev)
 	cfg80211_dev_free(rdev);
 }
 
-static int wiphy_uevent(struct device *dev, struct kobj_uevent_env *env)
-{
-	/* TODO, we probably need stuff here */
-	return 0;
-}
-
 #ifdef CONFIG_PM_SLEEP
 static void cfg80211_leave_all(struct cfg80211_registered_device *rdev)
 {
@@ -157,7 +151,6 @@ struct class ieee80211_class = {
 	.owner = THIS_MODULE,
 	.dev_release = wiphy_dev_release,
 	.dev_groups = ieee80211_groups,
-	.dev_uevent = wiphy_uevent,
 	.pm = WIPHY_PM_OPS,
 	.ns_type = &net_ns_type_operations,
 	.namespace = wiphy_namespace,
Signature · 1 line
2.29.2
#1 lore raw
Quoted 10 lines · Matteo Croce

From: Matteo Croce <[email protected]>

The ieee80211 class registers a callback which actually does nothing. Given that the callback is optional, and all its accesses are protected by a NULL check, remove it entirely.

---
 net/wireless/sysfs.c | 7 -------
 1 file changed, 7 deletions(-)

Normally cfg80211 patches go to mac80211-next, not net-next.

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches