aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/parisc/lba_pci.c
diff options
context:
space:
mode:
authorHelge Deller <deller@parisc-linux.org>2006-01-17 14:40:40 -0500
committerKyle McMartin <kyle@duet.int.mcmartin.ca>2006-01-22 20:26:31 -0500
commitcb6fc18e9ca615f03d18e60c49855b434ca2e51e (patch)
treec35af13054f8eeb7a24c928edf55fdc69c912562 /drivers/parisc/lba_pci.c
parenta1c744439591b1d4350f0926615d501e7cfbb708 (diff)
[PARISC] Use kzalloc and other janitor-style cleanups
Helge, o Convert a bunch of kmalloc/memset uses to kzalloc. o pci.c: Add some __read_mostly annotations. o pci.c: Move constant pci_post_reset_delay to asm/pci.h o grfioctl.h: Add A4450A to comment of CRT_ID_VISUALIZE_EG. o Add some consts to perf.c/perf_images.h Matthew, o sticore.c: Add some consts to suppress compile warnings. Signed-off-by: Helge Deller <deller@parisc-linux.org> Signed-off-by: Matthew Wilcox <willy@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'drivers/parisc/lba_pci.c')
-rw-r--r--drivers/parisc/lba_pci.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/parisc/lba_pci.c b/drivers/parisc/lba_pci.c
index cbae8c8963fa..e8a2a4a852f5 100644
--- a/drivers/parisc/lba_pci.c
+++ b/drivers/parisc/lba_pci.c
@@ -1565,7 +1565,7 @@ lba_driver_probe(struct parisc_device *dev)
1565 } else if (IS_MERCURY(dev) || IS_QUICKSILVER(dev)) { 1565 } else if (IS_MERCURY(dev) || IS_QUICKSILVER(dev)) {
1566 func_class &= 0xff; 1566 func_class &= 0xff;
1567 version = kmalloc(6, GFP_KERNEL); 1567 version = kmalloc(6, GFP_KERNEL);
1568 sprintf(version,"TR%d.%d",(func_class >> 4),(func_class & 0xf)); 1568 snprintf(version, 6, "TR%d.%d",(func_class >> 4),(func_class & 0xf));
1569 /* We could use one printk for both Elroy and Mercury, 1569 /* We could use one printk for both Elroy and Mercury,
1570 * but for the mask for func_class. 1570 * but for the mask for func_class.
1571 */ 1571 */
@@ -1586,14 +1586,12 @@ lba_driver_probe(struct parisc_device *dev)
1586 ** have an IRT entry will get NULL back from iosapic code. 1586 ** have an IRT entry will get NULL back from iosapic code.
1587 */ 1587 */
1588 1588
1589 lba_dev = kmalloc(sizeof(struct lba_device), GFP_KERNEL); 1589 lba_dev = kzalloc(sizeof(struct lba_device), GFP_KERNEL);
1590 if (!lba_dev) { 1590 if (!lba_dev) {
1591 printk(KERN_ERR "lba_init_chip - couldn't alloc lba_device\n"); 1591 printk(KERN_ERR "lba_init_chip - couldn't alloc lba_device\n");
1592 return(1); 1592 return(1);
1593 } 1593 }
1594 1594
1595 memset(lba_dev, 0, sizeof(struct lba_device));
1596
1597 1595
1598 /* ---------- First : initialize data we already have --------- */ 1596 /* ---------- First : initialize data we already have --------- */
1599 1597