LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] video: add missing framebuffer_release in error path
@ 2011-02-15  9:35 Axel Lin
  2011-02-15 18:53 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Axel Lin @ 2011-02-15  9:35 UTC (permalink / raw)
  To: linux-kernel; +Cc: David S. Miller, Paul Mundt, linux-fbdev

This patch fixes a memory leak in the error path.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/video/cg14.c |    1 +
 drivers/video/cg6.c  |    1 +
 drivers/video/tcx.c  |    1 +
 3 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/video/cg14.c b/drivers/video/cg14.c
index 2424953..2063a63 100644
--- a/drivers/video/cg14.c
+++ b/drivers/video/cg14.c
@@ -565,6 +565,7 @@ out_dealloc_cmap:
 
 out_unmap_regs:
 	cg14_unmap_regs(op, info, par);
+	framebuffer_release(info);
 
 out_err:
 	return err;
diff --git a/drivers/video/cg6.c b/drivers/video/cg6.c
index 2b5a970..f3b8848 100644
--- a/drivers/video/cg6.c
+++ b/drivers/video/cg6.c
@@ -822,6 +822,7 @@ out_dealloc_cmap:
 
 out_unmap_regs:
 	cg6_unmap_regs(op, info, par);
+	framebuffer_release(info);
 
 out_err:
 	return err;
diff --git a/drivers/video/tcx.c b/drivers/video/tcx.c
index 77ad279..3d84235 100644
--- a/drivers/video/tcx.c
+++ b/drivers/video/tcx.c
@@ -481,6 +481,7 @@ out_dealloc_cmap:
 
 out_unmap_regs:
 	tcx_unmap_regs(op, info, par);
+	framebuffer_release(info);
 
 out_err:
 	return err;
-- 
1.7.1




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] video: add missing framebuffer_release in error path
  2011-02-15  9:35 [PATCH] video: add missing framebuffer_release in error path Axel Lin
@ 2011-02-15 18:53 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2011-02-15 18:53 UTC (permalink / raw)
  To: axel.lin; +Cc: linux-kernel, lethal, linux-fbdev

From: Axel Lin <axel.lin@gmail.com>
Date: Tue, 15 Feb 2011 17:35:02 +0800

> This patch fixes a memory leak in the error path.
> 
> Signed-off-by: Axel Lin <axel.lin@gmail.com>

Acked-by: David S. Miller <davem@davemloft.net>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-02-15 18:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-15  9:35 [PATCH] video: add missing framebuffer_release in error path Axel Lin
2011-02-15 18:53 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).