]> err.no Git - linux-2.6/blobdiff - include/pcmcia/ds.h
[PATCH] pcmcia: use mutexes instead of semaphores
[linux-2.6] / include / pcmcia / ds.h
index b707a603351b2217b6aecaeca3b7e81155b38d9e..8512cf9a12168815b955e0a7aad1702f312b58fc 100644 (file)
@@ -106,7 +106,6 @@ typedef struct dev_node_t {
 typedef struct dev_link_t {
     dev_node_t         *dev;
     u_int              state, open;
-    wait_queue_head_t  pending;
     client_handle_t    handle;
     io_req_t           io;
     irq_req_t          irq;
@@ -131,12 +130,15 @@ typedef struct dev_link_t {
 
 
 struct pcmcia_socket;
+struct config_t;
 
 struct pcmcia_driver {
-       dev_link_t              *(*attach)(void);
-       int (*event)            (event_t event, int priority,
-                                event_callback_args_t *);
-       void                    (*detach)(dev_link_t *);
+       int (*probe)            (struct pcmcia_device *dev);
+       void (*remove)          (struct pcmcia_device *dev);
+
+       int (*suspend)          (struct pcmcia_device *dev);
+       int (*resume)           (struct pcmcia_device *dev);
+
        struct module           *owner;
        struct pcmcia_device_id *id_table;
        struct device_driver    drv;
@@ -151,18 +153,20 @@ struct pcmcia_device {
           uniquely define a pcmcia_device */
        struct pcmcia_socket    *socket;
 
+       char                    *devname;
+
        u8                      device_no;
 
        /* the hardware "function" device; certain subdevices can
         * share one hardware "function" device. */
        u8                      func;
+       struct config_t*        function_config;
 
        struct list_head        socket_device_list;
 
        /* deprecated, a cleaned up version will be moved into this
           struct soon */
        dev_link_t              *instance;
-       event_callback_args_t   event_callback_args;
        u_int                   state;
 
        /* information about this device */
@@ -191,6 +195,8 @@ struct pcmcia_device {
 #define handle_to_pdev(handle) (handle)
 #define handle_to_dev(handle) (handle->dev)
 
+#define dev_to_instance(dev) (dev->instance)
+
 /* error reporting */
 void cs_error(client_handle_t handle, int func, int ret);