dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 1/4] fbtft: Replace custom ->reset() with generic one
@ 2021-04-16 14:20 Andy Shevchenko
  2021-04-16 14:20 ` [PATCH v2 2/4] fbtft: Rectify GPIO handling Andy Shevchenko
                   ` (4 more replies)
  0 siblings, 5 replies; 7+ messages in thread
From: Andy Shevchenko @ 2021-04-16 14:20 UTC (permalink / raw)
  To: Andy Shevchenko, dri-devel, linux-fbdev, linux-staging, linux-kernel
  Cc: Greg Kroah-Hartman

The custom ->reset() repeats the generic one, replace it.

Note, in newer kernels the context of the function is a sleeping one,
it's fine to switch over to the sleeping functions. Keeping the reset
line asserted longer than 20 microseconds is also okay, it's an idling
state of the hardware.

Fixes: b2ebd4be6fa1 ("staging: fbtft: add fb_agm1264k-fl driver")
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
v2: new patch split from the bigger fix (Greg)
 drivers/staging/fbtft/fb_agm1264k-fl.c | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/drivers/staging/fbtft/fb_agm1264k-fl.c b/drivers/staging/fbtft/fb_agm1264k-fl.c
index eeeeec97ad27..4dfc22d05a40 100644
--- a/drivers/staging/fbtft/fb_agm1264k-fl.c
+++ b/drivers/staging/fbtft/fb_agm1264k-fl.c
@@ -77,19 +77,6 @@ static int init_display(struct fbtft_par *par)
 	return 0;
 }
 
-static void reset(struct fbtft_par *par)
-{
-	if (!par->gpio.reset)
-		return;
-
-	dev_dbg(par->info->device, "%s()\n", __func__);
-
-	gpiod_set_value(par->gpio.reset, 0);
-	udelay(20);
-	gpiod_set_value(par->gpio.reset, 1);
-	mdelay(120);
-}
-
 /* Check if all necessary GPIOS defined */
 static int verify_gpios(struct fbtft_par *par)
 {
@@ -439,7 +426,6 @@ static struct fbtft_display display = {
 		.set_addr_win = set_addr_win,
 		.verify_gpios = verify_gpios,
 		.request_gpios_match = request_gpios_match,
-		.reset = reset,
 		.write = write,
 		.write_register = write_reg8_bus8,
 		.write_vmem = write_vmem,
-- 
2.30.2

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-04-27 12:10 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-16 14:20 [PATCH v2 1/4] fbtft: Replace custom ->reset() with generic one Andy Shevchenko
2021-04-16 14:20 ` [PATCH v2 2/4] fbtft: Rectify GPIO handling Andy Shevchenko
2021-04-16 14:20 ` [PATCH v2 3/4] fbtft: Don't spam logs when probe is deferred Andy Shevchenko
2021-04-16 14:20 ` [PATCH v2 4/4] fbtft: Update TODO Andy Shevchenko
2021-04-17  7:18 ` [PATCH v2 1/4] fbtft: Replace custom ->reset() with generic one Fabio Aiuto
2021-04-27 11:07 ` Greg Kroah-Hartman
2021-04-27 12:10   ` Andy Shevchenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).