Skip to content

Commit 650dd7e

Browse files
anholtgregkh
authored andcommitted
drm/i915: Fix object refcount leak on mmappable size limit error path.
commit 14660cc upstream. I've been seeing memory leaks on my system in the form of large (300-400MB) GEM objects created by now-dead processes laying around clogging up memory. I usually notice when it gets to about 1.2GB of them. Hopefully this clears up the issue, but I just found this bug by inspection. Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Keith Packard <keithp@keithp.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
1 parent aa85ae0 commit 650dd7e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎drivers/gpu/drm/i915/i915_gem.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1475,7 +1475,7 @@ i915_gem_mmap_gtt(struct drm_file *file,
14751475

14761476
if (obj->base.size > dev_priv->mm.gtt_mappable_end) {
14771477
ret = -E2BIG;
1478-
goto unlock;
1478+
goto out;
14791479
}
14801480

14811481
if (obj->madv != I915_MADV_WILLNEED) {

0 commit comments

Comments
 (0)