[PATCH] pcmcia: use bitfield instead of p_state and state
[deliverable/linux.git] / drivers / pcmcia / pcmcia_ioctl.c
index 2b11a332175e339fe2b9f6e8c8e8cc7623a24e1d..c53db7ceda5e2ab12770964dc18216fa819ab4c8 100644 (file)
@@ -304,6 +304,7 @@ static int get_device_info(struct pcmcia_socket *s, bind_info_t *bind_info, int
 {
        dev_node_t *node;
        struct pcmcia_device *p_dev;
+       struct pcmcia_driver *p_drv;
        unsigned long flags;
        int ret = 0;
 
@@ -358,7 +359,8 @@ static int get_device_info(struct pcmcia_socket *s, bind_info_t *bind_info, int
  found:
        spin_unlock_irqrestore(&pcmcia_dev_list_lock, flags);
 
-       if (p_dev->state & DEV_CONFIG_PENDING) {
+       p_drv = to_pcmcia_drv(p_dev->dev.driver);
+       if (p_drv && !p_dev->_locked) {
                ret = -EAGAIN;
                goto err_put;
        }
This page took 0.027051 seconds and 5 git commands to generate.