All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marijn Suijten <marijn.suijten@somainline.org>
To: phone-devel@vger.kernel.org, Rob Clark <robdclark@gmail.com>,
	Abhinav Kumar <quic_abhinavk@quicinc.com>,
	Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
	Vinod Koul <vkoul@kernel.org>
Cc: ~postmarketos/upstreaming@lists.sr.ht,
	"AngeloGioacchino Del Regno"
	<angelogioacchino.delregno@somainline.org>,
	"Konrad Dybcio" <konrad.dybcio@somainline.org>,
	"Martin Botka" <martin.botka@somainline.org>,
	"Jami Kettunen" <jami.kettunen@somainline.org>,
	"Marijn Suijten" <marijn.suijten@somainline.org>,
	"Sean Paul" <sean@poorly.run>, "David Airlie" <airlied@gmail.com>,
	"Daniel Vetter" <daniel@ffwll.ch>,
	"Stephen Boyd" <swboyd@chromium.org>,
	"Bjorn Andersson" <andersson@kernel.org>,
	"Jessica Zhang" <quic_jesszhan@quicinc.com>,
	"Ville Syrjälä" <ville.syrjala@linux.intel.com>,
	"Kuogee Hsieh" <quic_khsieh@quicinc.com>,
	"Jani Nikula" <jani.nikula@intel.com>,
	sunliming <sunliming@kylinos.cn>,
	"Sam Ravnborg" <sam@ravnborg.org>,
	"Haowen Bai" <baihaowen@meizu.com>,
	"Konrad Dybcio" <konrad.dybcio@linaro.org>,
	"Loic Poulain" <loic.poulain@linaro.org>,
	"Vinod Polimera" <quic_vpolimer@quicinc.com>,
	"Douglas Anderson" <dianders@chromium.org>,
	"Vladimir Lypak" <vladimir.lypak@gmail.com>,
	linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
	freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: [PATCH v2 0/8] drm/msm: DSC Electric Boogaloo for sm8[12]50
Date: Thu, 22 Dec 2022 00:19:35 +0100	[thread overview]
Message-ID: <20221221231943.1961117-1-marijn.suijten@somainline.org> (raw)

This preliminary Display Stream Compression support package for
(initially tested on) sm8[12]50 is based on comparing DSC behaviour
between downstream and mainline.  Some new callbacks are added (for
binding blocks on active CTLs), logic bugs are corrected, zeroed struct
members are now assigned proper values, and RM allocation and hw block
retrieval now hand out (or not) DSC blocks without causing null-pointer
dereferences.

Unfortunately it is not yet enough to get rid of completely corrupted
display output on the boards I tested here:
- Sony Xperia 1 (sm8150), 1644x3840 or 1096x2560 pixels;
- Sony Xperia 5II (sm8250), 1080x2520, at 60 or 120Hz;
- (can include more Xperia boards if desired)

Both devices use the DUALPIPE_DSCMERGE topology downstream: dual LM, PP
and DSC, but only a single INTF/encoder/DSI-link.

Hopefully this spawns some community/upstream interest to help rootcause
our corruption issues (after we open a drm/msm report on GitLab for more
appropriate tracking).

The Sony Xperia XZ3 (sdm845) was fully tested and validated with this
series to not cause any regressions (and one of the math fixes now
allows us to change slice_count in the panel driver, which would corrupt
previously).

Changes since v1:

- Split patch 6 into two separately backportable Fixes: patches;
- Additionally remove num_enc from msm_display_topology in favour of
  num_dsc;
- Reorder patches to have all Fixes: at the beginning for easier
  picking;
- Fix existing multiline comment while editing it anyway;
- Add missing Signed-off-by to patch 5.

v1: https://lore.kernel.org/linux-arm-msm/20221213232207.113607-1-marijn.suijten@somainline.org/T/#u

Marijn Suijten (8):
  drm/msm/dpu: Wire up DSC mask for active CTL configuration
  drm/msm/dsi: Use DSC slice(s) packet size to compute word count
  drm/msm/dsi: Flip greater-than check for slice_count and
    slice_per_intf
  drm/msm/dpu: Disallow unallocated resources to be returned
  drm/msm/dpu: Reject topologies for which no DSC blocks are available
  drm/msm/dpu: Remove num_enc from topology struct in favour of num_dsc
  drm/msm/dpu: Implement DSC binding to PP block for CTL V1
  drm/msm/dpu: Add DSC configuration for SM8150 and SM8250

 drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c   | 12 +++++----
 .../drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c  |  1 +
 .../drm/msm/disp/dpu1/dpu_encoder_phys_vid.c  |  1 +
 .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c    | 23 +++++++++++-----
 .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h    |  9 +++++++
 drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.c    | 27 +++++++++++++++++++
 drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.h    |  4 +++
 drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c        | 14 ++++++++--
 drivers/gpu/drm/msm/dsi/dsi_host.c            |  7 ++---
 drivers/gpu/drm/msm/msm_drv.h                 |  2 --
 10 files changed, 82 insertions(+), 18 deletions(-)

--
2.39.0


WARNING: multiple messages have this Message-ID (diff)
From: Marijn Suijten <marijn.suijten@somainline.org>
To: phone-devel@vger.kernel.org, Rob Clark <robdclark@gmail.com>,
	Abhinav Kumar <quic_abhinavk@quicinc.com>,
	Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
	Vinod Koul <vkoul@kernel.org>
Cc: Konrad Dybcio <konrad.dybcio@somainline.org>,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@somainline.org>,
	Marijn Suijten <marijn.suijten@somainline.org>,
	Vinod Polimera <quic_vpolimer@quicinc.com>,
	Haowen Bai <baihaowen@meizu.com>, Sam Ravnborg <sam@ravnborg.org>,
	Kuogee Hsieh <quic_khsieh@quicinc.com>,
	Jessica Zhang <quic_jesszhan@quicinc.com>,
	Jani Nikula <jani.nikula@intel.com>,
	linux-arm-msm@vger.kernel.org, Stephen Boyd <swboyd@chromium.org>,
	Martin Botka <martin.botka@somainline.org>,
	~postmarketos/upstreaming@lists.sr.ht,
	Sean Paul <sean@poorly.run>,
	Loic Poulain <loic.poulain@linaro.org>,
	Jami Kettunen <jami.kettunen@somainline.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Vladimir Lypak <vladimir.lypak@gmail.com>,
	Douglas Anderson <dianders@chromium.org>,
	Konrad Dybcio <konrad.dybcio@linaro.org>,
	sunliming <sunliming@kylinos.cn>,
	freedreno@lists.freedesktop.org
Subject: [PATCH v2 0/8] drm/msm: DSC Electric Boogaloo for sm8[12]50
Date: Thu, 22 Dec 2022 00:19:35 +0100	[thread overview]
Message-ID: <20221221231943.1961117-1-marijn.suijten@somainline.org> (raw)

This preliminary Display Stream Compression support package for
(initially tested on) sm8[12]50 is based on comparing DSC behaviour
between downstream and mainline.  Some new callbacks are added (for
binding blocks on active CTLs), logic bugs are corrected, zeroed struct
members are now assigned proper values, and RM allocation and hw block
retrieval now hand out (or not) DSC blocks without causing null-pointer
dereferences.

Unfortunately it is not yet enough to get rid of completely corrupted
display output on the boards I tested here:
- Sony Xperia 1 (sm8150), 1644x3840 or 1096x2560 pixels;
- Sony Xperia 5II (sm8250), 1080x2520, at 60 or 120Hz;
- (can include more Xperia boards if desired)

Both devices use the DUALPIPE_DSCMERGE topology downstream: dual LM, PP
and DSC, but only a single INTF/encoder/DSI-link.

Hopefully this spawns some community/upstream interest to help rootcause
our corruption issues (after we open a drm/msm report on GitLab for more
appropriate tracking).

The Sony Xperia XZ3 (sdm845) was fully tested and validated with this
series to not cause any regressions (and one of the math fixes now
allows us to change slice_count in the panel driver, which would corrupt
previously).

Changes since v1:

- Split patch 6 into two separately backportable Fixes: patches;
- Additionally remove num_enc from msm_display_topology in favour of
  num_dsc;
- Reorder patches to have all Fixes: at the beginning for easier
  picking;
- Fix existing multiline comment while editing it anyway;
- Add missing Signed-off-by to patch 5.

v1: https://lore.kernel.org/linux-arm-msm/20221213232207.113607-1-marijn.suijten@somainline.org/T/#u

Marijn Suijten (8):
  drm/msm/dpu: Wire up DSC mask for active CTL configuration
  drm/msm/dsi: Use DSC slice(s) packet size to compute word count
  drm/msm/dsi: Flip greater-than check for slice_count and
    slice_per_intf
  drm/msm/dpu: Disallow unallocated resources to be returned
  drm/msm/dpu: Reject topologies for which no DSC blocks are available
  drm/msm/dpu: Remove num_enc from topology struct in favour of num_dsc
  drm/msm/dpu: Implement DSC binding to PP block for CTL V1
  drm/msm/dpu: Add DSC configuration for SM8150 and SM8250

 drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c   | 12 +++++----
 .../drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c  |  1 +
 .../drm/msm/disp/dpu1/dpu_encoder_phys_vid.c  |  1 +
 .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c    | 23 +++++++++++-----
 .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h    |  9 +++++++
 drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.c    | 27 +++++++++++++++++++
 drivers/gpu/drm/msm/disp/dpu1/dpu_hw_dsc.h    |  4 +++
 drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c        | 14 ++++++++--
 drivers/gpu/drm/msm/dsi/dsi_host.c            |  7 ++---
 drivers/gpu/drm/msm/msm_drv.h                 |  2 --
 10 files changed, 82 insertions(+), 18 deletions(-)

--
2.39.0


             reply	other threads:[~2022-12-21 23:19 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-21 23:19 Marijn Suijten [this message]
2022-12-21 23:19 ` [PATCH v2 0/8] drm/msm: DSC Electric Boogaloo for sm8[12]50 Marijn Suijten
2022-12-21 23:19 ` [PATCH v2 1/8] drm/msm/dpu: Wire up DSC mask for active CTL configuration Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2023-01-08 23:23   ` Dmitry Baryshkov
2023-01-08 23:23     ` Dmitry Baryshkov
2022-12-21 23:19 ` [PATCH v2 2/8] drm/msm/dsi: Use DSC slice(s) packet size to compute word count Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2022-12-21 23:19 ` [PATCH v2 3/8] drm/msm/dsi: Flip greater-than check for slice_count and slice_per_intf Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2022-12-21 23:19 ` [PATCH v2 4/8] drm/msm/dpu: Disallow unallocated resources to be returned Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2023-01-08 23:28   ` Dmitry Baryshkov
2023-01-08 23:28     ` Dmitry Baryshkov
2023-01-08 23:30     ` Dmitry Baryshkov
2023-01-08 23:30       ` Dmitry Baryshkov
2023-01-09  8:23       ` Marijn Suijten
2023-01-09  8:23         ` Marijn Suijten
2023-01-09  9:06         ` Dmitry Baryshkov
2023-01-09  9:06           ` Dmitry Baryshkov
2023-01-09 17:12           ` Marijn Suijten
2023-01-09 17:12             ` Marijn Suijten
2023-01-09 18:24             ` Dmitry Baryshkov
2023-01-09 18:24               ` Dmitry Baryshkov
2022-12-21 23:19 ` [PATCH v2 5/8] drm/msm/dpu: Reject topologies for which no DSC blocks are available Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2023-01-08 23:29   ` Dmitry Baryshkov
2023-01-08 23:29     ` Dmitry Baryshkov
2022-12-21 23:19 ` [PATCH v2 6/8] drm/msm/dpu: Remove num_enc from topology struct in favour of num_dsc Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2023-01-08 23:31   ` Dmitry Baryshkov
2023-01-08 23:31     ` Dmitry Baryshkov
2023-01-09  8:21     ` Marijn Suijten
2023-01-09  8:21       ` Marijn Suijten
2023-01-09  9:08       ` Dmitry Baryshkov
2023-01-09  9:08         ` Dmitry Baryshkov
2022-12-21 23:19 ` [PATCH v2 7/8] drm/msm/dpu: Implement DSC binding to PP block for CTL V1 Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2022-12-21 23:19 ` [PATCH v2 8/8] drm/msm/dpu: Add DSC configuration for SM8150 and SM8250 Marijn Suijten
2022-12-21 23:19   ` Marijn Suijten
2023-01-05 14:49 ` [PATCH v2 0/8] drm/msm: DSC Electric Boogaloo for sm8[12]50 Daniel Vetter
2023-01-05 14:49   ` Daniel Vetter
2023-01-09  7:59   ` Marijn Suijten
2023-01-09 22:41 ` Dmitry Baryshkov
2023-01-09 23:43   ` Dmitry Baryshkov
2023-01-09 23:43   ` Dmitry Baryshkov
2023-01-09 22:41   ` 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=20221221231943.1961117-1-marijn.suijten@somainline.org \
    --to=marijn.suijten@somainline.org \
    --cc=airlied@gmail.com \
    --cc=andersson@kernel.org \
    --cc=angelogioacchino.delregno@somainline.org \
    --cc=baihaowen@meizu.com \
    --cc=daniel@ffwll.ch \
    --cc=dianders@chromium.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=freedreno@lists.freedesktop.org \
    --cc=jami.kettunen@somainline.org \
    --cc=jani.nikula@intel.com \
    --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=martin.botka@somainline.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=sam@ravnborg.org \
    --cc=sean@poorly.run \
    --cc=sunliming@kylinos.cn \
    --cc=swboyd@chromium.org \
    --cc=ville.syrjala@linux.intel.com \
    --cc=vkoul@kernel.org \
    --cc=vladimir.lypak@gmail.com \
    --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 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.