[PATCH 3/3] drm/mipi: use dcs write for mipi_dsi_dcs_set_tear_scanline

Vinay Simha B N simhavcs at gmail.com
Thu May 7 12:29:16 UTC 2020


Emil,

Reply inline

On Tue, 5 May 2020 at 9:35 PM, Emil Velikov <emil.l.velikov at gmail.com>
wrote:

> From: Emil Velikov <emil.velikov at collabora.com>
>
> The helper uses the MIPI_DCS_SET_TEAR_SCANLINE, although it's currently
> using the generic write. This does not look right.
>
> Perhaps some platforms don't distinguish between the two writers?
>
> Cc: Robert Chiras <robert.chiras at nxp.com>
> Cc: Vinay Simha BN <simhavcs at gmail.com>
> Cc: Jani Nikula <jani.nikula at intel.com>
> Cc: Thierry Reding <treding at nvidia.com>
> Fixes: e83950816367 ("drm/dsi: Implement set tear scanline")
> Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
> ---
> Robert, can you please test this against the only user - the Raydium
> RM67191 panel driver that you introduced.
>
> Thanks
>
> Vinay, can you confirm if this is a genuine typo or there's something
> really subtle happening.

this has been tested on nexus 7 with jdi panel. I did not understand what
is the typo here?
We need to use DC’s write instead of generic write?

>
> ---
>  drivers/gpu/drm/drm_mipi_dsi.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_mipi_dsi.c
> b/drivers/gpu/drm/drm_mipi_dsi.c
> index b96d5b4629d7..07102d8da58f 100644
> --- a/drivers/gpu/drm/drm_mipi_dsi.c
> +++ b/drivers/gpu/drm/drm_mipi_dsi.c
> @@ -1082,11 +1082,11 @@ EXPORT_SYMBOL(mipi_dsi_dcs_set_pixel_format);
>   */
>  int mipi_dsi_dcs_set_tear_scanline(struct mipi_dsi_device *dsi, u16
> scanline)
>  {
> -       u8 payload[3] = { MIPI_DCS_SET_TEAR_SCANLINE, scanline >> 8,
> -                         scanline & 0xff };
> +       u8 payload[2] = { scanline >> 8, scanline & 0xff };
>         ssize_t err;
>
> -       err = mipi_dsi_generic_write(dsi, payload, sizeof(payload));
> +       err = mipi_dsi_dcs_write(dsi, MIPI_DCS_SET_TEAR_SCANLINE, payload,
> +                                sizeof(payload));
>         if (err < 0)
>                 return err;
>
> --
> 2.25.1
>
> --
regards,
vinaysimha
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20200507/d0f1760c/attachment-0001.htm>


More information about the dri-devel mailing list