summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/gdth.c
diff options
context:
space:
mode:
authorMariusz Kozlowski <m.kozlowski@tuxland.pl>2007-08-11 10:13:24 +0200
committerJames Bottomley <jejb@mulgrave.localdomain>2007-10-12 20:41:00 +0200
commitbbfbbbc1182f8b44c8cc4c99f4a3f3a512149022 (patch)
treef7e3d50cda2e3d55bff88c2cc617d60df8ddb2cb /drivers/scsi/gdth.c
parent[SCSI] mpt fusion: Change company name from LSI Logic to LSI (diff)
downloadlinux-bbfbbbc1182f8b44c8cc4c99f4a3f3a512149022.tar.xz
linux-bbfbbbc1182f8b44c8cc4c99f4a3f3a512149022.zip
[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/gdth.c')
-rw-r--r--drivers/scsi/gdth.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c
index 55e4d2dc2bbe..b20c188cc529 100644
--- a/drivers/scsi/gdth.c
+++ b/drivers/scsi/gdth.c
@@ -726,10 +726,10 @@ int __gdth_execute(struct scsi_device *sdev, gdth_cmd_str *gdtcmd, char *cmnd,
DECLARE_COMPLETION_ONSTACK(wait);
int rval;
- scp = kmalloc(sizeof(*scp), GFP_KERNEL);
+ scp = kzalloc(sizeof(*scp), GFP_KERNEL);
if (!scp)
return -ENOMEM;
- memset(scp, 0, sizeof(*scp));
+
scp->device = sdev;
/* use request field to save the ptr. to completion struct. */
scp->request = (struct request *)&wait;
@@ -5518,10 +5518,9 @@ static int gdth_ioctl(struct inode *inode, struct file *filep,
ha = HADATA(gdth_ctr_tab[hanum]);
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)
- scp = kmalloc(sizeof(*scp), GFP_KERNEL);
+ scp = kzalloc(sizeof(*scp), GFP_KERNEL);
if (!scp)
return -ENOMEM;
- memset(scp, 0, sizeof(*scp));
scp->device = ha->sdev;
scp->cmd_len = 12;
scp->use_sg = 0;