aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/message/fusion/mptbase.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2006-01-13 12:27:50 -0500
committerJames Bottomley <jejb@mulgrave.(none)>2006-01-14 11:54:58 -0500
commit1ca00bb7916cb40b8140173c23481e11d92d6f6a (patch)
treee5a16f6f230556ce43f77139c729f09a16ec95fb /drivers/message/fusion/mptbase.c
parenteeb846cefdd842af479393a7d0fd399a29e42532 (diff)
[SCSI] fusion: kzalloc / kcalloc conversion
Convert kmalloc + memset to kzalloc or kcalloc in fusion. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/message/fusion/mptbase.c')
-rw-r--r--drivers/message/fusion/mptbase.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/message/fusion/mptbase.c b/drivers/message/fusion/mptbase.c
index 537836068c49..80ec89c505d2 100644
--- a/drivers/message/fusion/mptbase.c
+++ b/drivers/message/fusion/mptbase.c
@@ -1232,12 +1232,11 @@ mpt_attach(struct pci_dev *pdev, const struct pci_device_id *id)
1232 dprintk((KERN_INFO MYNAM 1232 dprintk((KERN_INFO MYNAM
1233 ": Not using 64 bit consistent mask\n")); 1233 ": Not using 64 bit consistent mask\n"));
1234 1234
1235 ioc = kmalloc(sizeof(MPT_ADAPTER), GFP_ATOMIC); 1235 ioc = kzalloc(sizeof(MPT_ADAPTER), GFP_ATOMIC);
1236 if (ioc == NULL) { 1236 if (ioc == NULL) {
1237 printk(KERN_ERR MYNAM ": ERROR - Insufficient memory to add adapter!\n"); 1237 printk(KERN_ERR MYNAM ": ERROR - Insufficient memory to add adapter!\n");
1238 return -ENOMEM; 1238 return -ENOMEM;
1239 } 1239 }
1240 memset(ioc, 0, sizeof(MPT_ADAPTER));
1241 ioc->alloc_total = sizeof(MPT_ADAPTER); 1240 ioc->alloc_total = sizeof(MPT_ADAPTER);
1242 ioc->req_sz = MPT_DEFAULT_FRAME_SIZE; /* avoid div by zero! */ 1241 ioc->req_sz = MPT_DEFAULT_FRAME_SIZE; /* avoid div by zero! */
1243 ioc->reply_sz = MPT_REPLY_FRAME_SIZE; 1242 ioc->reply_sz = MPT_REPLY_FRAME_SIZE;