diff options
author | Subhajit Paul <subhajit_paul@ti.com> | 2014-04-11 03:23:30 -0400 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2014-04-15 06:35:27 -0400 |
commit | 15ec2ca964d7a52e7e0a452fe0f9c409d2f3eec6 (patch) | |
tree | cd97faade7e110ec53ebc640a42a0d8009146bcc /drivers/gpu | |
parent | b841aedfcfd543d836c856bfde5a17c51cab6b26 (diff) |
drm/omap: Fix memory leak in omap_gem_op_async
In omap_gem_op_async(), if a waiter is not added to the wait list, it needs to
be free'd in the function itself.
Make sure we free the waiter for this case.
Signed-off-by: Subhajit Paul <subhajit_paul@ti.com>
Signed-off-by: Archit Taneja <archit@ti.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/omapdrm/omap_gem.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/omapdrm/omap_gem.c b/drivers/gpu/drm/omapdrm/omap_gem.c index 70798b9fe635..9a68e9a28438 100644 --- a/drivers/gpu/drm/omapdrm/omap_gem.c +++ b/drivers/gpu/drm/omapdrm/omap_gem.c | |||
@@ -1226,6 +1226,8 @@ int omap_gem_op_async(struct drm_gem_object *obj, enum omap_gem_op op, | |||
1226 | } | 1226 | } |
1227 | 1227 | ||
1228 | spin_unlock(&sync_lock); | 1228 | spin_unlock(&sync_lock); |
1229 | |||
1230 | kfree(waiter); | ||
1229 | } | 1231 | } |
1230 | 1232 | ||
1231 | /* no waiting.. */ | 1233 | /* no waiting.. */ |