OSDN Git Service

gpio: fix line flag validation in linehandle_create
authorKent Gibson <warthog618@gmail.com>
Mon, 9 Sep 2019 03:22:18 +0000 (03:22 +0000)
committerBartosz Golaszewski <bgolaszewski@baylibre.com>
Mon, 9 Sep 2019 08:01:55 +0000 (10:01 +0200)
commite95fbc130a162ba9ad956311b95aa0da269eea48
tree2c4fbb24ea635835e3729d193e7adb3987218932
parent59929d3a2eb6c4abafc5b61a20c98aa8728ec378
gpio: fix line flag validation in linehandle_create

linehandle_create should not allow both GPIOHANDLE_REQUEST_INPUT
and GPIOHANDLE_REQUEST_OUTPUT to be set.

Fixes: d7c51b47ac11 ("gpio: userspace ABI for reading/writing GPIO lines")
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Kent Gibson <warthog618@gmail.com>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
drivers/gpio/gpiolib.c