diff options
author | Bommithi Sakeena <bommithi.sakeena@intel.com> | 2023-09-27 19:50:11 +0300 |
---|---|---|
committer | Rodrigo Vivi <rodrigo.vivi@intel.com> | 2023-12-21 19:41:21 +0300 |
commit | 28b1d9155c3c1651a6e184e1286cebb63ec6b51c (patch) | |
tree | 6ec8d9dc0437d92b1226ec42beb15f782ca3b43e /drivers/gpu/drm/xe/xe_pcode.c | |
parent | 5349bb76d62048e73f6e4a863b40a309c62dc47f (diff) | |
download | linux-28b1d9155c3c1651a6e184e1286cebb63ec6b51c.tar.xz |
drm/xe: Ensure mutex are destroyed
Add missing mutex_destroy calls to fini functions or convert to
drmm_mutex_init where fini function is not available.
Cc: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Bommithi Sakeena <bommithi.sakeena@intel.com>
Reviewed-by: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Diffstat (limited to 'drivers/gpu/drm/xe/xe_pcode.c')
-rw-r--r-- | drivers/gpu/drm/xe/xe_pcode.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/xe/xe_pcode.c b/drivers/gpu/drm/xe/xe_pcode.c index 7f1bf2297f51..4a240acf7625 100644 --- a/drivers/gpu/drm/xe/xe_pcode.c +++ b/drivers/gpu/drm/xe/xe_pcode.c @@ -8,6 +8,8 @@ #include <linux/delay.h> #include <linux/errno.h> +#include <drm/drm_managed.h> + #include "xe_gt.h" #include "xe_mmio.h" #include "xe_pcode_api.h" @@ -276,7 +278,7 @@ int xe_pcode_init(struct xe_gt *gt) */ int xe_pcode_probe(struct xe_gt *gt) { - mutex_init(>->pcode.lock); + drmm_mutex_init(>_to_xe(gt)->drm, >->pcode.lock); if (!IS_DGFX(gt_to_xe(gt))) return 0; |