summaryrefslogtreecommitdiff
path: root/patches/14-device-type.patch
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-12-10 16:33:59 -0800
committerLuis R. Rodriguez <lrodriguez@atheros.com>2009-12-10 16:36:32 -0800
commit1a8c0d67ff56b62d132267fafdd881d69a38ba30 (patch)
treecac4082ff21473b6917343b66609cdf0c426487e /patches/14-device-type.patch
parentb2399a1d9ff2ad8fc1fdc53029e44ecba4479ed3 (diff)
Re-order patch location and compat code
The patches can now go on the top level dir as that is all we ship with. The top level compat/ dir now exists as the home of the copied compat module and we build the compat module there. Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Diffstat (limited to 'patches/14-device-type.patch')
-rw-r--r--patches/14-device-type.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/patches/14-device-type.patch b/patches/14-device-type.patch
new file mode 100644
index 00000000..9f2f433b
--- /dev/null
+++ b/patches/14-device-type.patch
@@ -0,0 +1,36 @@
+Kernels >= 2.6.32 can identify the type of device netdevice
+so that sysfs can be used to get this. We never really had a
+systematic way of doing this -- now we do through the
+SET_NETDEV_DEVTYPE() macro. For older kernels we make the
+SET_NETDEV_DEVTYPE() be a no-op this means the wireless type
+we define is unused so we ucomment it simply to avoid a
+compile warning.
+
+--- a/net/wireless/core.c 2009-12-10 09:17:21.000000000 -0800
++++ b/net/wireless/core.c 2009-12-10 09:17:28.000000000 -0800
+@@ -635,9 +635,11 @@
+ dev_put(wdev->netdev);
+ }
+
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,32))
+ static struct device_type wiphy_type = {
+ .name = "wlan",
+ };
++#endif
+
+ static int cfg80211_netdev_notifier_call(struct notifier_block * nb,
+ unsigned long state,
+--- a/net/bluetooth/bnep/core.c 2009-12-10 09:22:58.000000000 -0800
++++ b/net/bluetooth/bnep/core.c 2009-12-10 09:22:59.000000000 -0800
+@@ -536,9 +536,11 @@ static struct device *bnep_get_device(st
+ return conn ? &conn->dev : NULL;
+ }
+
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,32))
+ static struct device_type bnep_type = {
+ .name = "bluetooth",
+ };
++#endif
+
+ int bnep_add_connection(struct bnep_connadd_req *req, struct socket *sock)
+ {