video: ffb: fix ffb_probe error path

Started by Axel Lin on Feb 8, 2011 · 2 messages from 2 authors · Last reply Feb 8, 2011

Subsystems (2)

Maintainers (2)

STALE5758d

open the first message on its own page

Message details and related content
Current implementation calls of_iounmap for par->fbc twice in error path.
In the case of goto out_unmap_dac, we should call of_iounmap for par->dac.

Signed-off-by: Axel Lin <redacted>
---
 drivers/video/ffb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/video/ffb.c b/drivers/video/ffb.c
index 6739b2a..b5d6a46 100644
--- a/drivers/video/ffb.c
+++ b/drivers/video/ffb.c
@@ -1011,7 +1011,7 @@ out_dealloc_cmap:
 	fb_dealloc_cmap(&info->cmap);
 
 out_unmap_dac:
-	of_iounmap(&op->resource[2], par->fbc, sizeof(struct ffb_fbc));
+	of_iounmap(&op->resource[1], par->dac, sizeof(struct ffb_dac));
 
 out_unmap_fbc:
 	of_iounmap(&op->resource[2], par->fbc, sizeof(struct ffb_fbc));
-- 
1.7.1


Message details and related content
From: Axel Lin <redacted>
Date: Tue, 08 Feb 2011 22:58:45 +0800
Current implementation calls of_iounmap for par->fbc twice in error path.
In the case of goto out_unmap_dac, we should call of_iounmap for par->dac.

Signed-off-by: Axel Lin <redacted>
Good spotting:

Acked-by: David S. Miller <davem@davemloft.net>
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help