From: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
To: Jessica Zhang <quic_jesszhan@quicinc.com>,
Marijn Suijten <marijn.suijten@somainline.org>,
phone-devel@vger.kernel.org,
Abhinav Kumar <quic_abhinavk@quicinc.com>,
Neil Armstrong <neil.armstrong@linaro.org>
Cc: ~postmarketos/upstreaming@lists.sr.ht,
AngeloGioacchino Del Regno
<angelogioacchino.delregno@somainline.org>,
Konrad Dybcio <konrad.dybcio@linaro.org>,
Martin Botka <martin.botka@somainline.org>,
Jami Kettunen <jami.kettunen@somainline.org>,
Rob Clark <robdclark@gmail.com>, Sean Paul <sean@poorly.run>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
Stephen Boyd <swboyd@chromium.org>, Vinod Koul <vkoul@kernel.org>,
Bjorn Andersson <andersson@kernel.org>,
Kuogee Hsieh <quic_khsieh@quicinc.com>,
Konrad Dybcio <konrad.dybcio@somainline.org>,
Loic Poulain <loic.poulain@linaro.org>,
Vinod Polimera <quic_vpolimer@quicinc.com>,
Adam Skladowski <a39.skl@gmail.com>,
linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH 5/7] drm/msm/dpu: Document and enable TEAR interrupts on DSI interfaces
Date: Mon, 13 Feb 2023 23:46:09 +0200 [thread overview]
Message-ID: <1051d6bd-eb3c-6293-0bd2-3f4ea28fa3f8@linaro.org> (raw)
In-Reply-To: <773cd72b-a766-1764-e25f-0af1174f0e51@quicinc.com>
On 13/02/2023 21:37, Jessica Zhang wrote:
>
>
> On 12/31/2022 1:50 PM, Marijn Suijten wrote:
>> All SoCs since DPU 5.0.0 (and seemingly up until and including 6.0.0,
>> but excluding 7.x.x) have the tear interrupt and control registers moved
>> out of the PINGPONG block and into the INTF block. Wire up the
>> necessary interrupts and IRQ masks on all supported hardware.
>
> Hi Marijn,
>
> Thanks for the patch.
>
> I saw that in your commit msg, you mentioned that 7.x doesn't have
> tearcheck in the INTF block -- can you double check that this is correct?
>
> I'm working on SM8350 (DPU v7) and I'm seeing that it does have
> tearcheck in INTF block.
I confirm, according to the vendor drivers INTF TE should be used for
all DPU >= 5.0, including 7.x and 8.x
However I think I know what Marijn meant here. For 5.x and 6.x these
IRQs are handled at the address MDSS + 0x6e800 / + 0x6e900 (which means
offset here should 0x6d800 and 0x6d900) for INTF_1 and INTF_2. Since DPU
7.x these IRQ registers were moved close to the main INTF block (0x36800
and 0x37800 = INTF + 0x800).
>
>>
>> Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org>
>> ---
>> .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 78 +++++++++++--------
>> .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h | 6 +-
>> .../gpu/drm/msm/disp/dpu1/dpu_hw_interrupts.c | 12 +++
>> .../gpu/drm/msm/disp/dpu1/dpu_hw_interrupts.h | 2 +
>> drivers/gpu/drm/msm/disp/dpu1/dpu_hwio.h | 3 +
>> 5 files changed, 68 insertions(+), 33 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
>> b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
>> index 1cfe94494135..b9b9b5b0b615 100644
>> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
>> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c
>> @@ -86,6 +86,15 @@
>> #define INTF_SC7280_MASK INTF_SC7180_MASK | BIT(DPU_DATA_HCTL_EN)
>> +#define IRQ_MSM8998_MASK (BIT(MDP_SSPP_TOP0_INTR) | \
>> + BIT(MDP_SSPP_TOP0_INTR2) | \
>> + BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> + BIT(MDP_INTF0_INTR) | \
>> + BIT(MDP_INTF1_INTR) | \
>> + BIT(MDP_INTF2_INTR) | \
>> + BIT(MDP_INTF3_INTR) | \
>> + BIT(MDP_INTF4_INTR))
>> +
>> #define IRQ_SDM845_MASK (BIT(MDP_SSPP_TOP0_INTR) | \
>> BIT(MDP_SSPP_TOP0_INTR2) | \
>> BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> @@ -100,13 +109,15 @@
>> #define IRQ_QCM2290_MASK (BIT(MDP_SSPP_TOP0_INTR) | \
>> BIT(MDP_SSPP_TOP0_INTR2) | \
>> BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> - BIT(MDP_INTF1_INTR))
>> + BIT(MDP_INTF1_INTR) | \
>> + BIT(MDP_INTF1_TEAR_INTR))
>> #define IRQ_SC7180_MASK (BIT(MDP_SSPP_TOP0_INTR) | \
>> BIT(MDP_SSPP_TOP0_INTR2) | \
>> BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> BIT(MDP_INTF0_INTR) | \
>> - BIT(MDP_INTF1_INTR))
>> + BIT(MDP_INTF1_INTR) | \
>> + BIT(MDP_INTF1_TEAR_INTR))
>> #define IRQ_SC7280_MASK (BIT(MDP_SSPP_TOP0_INTR) | \
>> BIT(MDP_SSPP_TOP0_INTR2) | \
>> @@ -120,7 +131,9 @@
>> BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> BIT(MDP_INTF0_INTR) | \
>> BIT(MDP_INTF1_INTR) | \
>> + BIT(MDP_INTF1_TEAR_INTR) | \
>> BIT(MDP_INTF2_INTR) | \
>> + BIT(MDP_INTF2_TEAR_INTR) | \
>> BIT(MDP_INTF3_INTR) | \
>> BIT(MDP_INTF4_INTR))
>> @@ -129,7 +142,9 @@
>> BIT(MDP_SSPP_TOP0_HIST_INTR) | \
>> BIT(MDP_INTF0_INTR) | \
>> BIT(MDP_INTF1_INTR) | \
>> + BIT(MDP_INTF1_TEAR_INTR) | \
>> BIT(MDP_INTF2_INTR) | \
>> + BIT(MDP_INTF2_TEAR_INTR) | \
>> BIT(MDP_INTF3_INTR) | \
>> BIT(MDP_INTF4_INTR) | \
>> BIT(MDP_INTF5_INTR) | \
>> @@ -1300,63 +1315,64 @@ static struct dpu_dsc_cfg sdm845_dsc[] = {
>> /*************************************************************
>> * INTF sub blocks config
>> *************************************************************/
>> -#define INTF_BLK(_name, _id, _base, _type, _ctrl_id, _progfetch,
>> _features, _reg, _underrun_bit, _vsync_bit) \
>> +#define INTF_BLK(_name, _id, _base, _len, _type, _ctrl_id,
>> _progfetch, _features, _reg, _underrun_bit, _vsync_bit, _tear_reg,
>> _tear_rd_ptr_bit) \
>> {\
>> .name = _name, .id = _id, \
>> - .base = _base, .len = 0x280, \
>> + .base = _base, .len = _len, \
>> .features = _features, \
>> .type = _type, \
>> .controller_id = _ctrl_id, \
>> .prog_fetch_lines_worst_case = _progfetch, \
>> .intr_underrun = DPU_IRQ_IDX(_reg, _underrun_bit), \
>> .intr_vsync = DPU_IRQ_IDX(_reg, _vsync_bit), \
>> + .intr_tear_rd_ptr = DPU_IRQ_IDX(_tear_reg, _tear_rd_ptr_bit), \
>> }
>> static const struct dpu_intf_cfg msm8998_intf[] = {
>> - INTF_BLK("intf_0", INTF_0, 0x6A000, INTF_DP, 0, 25,
>> INTF_SDM845_MASK, MDP_SSPP_TOP0_INTR, 24, 25),
>> - INTF_BLK("intf_1", INTF_1, 0x6A800, INTF_DSI, 0, 25,
>> INTF_SDM845_MASK, MDP_SSPP_TOP0_INTR, 26, 27),
>> - INTF_BLK("intf_2", INTF_2, 0x6B000, INTF_DSI, 1, 25,
>> INTF_SDM845_MASK, MDP_SSPP_TOP0_INTR, 28, 29),
>> - INTF_BLK("intf_3", INTF_3, 0x6B800, INTF_HDMI, 0, 25,
>> INTF_SDM845_MASK, MDP_SSPP_TOP0_INTR, 30, 31),
>> + INTF_BLK("intf_0", INTF_0, 0x6A000, 0x268, INTF_DP, 0, 25,
>> INTF_SDM845_MASK, MDP_SSPP_TOP0_INTR, 24, 25, -1, -1),
>
> Just wondering, how were the lengths calculated for the INTF blocks? The
> values in general seem a little off to me.
>
> For example, I'm looking downstream and it seems to me that the length
> for the INTF_0 on MSM8998 should be 0x280. Similarly for SC7280, I'm
> seeing that length for INTF + tearcheck should be 0x2c4.
We have discussed INTF lengths in [1]. The current understanding of the
block lengths can be found at [2]. Please comment there if any of the
fixed lengths sounds incorrect to you.
[1] https://patchwork.freedesktop.org/patch/522187/
[2] https://patchwork.freedesktop.org/patch/522227/
[skipped the rest]
--
With best wishes
Dmitry
next prev parent reply other threads:[~2023-02-13 21:46 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-31 21:49 [RFC PATCH 0/7] drm/msm/dpu: Implement tearcheck support on INTF block Marijn Suijten
2022-12-31 21:50 ` [RFC PATCH 1/7] drm/msm/dpu: Remove unused INTF0 interrupt mask from sm6115/qcm2290 Marijn Suijten
2023-01-01 4:18 ` Dmitry Baryshkov
2023-01-02 9:29 ` Konrad Dybcio
2023-01-02 10:12 ` Marijn Suijten
2022-12-31 21:50 ` [RFC PATCH 2/7] drm/msm/dpu: Disable pingpong TE on DPU 5.0.0 and above Marijn Suijten
2023-01-01 4:28 ` Dmitry Baryshkov
2023-01-02 10:25 ` Marijn Suijten
2023-01-02 14:02 ` Dmitry Baryshkov
2022-12-31 21:50 ` [RFC PATCH 3/7] drm/msm/dpu: Disable MDP vsync source selection " Marijn Suijten
2022-12-31 21:52 ` Marijn Suijten
2023-01-01 12:28 ` Dmitry Baryshkov
2023-01-02 9:30 ` Konrad Dybcio
2023-01-02 10:18 ` Marijn Suijten
2023-01-02 10:19 ` Konrad Dybcio
2022-12-31 21:50 ` [RFC PATCH 4/7] drm/msm/dpu: Move dpu_hw_{tear_check,pp_vsync_info} to dpu_hw_mdss.h Marijn Suijten
2023-01-01 12:37 ` Dmitry Baryshkov
2022-12-31 21:50 ` [RFC PATCH 5/7] drm/msm/dpu: Document and enable TEAR interrupts on DSI interfaces Marijn Suijten
2023-01-01 13:12 ` Dmitry Baryshkov
2023-01-02 10:38 ` Marijn Suijten
2023-02-13 19:37 ` Jessica Zhang
2023-02-13 21:46 ` Dmitry Baryshkov [this message]
2023-02-14 3:09 ` Abhinav Kumar
2023-02-14 13:06 ` Marijn Suijten
2023-02-14 17:54 ` Abhinav Kumar
2023-04-17 19:41 ` Marijn Suijten
2023-04-17 19:59 ` Abhinav Kumar
2022-12-31 21:50 ` [RFC PATCH 6/7] drm/msm/dpu: Implement tearcheck support on INTF block Marijn Suijten
2023-01-01 13:32 ` Dmitry Baryshkov
2023-01-02 11:06 ` Marijn Suijten
2023-01-02 15:48 ` Dmitry Baryshkov
2022-12-31 21:50 ` [RFC PATCH 7/7] drm/msm/dpu: Remove intr_rdptr from DPU >= 5.0.0 pingpong config Marijn Suijten
2023-01-01 12:27 ` Dmitry Baryshkov
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=1051d6bd-eb3c-6293-0bd2-3f4ea28fa3f8@linaro.org \
--to=dmitry.baryshkov@linaro.org \
--cc=a39.skl@gmail.com \
--cc=airlied@gmail.com \
--cc=andersson@kernel.org \
--cc=angelogioacchino.delregno@somainline.org \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=jami.kettunen@somainline.org \
--cc=konrad.dybcio@linaro.org \
--cc=konrad.dybcio@somainline.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loic.poulain@linaro.org \
--cc=marijn.suijten@somainline.org \
--cc=martin.botka@somainline.org \
--cc=neil.armstrong@linaro.org \
--cc=phone-devel@vger.kernel.org \
--cc=quic_abhinavk@quicinc.com \
--cc=quic_jesszhan@quicinc.com \
--cc=quic_khsieh@quicinc.com \
--cc=quic_vpolimer@quicinc.com \
--cc=robdclark@gmail.com \
--cc=sean@poorly.run \
--cc=swboyd@chromium.org \
--cc=vkoul@kernel.org \
--cc=~postmarketos/upstreaming@lists.sr.ht \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox