diff options
author | 2024-01-22 13:09:43 +0100 | |
---|---|---|
committer | 2024-01-25 10:16:56 +0100 | |
commit | f1cc6aceecd04964304786530eaa4ad87d90b972 (patch) | |
tree | abbfe177f3f83772c837cec402338fdf943938b1 /drivers/accel/ivpu/ivpu_gem.h | |
parent | Revert "drivers/firmware: Move sysfb_init() from device_initcall to subsys_in... (diff) | |
download | linux-f1cc6aceecd04964304786530eaa4ad87d90b972.tar.gz linux-f1cc6aceecd04964304786530eaa4ad87d90b972.tar.bz2 linux-f1cc6aceecd04964304786530eaa4ad87d90b972.zip |
accel/ivpu: Fix dev open/close races with unbind
- Add context_list_lock to synchronize user context addition/removal
- Use drm_dev_enter() to prevent unbinding the device during ivpu_open()
and vpu address allocation
Signed-off-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
Reviewed-by: Wachowski, Karol <karol.wachowski@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240122120945.1150728-2-jacek.lawrynowicz@linux.intel.com
Diffstat (limited to 'drivers/accel/ivpu/ivpu_gem.h')
-rw-r--r-- | drivers/accel/ivpu/ivpu_gem.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/accel/ivpu/ivpu_gem.h b/drivers/accel/ivpu/ivpu_gem.h index 5cb1dda3e58e..a8559211c70d 100644 --- a/drivers/accel/ivpu/ivpu_gem.h +++ b/drivers/accel/ivpu/ivpu_gem.h @@ -25,7 +25,7 @@ struct ivpu_bo { }; int ivpu_bo_pin(struct ivpu_bo *bo); -void ivpu_bo_remove_all_bos_from_context(struct ivpu_device *vdev, struct ivpu_mmu_context *ctx); +void ivpu_bo_unbind_all_bos_from_context(struct ivpu_device *vdev, struct ivpu_mmu_context *ctx); struct drm_gem_object *ivpu_gem_create_object(struct drm_device *dev, size_t size); struct ivpu_bo *ivpu_bo_alloc_internal(struct ivpu_device *vdev, u64 vpu_addr, u64 size, u32 flags); |