From cbbddd1046d44d90d31c7f246ed0207117602b89 Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Tue, 10 Jan 2006 20:54:46 +0100 Subject: [PATCH] pcmcia: remove unused defines Remove unused fields and declarations. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index 52660f32663..df9b7f70634 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -109,17 +109,6 @@ typedef struct client_req_t { #define CLIENT_THIS_SOCKET 0x01 -/* For RegisterClient */ -typedef struct client_reg_t { - dev_info_t *dev_info; - u_int Attributes; /* UNUSED */ - u_int EventMask; - int (*event_handler)(event_t event, int priority, - event_callback_args_t *); - event_callback_args_t event_callback_args; - u_int Version; -} client_reg_t; - /* ModifyConfiguration */ typedef struct modconf_t { u_int Attributes; -- cgit v1.2.3 From 1540eec5e5549b2e41704ce77f3f4ba880d2434c Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 15 Jan 2006 00:51:53 +0100 Subject: [PATCH] pcmcia: remove pcmcia_compat.c Remove the compatibility wrappers, as they can (now) also be implemented using macros. Please continue using these wrappers instead of new functions until a new API has stabilized. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index df9b7f70634..eda32a59581 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -386,15 +386,19 @@ int pcmcia_request_configuration(struct pcmcia_device *p_dev, config_req_t *req) int pcmcia_request_io(struct pcmcia_device *p_dev, io_req_t *req); int pcmcia_request_irq(struct pcmcia_device *p_dev, irq_req_t *req); int pcmcia_request_window(struct pcmcia_device **p_dev, win_req_t *req, window_handle_t *wh); -int pcmcia_reset_card(struct pcmcia_device *p_dev, client_req_t *req); int pcmcia_suspend_card(struct pcmcia_socket *skt); int pcmcia_resume_card(struct pcmcia_socket *skt); int pcmcia_eject_card(struct pcmcia_socket *skt); int pcmcia_insert_card(struct pcmcia_socket *skt); +int pccard_reset_card(struct pcmcia_socket *skt); struct pcmcia_socket * pcmcia_get_socket(struct pcmcia_socket *skt); void pcmcia_put_socket(struct pcmcia_socket *skt); +/* compatibility functions */ +#define pcmcia_reset_card(p_dev, req) \ + pccard_reset_card(p_dev->socket) + #endif /* __KERNEL__ */ #endif /* _LINUX_CS_H */ -- cgit v1.2.3 From 5f2a71fcb7995633b335a1e380ac63a968e61320 Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 15 Jan 2006 09:32:39 +0100 Subject: [PATCH] pcmcia: add pcmcia_disable_device pcmcia_disable_device(struct pcmcia_device *p_dev) performs the necessary cleanups upon device or driver removal: it calls the appropriate pcmcia_release_* functions, and can replace (most) of the current drivers' _release() functions. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index eda32a59581..a5d8df24d56 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -392,6 +392,8 @@ int pcmcia_eject_card(struct pcmcia_socket *skt); int pcmcia_insert_card(struct pcmcia_socket *skt); int pccard_reset_card(struct pcmcia_socket *skt); +void pcmcia_disable_device(struct pcmcia_device *p_dev); + struct pcmcia_socket * pcmcia_get_socket(struct pcmcia_socket *skt); void pcmcia_put_socket(struct pcmcia_socket *skt); -- cgit v1.2.3 From 50db3fdbbc98260fb538c1cc3f8cc597ba7bffe7 Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 15 Jan 2006 10:05:19 +0100 Subject: [PATCH] pcmcia: convert remaining users of pcmcia_release_io and _irq Convert the remaining drivers which use pcmcia_release_io or pcmcia_release_irq, and remove the EXPORT of these symbols. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index a5d8df24d56..7b915200c11 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -379,8 +379,6 @@ int pcmcia_get_mem_page(window_handle_t win, memreq_t *req); int pcmcia_map_mem_page(window_handle_t win, memreq_t *req); int pcmcia_modify_configuration(struct pcmcia_device *p_dev, modconf_t *mod); int pcmcia_release_configuration(struct pcmcia_device *p_dev); -int pcmcia_release_io(struct pcmcia_device *p_dev, io_req_t *req); -int pcmcia_release_irq(struct pcmcia_device *p_dev, irq_req_t *req); int pcmcia_release_window(window_handle_t win); int pcmcia_request_configuration(struct pcmcia_device *p_dev, config_req_t *req); int pcmcia_request_io(struct pcmcia_device *p_dev, io_req_t *req); -- cgit v1.2.3 From 4bbed5231468014b500b048d7370a1c6c349231a Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 15 Jan 2006 11:18:12 +0100 Subject: [PATCH] pcmcia: remove export of pcmcia_release_configuration Handle the _modifying_ operation sm91c92_cs requires in pcmcia_modify_configuration, so that the only remaining users of pcmcia_release_configuration() are within the pcmcia core module. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index 7b915200c11..087b3bc0489 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -116,10 +116,11 @@ typedef struct modconf_t { } modconf_t; /* Attributes for ModifyConfiguration */ -#define CONF_IRQ_CHANGE_VALID 0x100 -#define CONF_VCC_CHANGE_VALID 0x200 -#define CONF_VPP1_CHANGE_VALID 0x400 -#define CONF_VPP2_CHANGE_VALID 0x800 +#define CONF_IRQ_CHANGE_VALID 0x0100 +#define CONF_VCC_CHANGE_VALID 0x0200 +#define CONF_VPP1_CHANGE_VALID 0x0400 +#define CONF_VPP2_CHANGE_VALID 0x0800 +#define CONF_IO_CHANGE_WIDTH 0x1000 /* For RequestConfiguration */ typedef struct config_req_t { @@ -378,7 +379,6 @@ int pcmcia_get_status(struct pcmcia_device *p_dev, cs_status_t *status); int pcmcia_get_mem_page(window_handle_t win, memreq_t *req); int pcmcia_map_mem_page(window_handle_t win, memreq_t *req); int pcmcia_modify_configuration(struct pcmcia_device *p_dev, modconf_t *mod); -int pcmcia_release_configuration(struct pcmcia_device *p_dev); int pcmcia_release_window(window_handle_t win); int pcmcia_request_configuration(struct pcmcia_device *p_dev, config_req_t *req); int pcmcia_request_io(struct pcmcia_device *p_dev, io_req_t *req); -- cgit v1.2.3 From 70294b468302fd7a0a99dad935c7ba5322989345 Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 15 Jan 2006 12:43:16 +0100 Subject: [PATCH] pcmcia: remove unneeded Vcc pseudo setting As we do not allow setting Vcc in the pcmcia core, and Vpp1 and Vpp2 can only be set to the same value, a lot of code can be streamlined. Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index 087b3bc0489..e0835d612b7 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -125,7 +125,7 @@ typedef struct modconf_t { /* For RequestConfiguration */ typedef struct config_req_t { u_int Attributes; - u_int Vcc, Vpp1, Vpp2; + u_int Vpp; /* both Vpp1 and Vpp2 */ u_int IntType; u_int ConfigBase; u_char Status, Pin, Copy, ExtStatus; -- cgit v1.2.3 From 9940ec3617fec1db13e589bbc3f37e37878c7683 Mon Sep 17 00:00:00 2001 From: Dominik Brodowski Date: Sun, 5 Mar 2006 11:04:33 +0100 Subject: [PATCH] pcmcia: convert DEV_OK to pcmcia_dev_present Instead of the DEV_OK macro, drivers should use pcmcia_dev_present(). Signed-off-by: Dominik Brodowski --- include/pcmcia/cs.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/pcmcia/cs.h') diff --git a/include/pcmcia/cs.h b/include/pcmcia/cs.h index e0835d612b7..d5838c30d20 100644 --- a/include/pcmcia/cs.h +++ b/include/pcmcia/cs.h @@ -390,6 +390,7 @@ int pcmcia_eject_card(struct pcmcia_socket *skt); int pcmcia_insert_card(struct pcmcia_socket *skt); int pccard_reset_card(struct pcmcia_socket *skt); +struct pcmcia_device * pcmcia_dev_present(struct pcmcia_device *p_dev); void pcmcia_disable_device(struct pcmcia_device *p_dev); struct pcmcia_socket * pcmcia_get_socket(struct pcmcia_socket *skt); -- cgit v1.2.3