mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-04-08 07:29:14 +08:00
drm/panel: ronbo-rb070d30: fix warning with gpio controllers that sleep
The ronbo-rb070d30 controles the various gpios for reset, standby, vertical and horizontal flip using the non-sleeping gpiod_set_value() function. Switch to using gpiod_set_value_cansleep() when controlling reset_gpio to support GPIO providers that may sleep, such as I2C GPIO expanders. This fixes noisy complaints in kernel log for gpio providers that do sleep. Signed-off-by: Josua Mayer <josua@solid-run.com> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org> Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org> Link: https://patch.msgid.link/20251117-imx8mp-hb-iiot-v3-5-bf1a4cf5fa8e@solid-run.com
This commit is contained in:
committed by
Neil Armstrong
parent
72539c4b9e
commit
93f5a0dc2b
@@ -54,9 +54,9 @@ static int rb070d30_panel_prepare(struct drm_panel *panel)
|
||||
}
|
||||
|
||||
msleep(20);
|
||||
gpiod_set_value(ctx->gpios.power, 1);
|
||||
gpiod_set_value_cansleep(ctx->gpios.power, 1);
|
||||
msleep(20);
|
||||
gpiod_set_value(ctx->gpios.reset, 1);
|
||||
gpiod_set_value_cansleep(ctx->gpios.reset, 1);
|
||||
msleep(20);
|
||||
return 0;
|
||||
}
|
||||
@@ -65,8 +65,8 @@ static int rb070d30_panel_unprepare(struct drm_panel *panel)
|
||||
{
|
||||
struct rb070d30_panel *ctx = panel_to_rb070d30_panel(panel);
|
||||
|
||||
gpiod_set_value(ctx->gpios.reset, 0);
|
||||
gpiod_set_value(ctx->gpios.power, 0);
|
||||
gpiod_set_value_cansleep(ctx->gpios.reset, 0);
|
||||
gpiod_set_value_cansleep(ctx->gpios.power, 0);
|
||||
regulator_disable(ctx->supply);
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user