From: Val Packett <val@packett.cool>
To: Xi Zhang <xz.ca.cn@gmail.com>,
Rob Clark <robin.clark@oss.qualcomm.com>,
Dmitry Baryshkov <lumag@kernel.org>,
Abhinav Kumar <abhinav.kumar@linux.dev>,
Jessica Zhang <jesszhan0024@gmail.com>,
Sean Paul <sean@poorly.run>,
Marijn Suijten <marijn.suijten@somainline.org>,
David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>
Cc: linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 5/6] drm/msm: force mode_changed on color_mgmt_changed, not just ctm
Date: Mon, 26 Oct 2026 20:15:10 -0300 [thread overview]
Message-ID: <cb719558-3f7e-4332-beff-b81fa31cb73d@packett.cool> (raw)
In-Reply-To: <20261026-msm-dpu-res-clean-v2-5-3d864435186e@gmail.com>
On 10/26/26 5:25 PM, Xi Zhang wrote:
> dpu_crtc_atomic_check calls dpu_crtc_assign_resources when
> color_mgmt_changed is set, which is unsafe outside of full modeset.
>
> Set allow_modeset and mode_changed when color_mgmt_changed is set,
> not just when ctm is changed.
>
> Also would fix
> commit 42f62cd79578 ("drm/msm/dpu: try reserving the DSPP-less LM first")
> which was reverted.
>
> Closes: https://gitlab.freedesktop.org/drm/msm/-/work_items/102
>
> Signed-off-by: Xi Zhang <xz.ca.cn@gmail.com>
> ---
> drivers/gpu/drm/msm/msm_atomic.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/msm_atomic.c b/drivers/gpu/drm/msm/msm_atomic.c
> index a8babf1dbe0d..6f0f30b0728a 100644
> --- a/drivers/gpu/drm/msm/msm_atomic.c
> +++ b/drivers/gpu/drm/msm/msm_atomic.c
> @@ -195,8 +195,7 @@ int msm_atomic_check(struct drm_device *dev, struct drm_atomic_commit *state)
> */
> for_each_oldnew_crtc_in_state(state, crtc, old_crtc_state,
> new_crtc_state, i) {
> - if ((old_crtc_state->ctm && !new_crtc_state->ctm) ||
> - (!old_crtc_state->ctm && new_crtc_state->ctm)) {
> + if (new_crtc_state->color_mgmt_changed) {
> new_crtc_state->mode_changed = true;
> state->allow_modeset = true;
> }
This is also handled by patch 9 "drm/msm/dpu: only reassign resources
when the encoder is reprogrammed" of the smmu fault series:
https://lore.kernel.org/all/20261024-fd-kms-fix-smmu-v5-9-a5b0b284aead@oss.qualcomm.com/
Thanks,
~val
next prev parent reply other threads:[~2026-10-26 23:15 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-26 20:25 [PATCH v2 0/6] drm/msm/dpu: various dpu resource allocation/release mismatch fix Xi Zhang via B4 Relay
2026-10-26 20:25 ` [PATCH v2 1/6] drm/msm/dpu: reset unassigned resource slots to NULL on topology update Xi Zhang via B4 Relay
2026-10-26 23:04 ` Val Packett
2026-10-26 23:55 ` Xi Zhang
2026-10-26 20:25 ` [PATCH v2 2/6] drm/msm/dpu: save LMs in encoder mode_set for cleanup use later Xi Zhang via B4 Relay
2026-10-26 20:25 ` [PATCH v2 3/6] drm/msm/dpu: use common helper cleanup function in cmd mode disable Xi Zhang via B4 Relay
2026-10-26 20:25 ` [PATCH v2 4/6] drm/msm/dpu: Match setup_dither cleanup to the way it was set up Xi Zhang via B4 Relay
2026-10-26 20:25 ` [PATCH v2 5/6] drm/msm: force mode_changed on color_mgmt_changed, not just ctm Xi Zhang via B4 Relay
2026-10-26 23:15 ` Val Packett [this message]
2026-10-26 20:25 ` [PATCH v2 6/6] drm/msm/dpu: reset DSC_CMN_MAIN_CNF in dsc disable Xi Zhang via B4 Relay
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=cb719558-3f7e-4332-beff-b81fa31cb73d@packett.cool \
--to=val@packett.cool \
--cc=abhinav.kumar@linux.dev \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=jesszhan0024@gmail.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lumag@kernel.org \
--cc=marijn.suijten@somainline.org \
--cc=robin.clark@oss.qualcomm.com \
--cc=sean@poorly.run \
--cc=simona@ffwll.ch \
--cc=xz.ca.cn@gmail.com \
/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
all inboxes | Powered by JetHome®