mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
drivers/video/w100fb.c: avoid a couple of error-path NULL derefs
Fix a couple of error-patch oopses identified by Marcio Buss in http://bugzilla.kernel.org/show_bug.cgi?id=9567. Cc: Marcio Buss <[email protected]> Cc: Jeff Zhou <[email protected]> Cc: "Antonino A. Daplas" <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
0e170c72c0
commit
8224c3b166
1 changed files with 4 additions and 2 deletions
|
|
@ -765,8 +765,10 @@ int __init w100fb_probe(struct platform_device *pdev)
|
|||
printk(KERN_INFO "fb%d: %s frame buffer device\n", info->node, info->fix.id);
|
||||
return 0;
|
||||
out:
|
||||
fb_dealloc_cmap(&info->cmap);
|
||||
kfree(info->pseudo_palette);
|
||||
if (info) {
|
||||
fb_dealloc_cmap(&info->cmap);
|
||||
kfree(info->pseudo_palette);
|
||||
}
|
||||
if (remapped_fbuf != NULL)
|
||||
iounmap(remapped_fbuf);
|
||||
if (remapped_regs != NULL)
|
||||
|
|
|
|||
Loading…
Reference in a new issue