diff options
author | Andy Lutomirski <luto@kernel.org> | 2016-03-22 22:25:24 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-03-22 23:36:02 +0100 |
commit | 7365abbade07f9181cbd013669642f129e9ec635 (patch) | |
tree | bb0649b06ba54f11ab41f2c03f63465bed771e8d /drivers/hid | |
parent | input: redefine INPUT_COMPAT_TEST as in_compat_syscall() (diff) | |
download | linux-7365abbade07f9181cbd013669642f129e9ec635.tar.xz linux-7365abbade07f9181cbd013669642f129e9ec635.zip |
drivers/hid/uhid.c: check write() bitness using in_compat_syscall
uhid changes the format expected in write() depending on bitness. It
should check the syscall bitness directly.
Signed-off-by: Andy Lutomirski <luto@kernel.org>
Cc: David Herrmann <dh.herrmann@googlemail.com>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/hid')
-rw-r--r-- | drivers/hid/uhid.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/uhid.c b/drivers/hid/uhid.c index e094c572b86e..16b6f11a0700 100644 --- a/drivers/hid/uhid.c +++ b/drivers/hid/uhid.c @@ -384,7 +384,7 @@ struct uhid_create_req_compat { static int uhid_event_from_user(const char __user *buffer, size_t len, struct uhid_event *event) { - if (is_compat_task()) { + if (in_compat_syscall()) { u32 type; if (get_user(type, buffer)) |