summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-02-11 23:05:55 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2010-02-11 23:05:55 +0100
commitfd48d6c888eb3eb3c7e94a8880c6121893bd17b8 (patch)
tree4138605892a02eda7501120c8047b34e5b8171b4 /fs
parentMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dto... (diff)
parent[SCSI] qla2xxx: Obtain proper host structure during response-queue processing. (diff)
downloadlinux-fd48d6c888eb3eb3c7e94a8880c6121893bd17b8.tar.xz
linux-fd48d6c888eb3eb3c7e94a8880c6121893bd17b8.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6: [SCSI] qla2xxx: Obtain proper host structure during response-queue processing. [SCSI] compat_ioct: fix bsg SG_IO [SCSI] qla2xxx: make msix interrupt handler safe for irq [SCSI] zfcp: Report FC BSG errors in correct field [SCSI] mptfusion : mptscsih_abort return value should be SUCCESS instead of value 0.
Diffstat (limited to 'fs')
-rw-r--r--fs/compat_ioctl.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c
index 30698a13fb22..0ca9ec4a79c3 100644
--- a/fs/compat_ioctl.c
+++ b/fs/compat_ioctl.c
@@ -301,6 +301,12 @@ static int sg_ioctl_trans(unsigned int fd, unsigned int cmd,
u32 data;
void __user *dxferp;
int err;
+ int interface_id;
+
+ if (get_user(interface_id, &sgio32->interface_id))
+ return -EFAULT;
+ if (interface_id != 'S')
+ return sys_ioctl(fd, cmd, (unsigned long)sgio32);
if (get_user(iovec_count, &sgio32->iovec_count))
return -EFAULT;