diff options
author | Shawn Bohrer <shawn.bohrer@gmail.com> | 2009-10-18 20:32:17 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-12-11 20:23:01 (GMT) |
commit | a6279bc9e4dfb30bef8e3e1f41df8e877ecd3e30 (patch) | |
tree | 71c8fab0da239a1763e8e568d7f4532e30652443 /drivers/staging/comedi/comedi_compat32.c | |
parent | 5d7ae225540a98b6ee7ab1447c6a1eed89c219cd (diff) | |
download | linux-a6279bc9e4dfb30bef8e3e1f41df8e877ecd3e30.tar.xz |
Staging: comedi: Don't check for -ENOIOCTLCMD
unlocked_ioctl() never returns -ENOIOCTLCMD so remove the check.
Signed-off-by: Shawn Bohrer <shawn.bohrer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/comedi/comedi_compat32.c')
-rw-r--r-- | drivers/staging/comedi/comedi_compat32.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/staging/comedi/comedi_compat32.c b/drivers/staging/comedi/comedi_compat32.c index 47cf0a1..a9fdcda 100644 --- a/drivers/staging/comedi/comedi_compat32.c +++ b/drivers/staging/comedi/comedi_compat32.c @@ -97,12 +97,9 @@ static int translated_ioctl(struct file *file, unsigned int cmd, if (!file->f_op) return -ENOTTY; - if (file->f_op->unlocked_ioctl) { - int rc = (int)(*file->f_op->unlocked_ioctl) (file, cmd, arg); - if (rc == -ENOIOCTLCMD) - rc = -ENOTTY; - return rc; - } + if (file->f_op->unlocked_ioctl) + return file->f_op->unlocked_ioctl(file, cmd, arg); + return -ENOTTY; } |