[PATCH] drm/panel: JDI LT070ME05000 remove useless warning
Sam Ravnborg
sam at ravnborg.org
Sun Feb 6 19:26:50 UTC 2022
Hi David,
On Sun, Feb 06, 2022 at 08:07:02PM +0100, David Heidelberg wrote:
> Do as most of panel and in case of deffered probe, don't print error.
>
> Fixes warning:
> panel-jdi-lt070me05000 4700000.dsi.0: cannot get enable-gpio -517
>
> Signed-off-by: David Heidelberg <david at ixit.cz>
> ---
> drivers/gpu/drm/panel/panel-jdi-lt070me05000.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/panel/panel-jdi-lt070me05000.c b/drivers/gpu/drm/panel/panel-jdi-lt070me05000.c
> index ea0e7221e706..b5c0b51dc146 100644
> --- a/drivers/gpu/drm/panel/panel-jdi-lt070me05000.c
> +++ b/drivers/gpu/drm/panel/panel-jdi-lt070me05000.c
> @@ -408,7 +408,8 @@ static int jdi_panel_add(struct jdi_panel *jdi)
> jdi->enable_gpio = devm_gpiod_get(dev, "enable", GPIOD_OUT_LOW);
> if (IS_ERR(jdi->enable_gpio)) {
> ret = PTR_ERR(jdi->enable_gpio);
> - dev_err(dev, "cannot get enable-gpio %d\n", ret);
> + if (ret != -EPROBE_DEFER)
> + dev_err(dev, "cannot get enable-gpio %d\n", ret);
> return ret;
> }
Thanks for submitting a fix for this.
Please look into the use of dev_err_probe() for this as this is the
preferred way to fix it now.
Sam
More information about the dri-devel
mailing list