]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
gpiolib: skip unwanted events, don't convert them to opposite edge
authorBartosz Golaszewski <brgl@bgdev.pl>
Mon, 3 Jul 2017 09:12:03 +0000 (11:12 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 11 Aug 2017 15:33:53 +0000 (08:33 -0700)
commit36af36b8ddf0cfa9291cacb7d52c0ab09ce7cef5
tree969e03d0ae4c01c39efab53b304728b28e7a51a2
parent9c944d1090651c6f75010574cfbbe03e045990f8
gpiolib: skip unwanted events, don't convert them to opposite edge

commit df1e76f28ffe87d1b065eecab2d0fbb89e6bdee5 upstream.

The previous fix for filtering out of unwatched events was not entirely
correct. Instead of skipping the events we don't want, they are now
interpreted as events with opposing edge.

In order to fix it: always read the GPIO line value on interrupt and
only emit the event if it corresponds with the event type we requested.

Fixes: ad537b822577 ("gpiolib: fix filtering out unwanted events")
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpio/gpiolib.c