projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d0302e7
)
drm/i915/gvt: To check whether workload scan and shadow has mutex hold
author
Ping Gao
<ping.a.gao@intel.com>
Tue, 4 Jul 2017 06:53:03 +0000
(14:53 +0800)
committer
Zhenyu Wang
<zhenyuw@linux.intel.com>
Thu, 10 Aug 2017 02:26:07 +0000
(10:26 +0800)
The function workload scan and shadow have to hold the drm.struct_mutex
before called. To avoid misusing of this function, add a lockdep assert
in it.
Signed-off-by: Ping Gao <ping.a.gao@intel.com>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
drivers/gpu/drm/i915/gvt/scheduler.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/gpu/drm/i915/gvt/scheduler.c
b/drivers/gpu/drm/i915/gvt/scheduler.c
index bd59c6d093191ba9140a510342dedf9da47be8d9..ca1926d564c9a47e79f7549921f38f30f41036fa 100644
(file)
--- a/
drivers/gpu/drm/i915/gvt/scheduler.c
+++ b/
drivers/gpu/drm/i915/gvt/scheduler.c
@@
-201,6
+201,8
@@
int intel_gvt_scan_and_shadow_workload(struct intel_vgpu_workload *workload)
struct intel_vgpu *vgpu = workload->vgpu;
int ret;
+ lockdep_assert_held(&dev_priv->drm.struct_mutex);
+
if (workload->shadowed)
return 0;