drm/gma500: fix double freeing
authorSudip Mukherjee <sudipm.mukherjee@gmail.com>
Thu, 8 Oct 2015 12:47:48 +0000 (18:17 +0530)
committerPatrik Jakobsson <patrik.r.jakobsson@gmail.com>
Fri, 8 Apr 2016 11:39:23 +0000 (13:39 +0200)
commit4cd54d986e8a1e28b70cfeb748c3ce734635bb4b
tree0b62e42b8bddd65c5d6ee0e742b5de93e0327cf4
parentd00b39c17573ece6f5fb1385314877d29f540db8
drm/gma500: fix double freeing

We are allocating backing using psbfb_alloc() and so
backing->stolen is always true. So we were freeing backing two times.
Moreover if we follow the execution path then we should be freeing
backing after we have released the helper. So remove the one which frees
backing before the helper is released.
While at it the error labels are also renamed to give a meaningful
name.

[Patrik: Fixed conflict with removal of struct_mutex]

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Reviewed-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
drivers/gpu/drm/gma500/framebuffer.c