public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/sitronix/st7571-i2c: reset position before clearing display
@ 2025-09-13  6:09 Marcus Folkesson
  2025-09-17  9:32 ` Javier Martinez Canillas
  0 siblings, 1 reply; 6+ messages in thread
From: Marcus Folkesson @ 2025-09-13  6:09 UTC (permalink / raw)
  To: Javier Martinez Canillas, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, David Airlie, Simona Vetter
  Cc: dri-devel, linux-kernel, Marcus Folkesson

We cannot know where the write pointer is, always reset position to
(0,0) before clearing display.

Signed-off-by: Marcus Folkesson <marcus.folkesson@gmail.com>
---
 drivers/gpu/drm/sitronix/st7571-i2c.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/sitronix/st7571-i2c.c b/drivers/gpu/drm/sitronix/st7571-i2c.c
index a6c4a6738dedf5881328414e9d8810d3af2a6fe4..32b91d65b768b26caa7dcef42a00d36f236fbc32 100644
--- a/drivers/gpu/drm/sitronix/st7571-i2c.c
+++ b/drivers/gpu/drm/sitronix/st7571-i2c.c
@@ -263,6 +263,7 @@ static int st7571_fb_clear_screen(struct st7571_device *st7571)
 	u32 npixels = st7571->ncols * round_up(st7571->nlines, ST7571_PAGE_HEIGHT) * st7571->bpp;
 	char pixelvalue = 0x00;
 
+	st7571_set_position(st7571, 0, 0);
 	for (int i = 0; i < npixels; i++)
 		regmap_bulk_write(st7571->regmap, ST7571_DATA_MODE, &pixelvalue, 1);
 

---
base-commit: 91494dee1091a14d91da6bcb39e12a907765c793
change-id: 20250911-st7571-reset-785838285415

Best regards,
-- 
Marcus Folkesson <marcus.folkesson@gmail.com>


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

end of thread, other threads:[~2025-10-03 10:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-13  6:09 [PATCH] drm/sitronix/st7571-i2c: reset position before clearing display Marcus Folkesson
2025-09-17  9:32 ` Javier Martinez Canillas
2025-09-18  8:54   ` Marcus Folkesson
2025-09-18 11:07     ` Javier Martinez Canillas
2025-10-03  6:57       ` Marcus Folkesson
2025-10-03 10:04         ` Javier Martinez Canillas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox