pcmcia (2/4): remove "init_status" from struct pcmcia_driver
PATCH 1/1 pcmcia (2/4): remove "init_status" from struct pcmcia_driver
As we don't have a late_initcall in ds.c any more, we can't easily distinguish between in-kernel drivers and those built as modules. This information was used by cardmgr to detect whether "rmmod" makes sense. As unloading of modules seems to be deprecated behaviour anyway in 2.5., and the current driver unloading process is IMO broken anyway, I don't shed any tears on this lost functionality.
drivers/pcmcia/ds.c | 7 +------ include/pcmcia/ds.h | 2 +- 2 files changed, 2 insertions(+), 7 deletions(-)
drivers/pcmcia/ds.c +1 -6
@@ -129,9 +129,6 @@extern struct proc_dir_entry *proc_pccard; -/* We use this to distinguish in-kernel from modular drivers */ -static int init_status =1 ; -/*====================================================================*/ static void cs_error (client_handle_t handle,int func,int ret)
@@ -156,7 +153,6 @@return -EINVAL ; driver->use_count =0 ; - driver->status = init_status; driver->drv.bus = &pcmcia_bus_type;return driver_register (&driver->drv);
@@ -251,8 +247,7 @@struct pcmcia_driver *p_dev =container_of (driver, struct pcmcia_driver, drv); - *p +=sprintf (*p,"%-24.24s %d %d\n" , driver->name, p_dev->status, - p_dev->use_count); + *p +=sprintf (*p,"%-24.24s 1 %d\n" , driver->name, p_dev->use_count); d = (void *) p;return 0 ;
include/pcmcia/ds.h +1 -1
@@ -144,7 +144,7 @@extern struct bus_type pcmcia_bus_type;struct pcmcia_driver { -int use_count, status; +int use_count;dev_link_t *(*attach)(void );void (*detach)(dev_link_t *);struct module *owner;