drm/gud: Test for imported buffers with drm_gem_is_imported()
Subsystems (3)
Thomas Zimmermann
maintainerPATCH 3/11 drm/gud: Test for imported buffers with drm_gem_is_imported()
Instead of testing import_attach for imported GEM buffers, invoke drm_gem_is_imported() to do the test. The helper tests the dma_buf itself while import_attach is just an artifact of the import. Prepares to make import_attach optional.
Signed-off-by Thomas Zimmermann <[email protected]>
--- drivers/gpu/drm/gud/gud_pipe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/gud/gud_pipe.c +1 -1
@@ -443,7 +443,7 @@ static void gud_fb_handle_damage(struct gud_device *gdrm, struct drm_framebuffer }/* Imported buffers are assumed to be WriteCombined with uncached reads */ -gud_flush_damage (gdrm, fb, src, !fb->obj[0 ]->import_attach, damage); +gud_flush_damage (gdrm, fb, src, !drm_gem_is_imported (fb->obj[0 ]), damage); } int gud_pipe_check(struct drm_simple_display_pipe *pipe,
Signature · 1 line
2.49.0