Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update
@ 2023-06-29 15:35 Maarten Lankhorst
  2023-06-29 15:35 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Maarten Lankhorst @ 2023-06-29 15:35 UTC (permalink / raw)
  To: intel-gfx

Xe is lacking the ability to re-use the ggtt_vma when updating cursor.
Instead of pinning from the new plane_state, move the ggtt_vma from
old_plane_state to new_plane_state.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_cursor.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c
index 4962247911d41..6f34098ea314d 100644
--- a/drivers/gpu/drm/i915/display/intel_cursor.c
+++ b/drivers/gpu/drm/i915/display/intel_cursor.c
@@ -688,9 +688,8 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
 	if (ret)
 		goto out_free;
 
-	ret = intel_plane_pin_fb(new_plane_state);
-	if (ret)
-		goto out_free;
+	/* magic trick! */
+	swap(new_plane_state->ggtt_vma, old_plane_state->ggtt_vma);
 
 	intel_frontbuffer_flush(to_intel_frontbuffer(new_plane_state->hw.fb),
 				ORIGIN_CURSOR_UPDATE);
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 11+ messages in thread
* [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update
@ 2023-08-14  6:50 Maarten Lankhorst
  2023-08-14  6:50 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
  0 siblings, 1 reply; 11+ messages in thread
From: Maarten Lankhorst @ 2023-08-14  6:50 UTC (permalink / raw)
  To: intel-gfx

From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_cursor.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c
index 8ed8a623fa98..b1a77b89585d 100644
--- a/drivers/gpu/drm/i915/display/intel_cursor.c
+++ b/drivers/gpu/drm/i915/display/intel_cursor.c
@@ -690,9 +690,8 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
 	if (ret)
 		goto out_free;
 
-	ret = intel_plane_pin_fb(new_plane_state);
-	if (ret)
-		goto out_free;
+	/* magic trick! */
+	swap(new_plane_state->ggtt_vma, old_plane_state->ggtt_vma);
 
 	intel_frontbuffer_flush(to_intel_frontbuffer(new_plane_state->hw.fb),
 				ORIGIN_CURSOR_UPDATE);
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 11+ messages in thread
* [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update
@ 2023-08-10 12:41 Maarten Lankhorst
  2023-08-10 12:41 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
  0 siblings, 1 reply; 11+ messages in thread
From: Maarten Lankhorst @ 2023-08-10 12:41 UTC (permalink / raw)
  To: intel-gfx; +Cc: dri-devel

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_cursor.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c
index b342fad180ca..ab25f019eda1 100644
--- a/drivers/gpu/drm/i915/display/intel_cursor.c
+++ b/drivers/gpu/drm/i915/display/intel_cursor.c
@@ -688,9 +688,8 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
 	if (ret)
 		goto out_free;
 
-	ret = intel_plane_pin_fb(new_plane_state);
-	if (ret)
-		goto out_free;
+	/* magic trick! */
+	swap(new_plane_state->ggtt_vma, old_plane_state->ggtt_vma);
 
 	intel_frontbuffer_flush(to_intel_frontbuffer(new_plane_state->hw.fb),
 				ORIGIN_CURSOR_UPDATE);
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 11+ messages in thread
* [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update
@ 2023-06-21 11:48 Maarten Lankhorst
  2023-06-21 11:48 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
  0 siblings, 1 reply; 11+ messages in thread
From: Maarten Lankhorst @ 2023-06-21 11:48 UTC (permalink / raw)
  To: intel-gfx

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_cursor.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c
index 4962247911d41..6f34098ea314d 100644
--- a/drivers/gpu/drm/i915/display/intel_cursor.c
+++ b/drivers/gpu/drm/i915/display/intel_cursor.c
@@ -688,9 +688,8 @@ intel_legacy_cursor_update(struct drm_plane *_plane,
 	if (ret)
 		goto out_free;
 
-	ret = intel_plane_pin_fb(new_plane_state);
-	if (ret)
-		goto out_free;
+	/* magic trick! */
+	swap(new_plane_state->ggtt_vma, old_plane_state->ggtt_vma);
 
 	intel_frontbuffer_flush(to_intel_frontbuffer(new_plane_state->hw.fb),
 				ORIGIN_CURSOR_UPDATE);
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2023-08-18  8:37 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-29 15:35 [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update Maarten Lankhorst
2023-06-29 15:35 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
2023-06-29 19:15 ` [Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [1/2] drm/i915: Swap ggtt_vma during legacy cursor update Patchwork
2023-06-30  5:52 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2023-07-25 20:26 ` [Intel-gfx] [PATCH 1/2] " Shankar, Uma
  -- strict thread matches above, loose matches on Subject: below --
2023-08-14  6:50 Maarten Lankhorst
2023-08-14  6:50 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
2023-08-18  8:37   ` kernel test robot
2023-08-10 12:41 [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update Maarten Lankhorst
2023-08-10 12:41 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
2023-06-21 11:48 [Intel-gfx] [PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update Maarten Lankhorst
2023-06-21 11:48 ` [Intel-gfx] [PATCH 2/2] drm/i915: Handle legacy cursor update as normal update Maarten Lankhorst
2023-06-21 23:09   ` kernel test robot
2023-06-21 23:40   ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox