Skip to content

Commit 1381c23

Browse files
matt-auldlucasdemarchi
authored andcommitted
drm/xe/migrate: fix copy direction in access_memory
After we do the modification on the host side, ensure we write the result back to VRAM and not the other way around, otherwise the modification will be lost if treated like a read. Fixes: 270172f ("drm/xe: Update xe_ttm_access_memory to use GPU for non-visible access") Signed-off-by: Matthew Auld <[email protected]> Cc: Matthew Brost <[email protected]> Reviewed-by: Matthew Brost <[email protected]> Link: https://lore.kernel.org/r/[email protected] (cherry picked from commit c12fe70) Signed-off-by: Lucas De Marchi <[email protected]>
1 parent fd25fa9 commit 1381c23

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpu/drm/xe/xe_migrate.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1848,7 +1848,7 @@ int xe_migrate_access_memory(struct xe_migrate *m, struct xe_bo *bo,
18481848
err = xe_migrate_access_memory(m, bo,
18491849
offset & ~XE_CACHELINE_MASK,
18501850
(void *)ptr,
1851-
sizeof(bounce), 0);
1851+
sizeof(bounce), write);
18521852
if (err)
18531853
return err;
18541854
} else {

0 commit comments

Comments
 (0)