Input: uinput - rework ABS validation
authorDavid Herrmann <dh.herrmann@gmail.com>
Sun, 25 Oct 2015 09:34:13 +0000 (10:34 +0100)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Sat, 19 Dec 2015 01:48:51 +0000 (17:48 -0800)
commitfbae10db094046dba1d59e1c2ee5140835045f14
treef9129de6b266dada624d4bbce5457ed87fb42630
parent052876f8e5aec887d22c4d06e54aa5531ffcec75
Input: uinput - rework ABS validation

Rework the uinput ABS validation to check passed absinfo data immediately,
but do ABS initialization as last step in UI_DEV_CREATE. The behavior
observed by user-space is not changed, as ABS initialization was never
checked for errors.

With this in place, the order of device initialization and abs
configuration is no longer fixed. Userspace can initialize the device and
afterwards set absinfo just fine.

Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Tested-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/misc/uinput.c
include/uapi/linux/uinput.h