From: "Borah, Chaitanya Kumar" <chaitanya.kumar.borah@intel.com>
To: Nemesa Garg <nemesa.garg@intel.com>,
<intel-gfx@lists.freedesktop.org>,
<intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH 5/6] drm/i915/cursor: Program secondary cursor planes
Date: Wed, 1 Jul 2026 22:02:24 +0530 [thread overview]
Message-ID: <f7acea16-e3f6-4c90-b1e2-92126ea63de0@intel.com> (raw)
In-Reply-To: <20260608062629.820477-6-nemesa.garg@intel.com>
On 6/8/2026 11:56 AM, Nemesa Garg wrote:
> During the vblank-evade, program all joined cursor
> planes using intel_plane_update_noarm()/intel_plane_update_arm()
> or intel_plane_disable_arm() based on plane visibility.
>
> V2: Check primary and secondary pipe together. [Ville]
>
> Assisted-by: Claude:claude-sonnet-4.6
> Signed-off-by: Nemesa Garg <nemesa.garg@intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_cursor.c | 19 ++++++++++++++-----
> 1 file changed, 14 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c
> index 147ed6efb174..cb1fcae8a445 100644
> --- a/drivers/gpu/drm/i915/display/intel_cursor.c
> +++ b/drivers/gpu/drm/i915/display/intel_cursor.c
> @@ -896,6 +896,7 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
> struct intel_vblank_evade_ctx evade;
> struct intel_plane_state *old_pipe_states[4] = {};
> struct intel_plane_state *new_pipe_states[4] = {};
> + struct intel_crtc_state *pipe_crtc_states[4] = {};
Another candidate for the struct.
> struct intel_plane *pipe_planes[4] = {};
> struct intel_crtc *pipe_crtcs[4] = {};
> struct intel_crtc *pipe_crtc;
> @@ -977,6 +978,7 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
>
> pipe_planes[num_pipes] = plane;
> pipe_crtcs[num_pipes] = crtc;
> + pipe_crtc_states[num_pipes] = crtc_state;
> old_pipe_states[num_pipes] = old_plane_state;
> new_pipe_states[num_pipes] = new_plane_state;
> num_pipes++;
> @@ -1032,6 +1034,7 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
>
> pipe_planes[num_pipes] = pipe_plane;
> pipe_crtcs[num_pipes] = pipe_crtc;
> + pipe_crtc_states[num_pipes] = pipe_crtc_state;
> old_pipe_states[num_pipes] = old_pipe_plane_state;
> new_pipe_states[num_pipes] = new_pipe_plane_state;
> num_pipes++;
> @@ -1087,11 +1090,17 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
> local_irq_disable();
> }
>
> - if (new_plane_state->uapi.visible) {
> - intel_plane_update_noarm(NULL, plane, crtc_state, new_plane_state);
> - intel_plane_update_arm(NULL, plane, crtc_state, new_plane_state);
> - } else {
> - intel_plane_disable_arm(NULL, plane, crtc_state);
> + for (int i = 0; i < num_pipes; i++) {
> + if (new_pipe_states[i]->uapi.visible) {
> + intel_plane_update_noarm(NULL, pipe_planes[i],
> + pipe_crtc_states[i],
> + new_pipe_states[i]);
> + intel_plane_update_arm(NULL, pipe_planes[i],
> + pipe_crtc_states[i],
> + new_pipe_states[i]);
> + } else {
> + intel_plane_disable_arm(NULL, pipe_planes[i], pipe_crtc_states[i]);
> + }
All secondaries are now armed inside the single primary vblank-evade.
The atomic sync path evades every pipe individually but that might be an
over-kill for cursor updates. I wonder if we can add some debug logs to
warn us of vblank straddles if any.
==
Chaitanya
> }
>
> local_irq_enable();
next prev parent reply other threads:[~2026-07-01 16:32 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-08 6:26 [PATCH 0/6] Enable joiner cursor fast updates Nemesa Garg
2026-06-08 6:26 ` [PATCH 1/6] drm/i915/cursor: Check joiner cursor commit status Nemesa Garg
2026-07-01 16:25 ` Borah, Chaitanya Kumar
2026-07-06 8:40 ` Garg, Nemesa
2026-06-08 6:26 ` [PATCH 2/6] drm/i915/cursor: Add helper to update cursor plane Nemesa Garg
2026-07-01 16:26 ` Borah, Chaitanya Kumar
2026-07-06 8:40 ` Garg, Nemesa
2026-06-08 6:26 ` [PATCH 3/6] drm/i915/cursor: Handle secondary cursor state Nemesa Garg
2026-07-01 16:30 ` Borah, Chaitanya Kumar
2026-07-06 8:40 ` Garg, Nemesa
2026-06-08 6:26 ` [PATCH 4/6] drm/i915/cursor: Sync joiner " Nemesa Garg
2026-07-01 16:32 ` Borah, Chaitanya Kumar
2026-07-06 8:41 ` Garg, Nemesa
2026-06-08 6:26 ` [PATCH 5/6] drm/i915/cursor: Program secondary cursor planes Nemesa Garg
2026-07-01 16:32 ` Borah, Chaitanya Kumar [this message]
2026-07-06 8:42 ` Garg, Nemesa
2026-06-08 6:26 ` [PATCH 6/6] drm/i915/cursor: Allow joiner cursor fast path update Nemesa Garg
2026-07-01 16:31 ` Borah, Chaitanya Kumar
2026-06-08 11:43 ` ✗ CI.checkpatch: warning for Enable joiner cursor fast updates (rev3) Patchwork
2026-06-08 11:44 ` ✓ CI.KUnit: success " Patchwork
2026-06-08 14:17 ` ✓ i915.CI.BAT: " Patchwork
2026-06-08 16:30 ` ✗ i915.CI.Full: failure " Patchwork
-- strict thread matches above, loose matches on Subject: below --
2026-04-28 14:16 [PATCH 0/6] Enable joiner cursor fast updates Nemesa Garg
2026-04-28 14:16 ` [PATCH 5/6] drm/i915/cursor: Program secondary cursor planes Nemesa Garg
2026-04-22 7:37 [PATCH 0/6] Enable joiner cursor fast updates Nemesa Garg
2026-04-22 7:37 ` [PATCH 5/6] drm/i915/cursor: Program secondary cursor planes Nemesa Garg
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=f7acea16-e3f6-4c90-b1e2-92126ea63de0@intel.com \
--to=chaitanya.kumar.borah@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=intel-xe@lists.freedesktop.org \
--cc=nemesa.garg@intel.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 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.