Re: [PATCH v2 06/12] drm/msm/hdmi: drop unused GPIO support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Dmitry Baryshkov (2022-06-08 05:07:17)
> @@ -543,41 +529,16 @@ static int msm_hdmi_bind(struct device *dev, struct device *master, void *data)
>         hdmi_cfg->mmio_name     = "core_physical";
>         hdmi_cfg->qfprom_mmio_name = "qfprom_physical";
>
> -       for (i = 0; i < HDMI_MAX_NUM_GPIO; i++) {
[...]
> -               if (gpiod)
> -                       gpiod_set_consumer_name(gpiod, msm_hdmi_gpio_pdata[i].label);
> -               hdmi_cfg->gpios[i].output = msm_hdmi_gpio_pdata[i].output;
> -               hdmi_cfg->gpios[i].value = msm_hdmi_gpio_pdata[i].value;
> -       }
> +       hdmi->hpd_gpiod = devm_gpiod_get_optional(dev, "hpd", GPIOD_IN);
> +       /* This will catch e.g. -PROBE_DEFER */

EPROBE_DEFER?

> +       if (IS_ERR(hdmi->hpd_gpiod))
> +               return PTR_ERR(hdmi->hpd_gpiod);
> +
> +       if (!hdmi->hpd_gpiod)
> +               DBG("failed to get HPD gpio");

Does DBG() add newlines?

> +
> +       if (hdmi->hpd_gpiod)
> +               gpiod_set_consumer_name(hdmi->hpd_gpiod, "HDMI_HPD");
>
>         dev->platform_data = hdmi_cfg;
>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux