All of lore.kernel.org
 help / color / mirror / Atom feed
From: abhinavk@codeaurora.org
To: Marijn Suijten <marijn.suijten@somainline.org>
Cc: dri-devel@lists.freedesktop.org, linux-arm-msm@vger.kernel.org,
	swboyd@chromium.org, khsieh@codeaurora.org,
	seanpaul@chromium.org, dmitry.baryshkov@linaro.org,
	aravindh@codeaurora.org, freedreno@lists.freedesktop.org
Subject: Re: [Freedreno] [PATCH] drm/msm/dsi: add support for dsi test pattern generator
Date: Tue, 10 Aug 2021 16:24:26 -0700	[thread overview]
Message-ID: <82699a2eb95fa619e772551f2a500921@codeaurora.org> (raw)
In-Reply-To: <1cc300dc-7647-0431-fe05-d5504c337652@somainline.org>

Hi Marijn

Thanks for reviewing and testing the latest patchset.

On 2021-08-10 15:59, Marijn Suijten wrote:
> Hi Abhinav,
> 
> On 7/16/21 2:01 AM, abhinavk@codeaurora.org wrote:
>> Hi Marijn
>> 
>> Sorry for the late response.
> 
> 
> Apologies from my side as well.
> 
> [...]
> 
>>>> +static void msm_dsi_host_cmd_test_pattern_setup(struct msm_dsi_host
>>>> *msm_host)
>>>> +{
>>>> +	u32 reg;
>>>> +
>>>> +	reg = dsi_read(msm_host, REG_DSI_TEST_PATTERN_GEN_CTRL);
>>>> +
>>>> +	dsi_write(msm_host, REG_DSI_TEST_PATTERN_GEN_CMD_MDP_INIT_VAL0,
>>>> 0xff);
>>>> +
>>>> +	reg |= (0x3 << 0x8);
>>>> +	dsi_write(msm_host, REG_DSI_TEST_PATTERN_GEN_CTRL, reg);
>>>> +	/* draw checkered rectangle pattern */
>>>> +	dsi_write(msm_host, REG_DSI_TPG_MAIN_CONTROL2, (0x1 << 0x7));
>>> 
>>> 
>>> How about BIT(7)?
>> 
>> You mean BIT(7) of REG_DSI_TPG_MAIN_CONTROL2? Thats what this is 
>> right?
>> Did you mean some other bit?
> 
> 
> I meant to replace (0x1 << 0x7) with BIT(7), but replacing it with
> DSI_TPG_MAIN_CONTROL2_CMD_MDP0_CHECKERED_RECTANGLE_PATTERN is even
> better, thanks.
> 
>> 
>>> 
>>> On SM6125 this seems to change the color intensity of the pattern; it
>>> is always colored lines of a few pixels wide alternating R, B and G
>>> from left to right.  Is it possible to document the meaning and
>>> available values of these registers, especially if they differ 
>>> between
>>> SoC / DSI block?
>>> 
>> 
>> I have requested access for SM6125, will check this register on that 
>> to
>> see if there
>> is any difference.
>> 
>> Are you saying you are not seeing a rectangular checkered pattern 
>> while
>> testing?
> 
> 
> Correct.  It's fixed now, and this patch already proves its
> usefulness!  We had two minor configuration issues, and are now seeing
> the squares just like on the other SoCs.  Meaning we can finally move
> on to configuring the DPU, thanks!
> 

Thats good to know !

>> Also are you testing on command mode or video mode?
> 
> 
> Command mode, if it's still worth anything.
Thats good to know too, as I had not been able to test command mode.
> 
>> As requested by Rob, I will add the bit definitions and update the
>> dsi.xml.h in the
>> next patchset for the registers and the bits which I am using here.
>> 
>> With that the meaning of these bits will be more clear.
>> 
>> I dont think I will be able to document all the bits because the goal 
>> of
>> this patch
>> was only to draw a test pattern to help with validation. Different 
>> bits
>> of the REG_DSI_TPG_MAIN_CONTROL2
>> register only draw different patterns so the goal wasnt that we can 
>> draw
>> any pattern, it was just to
>> draw some pattern on the screen.
>> 
>> When we add support for all other patterns, we can expose those bits 
>> as
>> well but it should not
>> be required in my opinion.
> 
> 
> Understandable.  I'm curious if other patterns are useful in certain
> situations, like DSC?  Other than that, knowing that the DSI and PHY
> is correct is good enough for us.

The TPG in this patch is only for the DSI block which is after the DSC 
block.
So any pattern we pick from the DSI_TPG_MAIN_CONTROL2 register (using 
any other bit)
will only look different visually but will still be from DSI and no 
other block.
So it will not help to validate DSC block individually.

> 
>> 
>>> Kind regards,
>>> Marijn
>>> 
>>>> +	DBG("Cmd test pattern setup done\n");
>>>> +}
>>> [...]
> 
> 
> Thanks!
> Marijn

  reply	other threads:[~2021-08-10 23:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-29 19:04 [PATCH] drm/msm/dsi: add support for dsi test pattern generator Abhinav Kumar
2021-06-29 19:04 ` Abhinav Kumar
2021-06-29 20:58 ` Dmitry Baryshkov
2021-06-29 20:58   ` Dmitry Baryshkov
2021-07-13  9:10 ` Marijn Suijten
2021-07-13  9:10   ` Marijn Suijten
2021-07-16  0:01   ` abhinavk
2021-07-16  0:01     ` abhinavk
2021-08-10 22:59     ` Marijn Suijten
2021-08-10 23:24       ` abhinavk [this message]
2021-07-13 16:47 ` [Freedreno] " Rob Clark
2021-07-13 16:47   ` Rob Clark

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=82699a2eb95fa619e772551f2a500921@codeaurora.org \
    --to=abhinavk@codeaurora.org \
    --cc=aravindh@codeaurora.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=freedreno@lists.freedesktop.org \
    --cc=khsieh@codeaurora.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=marijn.suijten@somainline.org \
    --cc=seanpaul@chromium.org \
    --cc=swboyd@chromium.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.