diff options
author | Alan Ott <alan@signal11.us> | 2011-01-04 06:37:22 +0100 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2011-01-04 11:21:28 +0100 |
commit | ae5e49c79c051ea1d5ca91cbd4a0d22189067ba3 (patch) | |
tree | 06db2f9f459515ee6e2cc74721108e718d8a6afc /drivers/hid/hidraw.c | |
parent | HID: usbhid: base runtime PM on modern API (diff) | |
download | linux-ae5e49c79c051ea1d5ca91cbd4a0d22189067ba3.tar.xz linux-ae5e49c79c051ea1d5ca91cbd4a0d22189067ba3.zip |
HID: hidraw: add compatibility ioctl() for 32-bit applications.
Added the ioctl function to the compat_ioctl pointer in the file_operations
struct. Before this, some ioctls would fail for 32-bit apps on 64-bit systems.
Signed-off-by: Alan Ott <alan@signal11.us>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hidraw.c')
-rw-r--r-- | drivers/hid/hidraw.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c index 68d087f63c02..468e87b53ed2 100644 --- a/drivers/hid/hidraw.c +++ b/drivers/hid/hidraw.c @@ -344,6 +344,9 @@ static const struct file_operations hidraw_ops = { .open = hidraw_open, .release = hidraw_release, .unlocked_ioctl = hidraw_ioctl, +#ifdef CONFIG_COMPAT + .compat_ioctl = hidraw_ioctl, +#endif .llseek = noop_llseek, }; |