dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu: use dirty framebuffer helper
@ 2022-09-06 19:57 Hamza Mahfooz
  2022-09-08 13:14 ` Alex Deucher
  2022-09-19  6:44 ` Thomas Zimmermann
  0 siblings, 2 replies; 8+ messages in thread
From: Hamza Mahfooz @ 2022-09-06 19:57 UTC (permalink / raw)
  To: linux-kernel
  Cc: Guchun Chen, David Airlie, dri-devel, Pan, Xinhui, amd-gfx,
	Aurabindo Pillai, Sean Paul, Hamza Mahfooz, Alex Deucher,
	Christian König, Fernando Ramos

Currently, we aren't handling DRM_IOCTL_MODE_DIRTYFB. So, use
drm_atomic_helper_dirtyfb() as the dirty callback in the amdgpu_fb_funcs
struct.

Signed-off-by: Hamza Mahfooz <hamza.mahfooz@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
index c20922a5af9f..5b09c8f4fe95 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
@@ -38,6 +38,7 @@
 #include <linux/pci.h>
 #include <linux/pm_runtime.h>
 #include <drm/drm_crtc_helper.h>
+#include <drm/drm_damage_helper.h>
 #include <drm/drm_edid.h>
 #include <drm/drm_gem_framebuffer_helper.h>
 #include <drm/drm_fb_helper.h>
@@ -496,6 +497,7 @@ bool amdgpu_display_ddc_probe(struct amdgpu_connector *amdgpu_connector,
 static const struct drm_framebuffer_funcs amdgpu_fb_funcs = {
 	.destroy = drm_gem_fb_destroy,
 	.create_handle = drm_gem_fb_create_handle,
+	.dirty = drm_atomic_helper_dirtyfb,
 };
 
 uint32_t amdgpu_display_supported_domains(struct amdgpu_device *adev,
-- 
2.37.2


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

end of thread, other threads:[~2022-09-20  3:14 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-06 19:57 [PATCH] drm/amdgpu: use dirty framebuffer helper Hamza Mahfooz
2022-09-08 13:14 ` Alex Deucher
2022-09-18 12:09   ` root
2022-09-19  2:53     ` Arthur Marsh
2022-09-19 16:33     ` [PATCH] " Alex Deucher
2022-09-20  3:14       ` Arthur Marsh
2022-09-19  6:44 ` Thomas Zimmermann
2022-09-19 16:26   ` Alex Deucher

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).