projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
57a7a6d
)
video/aty/atyfb_base.c: free when fb can't be registered
author
Roel Kluin
<
[email protected]
>
Mon, 28 Apr 2008 09:15:04 +0000
(
02:15
-0700)
committer
Linus Torvalds
<
[email protected]
>
Mon, 28 Apr 2008 15:58:37 +0000
(08:58 -0700)
Free buffer when the framebuffer can't be registered
Signed-off-by: Roel Kluin <
[email protected]
>
Cc: "Antonino A. Daplas" <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
drivers/video/aty/atyfb_base.c
patch
|
blob
|
history
diff --git
a/drivers/video/aty/atyfb_base.c
b/drivers/video/aty/atyfb_base.c
index 62f9c6e387ccc3de3e65714ccec28c42eb38a7b8..e4bcf5376a9964095d8e18eddbc680b8538acfe7 100644
(file)
--- a/
drivers/video/aty/atyfb_base.c
+++ b/
drivers/video/aty/atyfb_base.c
@@
-2621,10
+2621,13
@@
static int __devinit aty_init(struct fb_info *info)
#endif /* CONFIG_FB_ATY_CT */
info->var = var;
- fb_alloc_cmap(&info->cmap, 256, 0);
+ if (fb_alloc_cmap(&info->cmap, 256, 0) < 0)
+ goto aty_init_exit;
- if (register_framebuffer(info) < 0)
+ if (register_framebuffer(info) < 0) {
+ fb_dealloc_cmap(&info->cmap);
goto aty_init_exit;
+ }
fb_list = info;