aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/nvidia
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2007-02-12 03:55:12 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-12 12:48:43 -0500
commitf5610b9c3a2896fcaa623b92d0f24d83f10bb2c0 (patch)
treef4ff35f5991debf0f892794687abc574cdaacb4f /drivers/video/nvidia
parentc4f28e54d61278203c2bb2aea0679e0a738235d2 (diff)
[PATCH] Video: fb, kzalloc changes
Use kzalloc instead of kmalloc + memset(0). Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: James Simmons <jsimmons@infradead.org> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/nvidia')
-rw-r--r--drivers/video/nvidia/nvidia.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/video/nvidia/nvidia.c b/drivers/video/nvidia/nvidia.c
index 538e947610e1..f6731dadff3a 100644
--- a/drivers/video/nvidia/nvidia.c
+++ b/drivers/video/nvidia/nvidia.c
@@ -1205,13 +1205,11 @@ static int __devinit nvidiafb_probe(struct pci_dev *pd,
1205 par = info->par; 1205 par = info->par;
1206 par->pci_dev = pd; 1206 par->pci_dev = pd;
1207 1207
1208 info->pixmap.addr = kmalloc(8 * 1024, GFP_KERNEL); 1208 info->pixmap.addr = kzalloc(8 * 1024, GFP_KERNEL);
1209 1209
1210 if (info->pixmap.addr == NULL) 1210 if (info->pixmap.addr == NULL)
1211 goto err_out_kfree; 1211 goto err_out_kfree;
1212 1212
1213 memset(info->pixmap.addr, 0, 8 * 1024);
1214
1215 if (pci_enable_device(pd)) { 1213 if (pci_enable_device(pd)) {
1216 printk(KERN_ERR PFX "cannot enable PCI device\n"); 1214 printk(KERN_ERR PFX "cannot enable PCI device\n");
1217 goto err_out_enable; 1215 goto err_out_enable;