summaryrefslogtreecommitdiffstats
path: root/include/pcmcia/ds.h
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2006-03-05 10:45:09 +0100
committerDominik Brodowski <linux@dominikbrodowski.net>2006-03-31 17:15:57 +0200
commitfd238232cd0ff4840ae6946bb338502154096d88 (patch)
treed20e8f5871f7cff9d0867a84f6ba088fbffcbe28 /include/pcmcia/ds.h
parent[PATCH] pcmcia: rename pcmcia_device.state (diff)
downloadlinux-fd238232cd0ff4840ae6946bb338502154096d88.tar.xz
linux-fd238232cd0ff4840ae6946bb338502154096d88.zip
[PATCH] pcmcia: embed dev_link_t into struct pcmcia_device
Embed dev_link_t into struct pcmcia_device(), as they basically address the same entity. The actual contents of dev_link_t will be cleaned up step by step. This patch includes a bugfix from and signed-off-by Andrew Morton. Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'include/pcmcia/ds.h')
-rw-r--r--include/pcmcia/ds.h31
1 files changed, 14 insertions, 17 deletions
diff --git a/include/pcmcia/ds.h b/include/pcmcia/ds.h
index 7f712df3e297..61f7d2dec199 100644
--- a/include/pcmcia/ds.h
+++ b/include/pcmcia/ds.h
@@ -39,7 +39,7 @@ typedef struct win_info_t {
typedef struct bind_info_t {
dev_info_t dev_info;
u_char function;
- struct dev_link_t *instance;
+ struct pcmcia_device *instance;
char name[DEV_NAME_LEN];
u_short major, minor;
void *next;
@@ -103,18 +103,6 @@ typedef struct dev_node_t {
struct dev_node_t *next;
} dev_node_t;
-typedef struct dev_link_t {
- dev_node_t *dev;
- u_int state, open;
- client_handle_t handle;
- io_req_t io;
- irq_req_t irq;
- config_req_t conf;
- window_handle_t win;
- void *priv;
- struct dev_link_t *next;
-} dev_link_t;
-
/* Flags for device state */
#define DEV_PRESENT 0x01
#define DEV_CONFIG 0x02
@@ -163,9 +151,17 @@ struct pcmcia_device {
struct list_head socket_device_list;
- /* deprecated, a cleaned up version will be moved into this
- struct soon */
- dev_link_t *instance;
+ /* deprecated, will be cleaned up soon */
+ dev_node_t *dev_node;
+ u_int state;
+ u_int open;
+ struct pcmcia_device *handle;
+ io_req_t io;
+ irq_req_t irq;
+ config_req_t conf;
+ window_handle_t win;
+ void *priv;
+
u_int p_state;
/* information about this device */
@@ -189,6 +185,7 @@ struct pcmcia_device {
struct pcmcia_driver * cardmgr;
#endif
};
+typedef struct pcmcia_device dev_link_t;
#define to_pcmcia_dev(n) container_of(n, struct pcmcia_device, dev)
#define to_pcmcia_drv(n) container_of(n, struct pcmcia_driver, drv)
@@ -196,7 +193,7 @@ struct pcmcia_device {
#define handle_to_pdev(handle) (handle)
#define handle_to_dev(handle) (handle->dev)
-#define dev_to_instance(dev) (dev->instance)
+#define dev_to_instance(dev) (dev)
/* error reporting */
void cs_error(client_handle_t handle, int func, int ret);