]> www.infradead.org Git - users/dwmw2/linux.git/commit
Staging: fbtft: Fix reset assertion when using gpio descriptor
authorPhil Reid <preid@electromag.com.au>
Tue, 16 Jul 2019 00:24:37 +0000 (08:24 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 Aug 2019 08:10:51 +0000 (10:10 +0200)
commit1dd12a5a8d3875ab6ac96afd89d21fe750a614a4
treeb3ca52173a79e4f6babe787b05486ce26f32d14d
parent3558601e5bf93c153065fd8616d89d807600b566
Staging: fbtft: Fix reset assertion when using gpio descriptor

commit b918d1c2706619cb0712a61cc8c05148b68b24b2 upstream.

Typically gpiod_set_value calls would assert the reset line and
then release it using the symantics of:
gpiod_set_value(par->gpio.reset, 0);
... delay
gpiod_set_value(par->gpio.reset, 1);
And the gpio binding would specify the polarity.

Prior to conversion to gpiod calls the polarity in the DT
was ignored and assumed to be active low. Fix it so that
DT polarity is respected.

Fixes: c440eee1a7a1 ("Staging: fbtft: Switch to the gpio descriptor interface")
Reviewed-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Tested-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Tested-by: Jan Sebastian Götte <linux@jaseg.net>
Signed-off-by: Phil Reid <preid@electromag.com.au>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/1563236677-5045-3-git-send-email-preid@electromag.com.au
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/fbtft/fbtft-core.c