[PATCH] pcmcia: mod_devicetable.h fix for different sizes in kernel- and userspace
authorDominik Brodowski <linux@dominikbrodowski.net>
Mon, 27 Jun 2005 23:28:56 +0000 (16:28 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Tue, 28 Jun 2005 01:03:21 +0000 (18:03 -0700)
The size of pointers may differ between (userspace) modpost and (kernelspace)
modules -- so fix mod_devicetable.h to reflect this possibility.

Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
include/linux/mod_devicetable.h

index 8a8dc82a941de4bac4ae274f4dbbbad038fa0e74..9b6d05172ed45ba62618a10a6b2e635105f5b3a5 100644 (file)
@@ -191,12 +191,22 @@ struct pcmcia_device_id {
        /* for pseude multi-function devices */
        __u8            device_no;
 
-       const char *    prod_id[4];
        __u32           prod_id_hash[4];
 
+       /* not matched against in kernelspace*/
+#ifdef __KERNEL__
+       const char *    prod_id[4];
+#else
+       kernel_ulong_t  prod_id[4];
+#endif
+
        /* not matched against */
        kernel_ulong_t  driver_info;
+#ifdef __KERNEL__
        char *          cisfile;
+#else
+       kernel_ulong_t  cisfile;
+#endif
 };
 
 #define PCMCIA_DEV_ID_MATCH_MANF_ID    0x0001