summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHauke Mehrtens <hauke@hauke-m.de>2011-12-22 21:47:26 +0100
committerLuis R. Rodriguez <mcgrof@frijolero.org>2011-12-23 07:06:49 -0800
commitb13fab2899646066a314508d63b0fddb5947b6af (patch)
tree28ff474b50280bd20ac408fdfa9987c03ab1c59e
parent88303e7a0325a0eba3b97228805a819ac9630eba (diff)
compat-wireless: remove platform_device_id for kernel < 2.6.30
Kernel < 2.6.30 do not support struct platform_device_id, so remove it for them and hope that the probing will reject an invalid device. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
-rw-r--r--patches/45-remove-platform-id-table.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/patches/45-remove-platform-id-table.patch b/patches/45-remove-platform-id-table.patch
new file mode 100644
index 00000000..aa96ecb6
--- /dev/null
+++ b/patches/45-remove-platform-id-table.patch
@@ -0,0 +1,23 @@
+--- a/drivers/net/wireless/wl12xx/main.c
++++ b/drivers/net/wireless/wl12xx/main.c
+@@ -5321,16 +5321,20 @@ static int __devexit wl12xx_remove(struc
+ return 0;
+ }
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,30)
+ static const struct platform_device_id wl12xx_id_table[] __devinitconst = {
+ { "wl12xx", 0 },
+ { } /* Terminating Entry */
+ };
+ MODULE_DEVICE_TABLE(platform, wl12xx_id_table);
++#endif
+
+ static struct platform_driver wl12xx_driver = {
+ .probe = wl12xx_probe,
+ .remove = __devexit_p(wl12xx_remove),
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,30)
+ .id_table = wl12xx_id_table,
++#endif
+ .driver = {
+ .name = "wl12xx_driver",
+ .owner = THIS_MODULE,