Commit 15d0a873 authored by Marc Zyngier's avatar Marc Zyngier Committed by Dominik Brodowski

pcmcia: fix compilation after 16bit state locking changes

Commit 04de0816 (pcmcia: pcmcia_dev_present bugfix) broke the
deprecated ioctl layer. Fix it by getting rid of references to
unexisting fields.
Signed-off-by: default avatarMarc Zyngier <maz@misterjones.org>
Reported-by: default avatarPavel Machek <pavel@ucw.cz>
Signed-off-by: default avatarDominik Brodowski <linux@dominikbrodowski.net>
parent 43821242
...@@ -711,7 +711,7 @@ static int ds_open(struct inode *inode, struct file *file) ...@@ -711,7 +711,7 @@ static int ds_open(struct inode *inode, struct file *file)
warning_printed = 1; warning_printed = 1;
} }
if (s->pcmcia_state.present) if (atomic_read(&s->present))
queue_event(user, CS_EVENT_CARD_INSERTION); queue_event(user, CS_EVENT_CARD_INSERTION);
out: out:
unlock_kernel(); unlock_kernel();
...@@ -770,9 +770,6 @@ static ssize_t ds_read(struct file *file, char __user *buf, ...@@ -770,9 +770,6 @@ static ssize_t ds_read(struct file *file, char __user *buf,
return -EIO; return -EIO;
s = user->socket; s = user->socket;
if (s->pcmcia_state.dead)
return -EIO;
ret = wait_event_interruptible(s->queue, !queue_empty(user)); ret = wait_event_interruptible(s->queue, !queue_empty(user));
if (ret == 0) if (ret == 0)
ret = put_user(get_queued_event(user), (int __user *)buf) ? -EFAULT : 4; ret = put_user(get_queued_event(user), (int __user *)buf) ? -EFAULT : 4;
...@@ -838,8 +835,6 @@ static int ds_ioctl(struct inode *inode, struct file *file, ...@@ -838,8 +835,6 @@ static int ds_ioctl(struct inode *inode, struct file *file,
return -EIO; return -EIO;
s = user->socket; s = user->socket;
if (s->pcmcia_state.dead)
return -EIO;
size = (cmd & IOCSIZE_MASK) >> IOCSIZE_SHIFT; size = (cmd & IOCSIZE_MASK) >> IOCSIZE_SHIFT;
if (size > sizeof(ds_ioctl_arg_t)) if (size > sizeof(ds_ioctl_arg_t))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment