mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
fbdev: bf54x-lq043fb: use kzalloc over kmalloc/memset
Signed-off-by: Mike Frysinger <[email protected]> Cc: Krzysztof Helt <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
8f09d74a61
commit
a34601c5d8
1 changed files with 1 additions and 3 deletions
|
|
@ -630,7 +630,7 @@ static int __devinit bfin_bf54x_probe(struct platform_device *pdev)
|
|||
|
||||
fbinfo->fbops = &bfin_bf54x_fb_ops;
|
||||
|
||||
fbinfo->pseudo_palette = kmalloc(sizeof(u32) * 16, GFP_KERNEL);
|
||||
fbinfo->pseudo_palette = kzalloc(sizeof(u32) * 16, GFP_KERNEL);
|
||||
if (!fbinfo->pseudo_palette) {
|
||||
printk(KERN_ERR DRIVER_NAME
|
||||
"Fail to allocate pseudo_palette\n");
|
||||
|
|
@ -639,8 +639,6 @@ static int __devinit bfin_bf54x_probe(struct platform_device *pdev)
|
|||
goto out4;
|
||||
}
|
||||
|
||||
memset(fbinfo->pseudo_palette, 0, sizeof(u32) * 16);
|
||||
|
||||
if (fb_alloc_cmap(&fbinfo->cmap, BFIN_LCD_NBR_PALETTE_ENTRIES, 0)
|
||||
< 0) {
|
||||
printk(KERN_ERR DRIVER_NAME
|
||||
|
|
|
|||
Loading…
Reference in a new issue