diff options
author | Mariusz Kozlowski <m.kozlowski@tuxland.pl> | 2007-08-11 10:13:24 +0200 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.localdomain> | 2007-10-12 14:41:00 -0400 |
commit | bbfbbbc1182f8b44c8cc4c99f4a3f3a512149022 (patch) | |
tree | f7e3d50cda2e3d55bff88c2cc617d60df8ddb2cb /drivers/scsi/a4000t.c | |
parent | f36789e22ac32a6554b8e4d05ab6125fc1161745 (diff) | |
download | op-kernel-dev-bbfbbbc1182f8b44c8cc4c99f4a3f3a512149022.zip op-kernel-dev-bbfbbbc1182f8b44c8cc4c99f4a3f3a512149022.tar.gz |
[SCSI] kmalloc + memset conversion to kzalloc
In NCR_D700, a4000t, aic7xxx_old, bvme6000, dpt_i2o, gdth, lpfc,
megaraid, mvme16x osst, pluto, qla2xxx, zorro7xx
Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/a4000t.c')
-rw-r--r-- | drivers/scsi/a4000t.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/scsi/a4000t.c b/drivers/scsi/a4000t.c index 0c758d1..d4bda20 100644 --- a/drivers/scsi/a4000t.c +++ b/drivers/scsi/a4000t.c @@ -37,7 +37,7 @@ static struct platform_device *a4000t_scsi_device; static int __devinit a4000t_probe(struct device *dev) { - struct Scsi_Host * host = NULL; + struct Scsi_Host *host; struct NCR_700_Host_Parameters *hostdata; if (!(MACH_IS_AMIGA && AMIGAHW_PRESENT(A4000_SCSI))) @@ -47,12 +47,11 @@ static int __devinit a4000t_probe(struct device *dev) "A4000T builtin SCSI")) goto out; - hostdata = kmalloc(sizeof(struct NCR_700_Host_Parameters), GFP_KERNEL); - if (hostdata == NULL) { + hostdata = kzalloc(sizeof(struct NCR_700_Host_Parameters), GFP_KERNEL); + if (!hostdata) { printk(KERN_ERR "a4000t-scsi: Failed to allocate host data\n"); goto out_release; } - memset(hostdata, 0, sizeof(struct NCR_700_Host_Parameters)); /* Fill in the required pieces of hostdata */ hostdata->base = (void __iomem *)ZTWO_VADDR(A4000T_SCSI_ADDR); |