From: Dominik Brodowski From: Christoph Hellwig socket->{a,c}_region aren't ever touched elsewhere, so let's kill this. Signed-off-by: Christoph Hellwig Signed-off-by: Dominik Brodowski Signed-off-by: Andrew Morton --- 25-akpm/drivers/pcmcia/cs.c | 22 ++++------------------ 25-akpm/include/pcmcia/ss.h | 2 -- 2 files changed, 4 insertions(+), 20 deletions(-) diff -puN drivers/pcmcia/cs.c~pcmcia-socket-acregion-are-unused drivers/pcmcia/cs.c --- 25/drivers/pcmcia/cs.c~pcmcia-socket-acregion-are-unused Wed Jan 19 15:48:02 2005 +++ 25-akpm/drivers/pcmcia/cs.c Wed Jan 19 15:48:02 2005 @@ -341,25 +341,13 @@ EXPORT_SYMBOL(pcmcia_get_socket_by_nr); /*====================================================================== - Shutdown_Socket() and setup_socket() are scheduled using add_timer - calls by the main event handler when card insertion and removal - events are received. Shutdown_Socket() unconfigures a socket and - turns off socket power. Setup_socket() turns on socket power - and resets the socket, in two stages. + socket_setup() and shutdown_socket() are called by the main event + handler when card insertion and removal events are received. + socket_setup() turns on socket power and resets the socket, in two stages. + shutdown_socket() unconfigures a socket and turns off socket power. ======================================================================*/ -static void free_regions(memory_handle_t *list) -{ - memory_handle_t tmp; - while (*list != NULL) { - tmp = *list; - *list = tmp->info.next; - tmp->region_magic = 0; - kfree(tmp); - } -} - static void shutdown_socket(struct pcmcia_socket *s) { cs_dbg(s, 1, "shutdown_socket\n"); @@ -379,8 +367,6 @@ static void shutdown_socket(struct pcmci kfree(s->config); s->config = NULL; } - free_regions(&s->a_region); - free_regions(&s->c_region); { int status; diff -puN include/pcmcia/ss.h~pcmcia-socket-acregion-are-unused include/pcmcia/ss.h --- 25/include/pcmcia/ss.h~pcmcia-socket-acregion-are-unused Wed Jan 19 15:48:02 2005 +++ 25-akpm/include/pcmcia/ss.h Wed Jan 19 15:48:02 2005 @@ -165,7 +165,6 @@ typedef struct window_t { #define MAX_WIN 4 struct config_t; -struct region_t; struct pcmcia_callback; @@ -185,7 +184,6 @@ struct pcmcia_socket { } irq; io_window_t io[MAX_IO_WIN]; window_t win[MAX_WIN]; - struct region_t *c_region, *a_region; struct list_head cis_cache; u_int fake_cis_len; char *fake_cis; _