artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
059ed2c
)
drm/i915/gvt: fix vgpu debugfs clean in remove
author
jsg
<jsg@openbsd.org>
Fri, 13 Jan 2023 01:54:11 +0000
(
01:54
+0000)
committer
jsg
<jsg@openbsd.org>
Fri, 13 Jan 2023 01:54:11 +0000
(
01:54
+0000)
From Zhenyu Wang
44c0e07e3972e3f2609d69ad873d4f342f8a68ec
in linux-6.1.y/6.1.5
704f3384f322b40ba24d958473edfb1c9750c8fd
in mainline linux
sys/dev/pci/drm/i915/gvt/debugfs.c
patch
|
blob
|
history
diff --git
a/sys/dev/pci/drm/i915/gvt/debugfs.c
b/sys/dev/pci/drm/i915/gvt/debugfs.c
index
d7df27f
..
e08ed0e
100644
(file)
--- a/
sys/dev/pci/drm/i915/gvt/debugfs.c
+++ b/
sys/dev/pci/drm/i915/gvt/debugfs.c
@@
-175,8
+175,13
@@
void intel_gvt_debugfs_add_vgpu(struct intel_vgpu *vgpu)
*/
void intel_gvt_debugfs_remove_vgpu(struct intel_vgpu *vgpu)
{
- debugfs_remove_recursive(vgpu->debugfs);
- vgpu->debugfs = NULL;
+ struct intel_gvt *gvt = vgpu->gvt;
+ struct drm_minor *minor = gvt->gt->i915->drm.primary;
+
+ if (minor->debugfs_root && gvt->debugfs_root) {
+ debugfs_remove_recursive(vgpu->debugfs);
+ vgpu->debugfs = NULL;
+ }
}
/**