Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/panel: boe-tv101wum-nl6: Check for errors on the NOP in prepare()

The mipi_dsi_dcs_nop() function returns an error but we weren't
checking it in boe_panel_prepare(). Add a check. This is highly
unlikely to matter in practice. If the NOP failed then likely later
MIPI commands would fail too.

Found by code inspection.

Fixes: 812562b8d881 ("drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence")
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20240517143643.3.Ibffbaa5b4999ac0e55f43bf353144433b099d727@changeid
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20240517143643.3.Ibffbaa5b4999ac0e55f43bf353144433b099d727@changeid

authored by

Douglas Anderson and committed by
Neil Armstrong
6320b919 587c48f6

+5 -1
+5 -1
drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
··· 1456 1456 usleep_range(10000, 11000); 1457 1457 1458 1458 if (boe->desc->lp11_before_reset) { 1459 - mipi_dsi_dcs_nop(boe->dsi); 1459 + ret = mipi_dsi_dcs_nop(boe->dsi); 1460 + if (ret < 0) { 1461 + dev_err(&boe->dsi->dev, "Failed to send NOP: %d\n", ret); 1462 + goto poweroff; 1463 + } 1460 1464 usleep_range(1000, 2000); 1461 1465 } 1462 1466 gpiod_set_value(boe->enable_gpio, 1);