* [PATCH] video: stm32-ltdc: reset the controller on probe
@ 2026-09-28 9:55 Ahmad Fatoum
0 siblings, 0 replies; only message in thread
From: Ahmad Fatoum @ 2026-09-28 9:55 UTC (permalink / raw)
To: barebox; +Cc: Ahmad Fatoum
Linux resets the LTDC on probe. Let's do the same in barebox, so
a chainloaded barebox doesn't attempt reconfiguration of the DSI host
while the LTDC is still streaming to it.
Tested by chainloading the generic BL33 image on an STM32MP157C-DK2 and
observing it doesn't hang when framebuffer support is enabled.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
drivers/video/stm32_ltdc.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/video/stm32_ltdc.c b/drivers/video/stm32_ltdc.c
index 43d443788364..5165bbf01749 100644
--- a/drivers/video/stm32_ltdc.c
+++ b/drivers/video/stm32_ltdc.c
@@ -272,6 +272,10 @@ static int ltdc_probe(struct device *dev)
if (IS_ERR(hw->pclk))
return dev_errp_probe(dev, hw->pclk, "peripheral clock get\n");
+ ret = device_reset_us(dev, 10);
+ if (ret)
+ return dev_err_probe(dev, ret, "peripheral reset\n");
+
for_each_available_child_of_node(dev->of_node, np) {
struct ltdc_fb *priv;
struct of_endpoint ep;
--
2.47.3
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-09-28 10:48 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-28 9:55 [PATCH] video: stm32-ltdc: reset the controller on probe Ahmad Fatoum
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox