[PATCHv2 3/3] i915: do not leak module ref counter

Sergey Senozhatsky sergey.senozhatsky at gmail.com
Mon Aug 5 16:03:07 UTC 2019


put_filesystem() must follow get_fs_type().

Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky at gmail.com>
---
 drivers/gpu/drm/i915/gem/i915_gemfs.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/i915/gem/i915_gemfs.c b/drivers/gpu/drm/i915/gem/i915_gemfs.c
index feedc9242072..93ac365ce9ce 100644
--- a/drivers/gpu/drm/i915/gem/i915_gemfs.c
+++ b/drivers/gpu/drm/i915/gem/i915_gemfs.c
@@ -24,6 +24,7 @@ int i915_gemfs_init(struct drm_i915_private *i915)
 		return -ENODEV;
 
 	gemfs = kern_mount(type);
+	put_filesystem(type);
 	if (IS_ERR(gemfs))
 		return PTR_ERR(gemfs);
 
-- 
2.22.0



More information about the dri-devel mailing list