From: Greg Kroah-Hartman Date: Mon, 26 Nov 2012 22:32:09 +0000 (-0800) Subject: 3.6-stable patches X-Git-Tag: v3.6.9~19 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8c5dd6fb4d60dd358b0f6af58c2f945633ad4533;p=thirdparty%2Fkernel%2Fstable-queue.git 3.6-stable patches added patches: wireless-add-back-sysfs-directory.patch --- diff --git a/queue-3.6/series b/queue-3.6/series new file mode 100644 index 00000000000..2c0b42cdf00 --- /dev/null +++ b/queue-3.6/series @@ -0,0 +1 @@ +wireless-add-back-sysfs-directory.patch diff --git a/queue-3.6/wireless-add-back-sysfs-directory.patch b/queue-3.6/wireless-add-back-sysfs-directory.patch new file mode 100644 index 00000000000..fff86e92ba8 --- /dev/null +++ b/queue-3.6/wireless-add-back-sysfs-directory.patch @@ -0,0 +1,61 @@ +From 38c1a01cf10c6e4049b4ffbd4a6af655df2a46e1 Mon Sep 17 00:00:00 2001 +From: Johannes Berg +Date: Fri, 16 Nov 2012 20:46:19 +0100 +Subject: wireless: add back sysfs directory + +From: Johannes Berg + +commit 38c1a01cf10c6e4049b4ffbd4a6af655df2a46e1 upstream. + +commit 35b2a113cb0298d4f9a1263338b456094a414057 broke (at least) +Fedora's networking scripts, they check for the existence of the +wireless directory. As the files aren't used, add the directory +back and not the files. Also do it for both drivers based on the +old wireless extensions and cfg80211, regardless of whether the +compat code for wext is built into cfg80211 or not. + +Reported-by: Dave Airlie +Reported-by: Bill Nottingham +Signed-off-by: Johannes Berg +Signed-off-by: Greg Kroah-Hartman + +--- + net/core/net-sysfs.c | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) + +--- a/net/core/net-sysfs.c ++++ b/net/core/net-sysfs.c +@@ -417,6 +417,17 @@ static struct attribute_group netstat_gr + .name = "statistics", + .attrs = netstat_attrs, + }; ++ ++#if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211) ++static struct attribute *wireless_attrs[] = { ++ NULL ++}; ++ ++static struct attribute_group wireless_group = { ++ .name = "wireless", ++ .attrs = wireless_attrs, ++}; ++#endif + #endif /* CONFIG_SYSFS */ + + #ifdef CONFIG_RPS +@@ -1397,6 +1408,15 @@ int netdev_register_kobject(struct net_d + groups++; + + *groups++ = &netstat_group; ++ ++#if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211) ++ if (net->ieee80211_ptr) ++ *groups++ = &wireless_group; ++#if IS_ENABLED(CONFIG_WIRELESS_EXT) ++ else if (net->wireless_handlers) ++ *groups++ = &wireless_group; ++#endif ++#endif + #endif /* CONFIG_SYSFS */ + + error = device_add(dev);