From: FUJITA Tomonori Date: Tue, 31 Jul 2007 23:40:27 +0000 (+0900) Subject: [SCSI] initialize shost_data to zero X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=c000c43cf12090972fad0fbb621d78c2100d0373;p=openwrt%2Fstaging%2Fblogic.git [SCSI] initialize shost_data to zero It's better to initialize host->shost_data to zero like target->starget_data and device->sdev_data. Signed-off-by: FUJITA Tomonori Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/hosts.c b/drivers/scsi/hosts.c index bd8e7f323c69..96bc31266c98 100644 --- a/drivers/scsi/hosts.c +++ b/drivers/scsi/hosts.c @@ -220,7 +220,7 @@ int scsi_add_host(struct Scsi_Host *shost, struct device *dev) get_device(&shost->shost_gendev); if (shost->transportt->host_size && - (shost->shost_data = kmalloc(shost->transportt->host_size, + (shost->shost_data = kzalloc(shost->transportt->host_size, GFP_KERNEL)) == NULL) goto out_del_classdev;