[PATCH] drm: fb: cma: fix memory leak

2016-06-13 Thread Daniel Vetter
On Sun, Jun 12, 2016 at 04:03:56PM +0100, Sudip Mukherjee wrote: > We may have a situation that the memory allocation for fbdefio fails > and then the allocation for fbops may succeed as some memory has been > freed somewhere. Lets free fbops also to face these rare situtation. > Since kfree can

[PATCH] drm: fb: cma: fix memory leak

2016-06-12 Thread Sudip Mukherjee
We may have a situation that the memory allocation for fbdefio fails and then the allocation for fbops may succeed as some memory has been freed somewhere. Lets free fbops also to face these rare situtation. Since kfree can handle arguments as NULL, there should not be any problem in calling both