[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20180704144039eucas1p1fa0fd905d195acd4f37f3f457c7ab826~_MWZx9wta1767417674eucas1p1x@eucas1p1.samsung.com>
Date: Wed, 4 Jul 2018 16:40:23 +0200
From: Andrzej Hajda <a.hajda@...sung.com>
To: Maciej Purski <m.purski@...sung.com>,
dri-devel@...ts.freedesktop.org
Cc: Archit Taneja <architt@...eaurora.org>,
Laurent Pinchart <Laurent.pinchart@...asonboard.com>,
David Airlie <airlied@...ux.ie>,
Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
Marek Szyprowski <m.szyprowski@...sung.com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 3/3] drm/bridge/sii8620: Fix link mode selection
On 28.06.2018 18:44, Maciej Purski wrote:
> Current link mode values do not allow to enable packed pixel modes.
>
> Select packed pixel clock mode, if needed, every time the link mode
> register gets updated.
>
> Signed-off-by: Maciej Purski <m.purski@...sung.com>
Queued all three patches to drm-misc-fixes.
Regards
Andrzej
> ---
> drivers/gpu/drm/bridge/sil-sii8620.c | 30 ++++++++++++++++++++----------
> 1 file changed, 20 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/sil-sii8620.c b/drivers/gpu/drm/bridge/sil-sii8620.c
> index 16fe7ea..a6e8f45 100644
> --- a/drivers/gpu/drm/bridge/sil-sii8620.c
> +++ b/drivers/gpu/drm/bridge/sil-sii8620.c
> @@ -1165,8 +1165,14 @@ static void sii8620_start_video(struct sii8620 *ctx)
> sii8620_set_format(ctx);
>
> if (!sii8620_is_mhl3(ctx)) {
> - sii8620_mt_write_stat(ctx, MHL_DST_REG(LINK_MODE),
> - MHL_DST_LM_CLK_MODE_NORMAL | MHL_DST_LM_PATH_ENABLED);
> + u8 link_mode = MHL_DST_LM_PATH_ENABLED;
> +
> + if (ctx->use_packed_pixel)
> + link_mode |= MHL_DST_LM_CLK_MODE_PACKED_PIXEL;
> + else
> + link_mode |= MHL_DST_LM_CLK_MODE_NORMAL;
> +
> + sii8620_mt_write_stat(ctx, MHL_DST_REG(LINK_MODE), link_mode);
> sii8620_set_auto_zone(ctx);
> } else {
> static const struct {
> @@ -1677,14 +1683,18 @@ static void sii8620_status_dcap_ready(struct sii8620 *ctx)
>
> static void sii8620_status_changed_path(struct sii8620 *ctx)
> {
> - if (ctx->stat[MHL_DST_LINK_MODE] & MHL_DST_LM_PATH_ENABLED) {
> - sii8620_mt_write_stat(ctx, MHL_DST_REG(LINK_MODE),
> - MHL_DST_LM_CLK_MODE_NORMAL
> - | MHL_DST_LM_PATH_ENABLED);
> - } else {
> - sii8620_mt_write_stat(ctx, MHL_DST_REG(LINK_MODE),
> - MHL_DST_LM_CLK_MODE_NORMAL);
> - }
> + u8 link_mode;
> +
> + if (ctx->use_packed_pixel)
> + link_mode = MHL_DST_LM_CLK_MODE_PACKED_PIXEL;
> + else
> + link_mode = MHL_DST_LM_CLK_MODE_NORMAL;
> +
> + if (ctx->stat[MHL_DST_LINK_MODE] & MHL_DST_LM_PATH_ENABLED)
> + link_mode |= MHL_DST_LM_PATH_ENABLED;
> +
> + sii8620_mt_write_stat(ctx, MHL_DST_REG(LINK_MODE),
> + link_mode);
> }
>
> static void sii8620_msc_mr_write_stat(struct sii8620 *ctx)
Powered by blists - more mailing lists