patch from Ian Abbott <abbotti@mev.co.uk>:
authorFrank Mori Hess <fmhess@speakeasy.net>
Sun, 27 Feb 2005 23:12:25 +0000 (23:12 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Sun, 27 Feb 2005 23:12:25 +0000 (23:12 +0000)
The last change to das08_cs.c on Feb 5 breaks on 2.4, though the change
itself was not unreasonable (it saves a few bytes at least).  The
problem is that the change was incompatible with the version of struct
device_driver defined in comedi's linux/device.h compatibility header.
In the "real" version of struct device_driver, the "name" member is a
"char *", but in the compatibility version it's a "dev_info_t", which is
a "char[32]".

The attached patch sorts it out in the compatibility headers.

include/linux/device.h
include/pcmcia/ds.h

index f3a6d18f11b0306df75b631e74eacaf38b6203d9..7f3bf34eb8f76820100ba1199a334b8ec3342bc1 100644 (file)
@@ -12,7 +12,7 @@
 
 struct device_driver 
 {
-       dev_info_t name;
+       char *name;
 };
 
 typedef void class_simple;
index 31d7ef9322afac20a2a9a3093c6f9acb3cfec5e0..cf8223e5a467c065a035ab146030f5697cbbdf3a 100644 (file)
@@ -20,12 +20,13 @@ struct pcmcia_driver {
 /* driver registration */
 static inline int pcmcia_register_driver(struct pcmcia_driver *driver)
 {
-       return register_pccard_driver(&driver->drv.name, driver->attach, driver->detach);
+       return register_pccard_driver((dev_info_t*)driver->drv.name,
+                       driver->attach, driver->detach);
 };
 
 static void inline pcmcia_unregister_driver(struct pcmcia_driver *driver)
 {
-       unregister_pccard_driver(&driver->drv.name);
+       unregister_pccard_driver((dev_info_t*)driver->drv.name);
 };
 
 static void inline cs_error(client_handle_t handle, int func, int ret)