Commit 7ead3315 authored by Matthew Brost's avatar Matthew Brost Committed by Rodrigo Vivi

drm/xe: Use migrate engine for page fault binds

We must use migrate engine for page fault binds in order to avoid a
deadlock as the migrate engine has a reserved BCS instance which cannot
be stuck on a fault. To use the migrate engine the engine argument to
xe_migrate_update_pgtables must be NULL, this was incorrectly wired up
so vm->eng[tile_id] was always being used. Fix this.
Reviewed-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: default avatarMatthew Brost <matthew.brost@intel.com>
Signed-off-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
parent a4cc60a5
...@@ -1421,8 +1421,7 @@ __xe_pt_bind_vma(struct xe_tile *tile, struct xe_vma *vma, struct xe_engine *e, ...@@ -1421,8 +1421,7 @@ __xe_pt_bind_vma(struct xe_tile *tile, struct xe_vma *vma, struct xe_engine *e,
} }
fence = xe_migrate_update_pgtables(tile->migrate, fence = xe_migrate_update_pgtables(tile->migrate,
vm, xe_vma_bo(vma), vm, xe_vma_bo(vma), e,
e ? e : vm->eng[tile->id],
entries, num_entries, entries, num_entries,
syncs, num_syncs, syncs, num_syncs,
&bind_pt_update.base); &bind_pt_update.base);
......
...@@ -1675,7 +1675,8 @@ xe_vm_bind_vma(struct xe_vma *vma, struct xe_engine *e, ...@@ -1675,7 +1675,8 @@ xe_vm_bind_vma(struct xe_vma *vma, struct xe_engine *e,
if (!(vma->tile_mask & BIT(id))) if (!(vma->tile_mask & BIT(id)))
goto next; goto next;
fence = __xe_pt_bind_vma(tile, vma, e, first_op ? syncs : NULL, fence = __xe_pt_bind_vma(tile, vma, e ? e : vm->eng[id],
first_op ? syncs : NULL,
first_op ? num_syncs : 0, first_op ? num_syncs : 0,
vma->tile_present & BIT(id)); vma->tile_present & BIT(id));
if (IS_ERR(fence)) { if (IS_ERR(fence)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment