diff options
author | Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com> | 2024-04-24 10:09:10 +0530 |
---|---|---|
committer | Matthew Brost <matthew.brost@intel.com> | 2024-04-25 20:38:35 -0700 |
commit | c79828e0c7795cccc92abcd24107aa478168628c (patch) | |
tree | c47c96ced557cf65221ccb77cb505f27dc719be6 /drivers/gpu/drm/xe/xe_lrc.c | |
parent | a1adb3d250925ddccd5270106d39aa09493d6edf (diff) | |
download | lwn-c79828e0c7795cccc92abcd24107aa478168628c.tar.gz lwn-c79828e0c7795cccc92abcd24107aa478168628c.zip |
drm/xe: Use xe_bo_lock()/xe_bo_unlock() helpers
There is no change in functionality. Using the helper function
defined within the driver for locking/unlocking the reservation
object.
Cc: Matthew Brost <matthew.brost@intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Suggested-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240424043910.2190376-3-himal.prasad.ghimiray@intel.com
Diffstat (limited to 'drivers/gpu/drm/xe/xe_lrc.c')
-rw-r--r-- | drivers/gpu/drm/xe/xe_lrc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/xe/xe_lrc.c b/drivers/gpu/drm/xe/xe_lrc.c index 615bbc372ac6..2066d34ddf0b 100644 --- a/drivers/gpu/drm/xe/xe_lrc.c +++ b/drivers/gpu/drm/xe/xe_lrc.c @@ -1382,7 +1382,7 @@ void xe_lrc_snapshot_capture_delayed(struct xe_lrc_snapshot *snapshot) if (!snapshot->lrc_snapshot) goto put_bo; - dma_resv_lock(bo->ttm.base.resv, NULL); + xe_bo_lock(bo, false); if (!ttm_bo_vmap(&bo->ttm, &src)) { xe_map_memcpy_from(xe_bo_device(bo), snapshot->lrc_snapshot, &src, snapshot->lrc_offset, @@ -1392,7 +1392,7 @@ void xe_lrc_snapshot_capture_delayed(struct xe_lrc_snapshot *snapshot) kvfree(snapshot->lrc_snapshot); snapshot->lrc_snapshot = NULL; } - dma_resv_unlock(bo->ttm.base.resv); + xe_bo_unlock(bo); put_bo: xe_bo_put(bo); } |