]> git.baikalelectronics.ru Git - kernel.git/commit
extcon: ptn5150: Fix usage of atomic GPIO with sleeping GPIO chips
authorKrzysztof Kozlowski <krzk@kernel.org>
Mon, 17 Aug 2020 07:00:00 +0000 (09:00 +0200)
committerChanwoo Choi <cw00.choi@samsung.com>
Thu, 24 Sep 2020 10:20:47 +0000 (19:20 +0900)
commit13f67503ce26ac3ccb5c4a70ae6bb27214ac9f91
tree5cd05a40f25968d5d0e07b8999a671ad141c9db8
parentb1e9dffdf6e1a2245b77a8a1a6c0e1c546e6cf5a
extcon: ptn5150: Fix usage of atomic GPIO with sleeping GPIO chips

The driver uses atomic version of gpiod_set_value() without any real
reason.  It is called in a workqueue under mutex so it could sleep
there.  Changing it to "can_sleep" flavor allows to use the driver with
all GPIO chips.

Fixes: 81cc002572d2 ("extcon: Add support for ptn5150 extcon driver")
Cc: <stable@vger.kernel.org>
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Reviewed-by: Vijai Kumar K <vijaikumar.kanagarajan@gmail.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
drivers/extcon/extcon-ptn5150.c