diff options
author | Ingo Molnar <mingo@elte.hu> | 2010-05-10 13:12:26 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-05-10 13:12:29 +0200 |
commit | 7c224a03a79021ab12ce057964df9e679af5386d (patch) | |
tree | 809dbf3bcb5978e7b1845eb4c46179f1c9405f0c /drivers/char/pcmcia/cm4000_cs.c | |
parent | oprofile/x86: remove duplicate IBS capability check (diff) | |
parent | Linux 2.6.34-rc7 (diff) | |
download | linux-7c224a03a79021ab12ce057964df9e679af5386d.tar.xz linux-7c224a03a79021ab12ce057964df9e679af5386d.zip |
Merge commit 'v2.6.34-rc7' into oprofile
Merge reason: Update to Linus's latest -rc.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/char/pcmcia/cm4000_cs.c')
-rw-r--r-- | drivers/char/pcmcia/cm4000_cs.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/char/pcmcia/cm4000_cs.c b/drivers/char/pcmcia/cm4000_cs.c index c9bc896d68af..90b199f97bec 100644 --- a/drivers/char/pcmcia/cm4000_cs.c +++ b/drivers/char/pcmcia/cm4000_cs.c @@ -1026,14 +1026,16 @@ static ssize_t cmm_read(struct file *filp, __user char *buf, size_t count, xoutb(0, REG_FLAGS1(iobase)); /* clear detectCMM */ /* last check before exit */ - if (!io_detect_cm4000(iobase, dev)) - count = -ENODEV; + if (!io_detect_cm4000(iobase, dev)) { + rc = -ENODEV; + goto release_io; + } if (test_bit(IS_INVREV, &dev->flags) && count > 0) str_invert_revert(dev->rbuf, count); if (copy_to_user(buf, dev->rbuf, count)) - return -EFAULT; + rc = -EFAULT; release_io: clear_bit(LOCK_IO, &dev->flags); |