aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi/zfcp_scsi.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/s390/scsi/zfcp_scsi.c')
-rw-r--r--drivers/s390/scsi/zfcp_scsi.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/s390/scsi/zfcp_scsi.c b/drivers/s390/scsi/zfcp_scsi.c
index 118cf0fa0afc..3a180d80c3cb 100644
--- a/drivers/s390/scsi/zfcp_scsi.c
+++ b/drivers/s390/scsi/zfcp_scsi.c
@@ -761,10 +761,9 @@ zfcp_get_fc_host_stats(struct Scsi_Host *shost)
761 if (!fc_stats) 761 if (!fc_stats)
762 return NULL; 762 return NULL;
763 763
764 data = kmalloc(sizeof(*data), GFP_KERNEL); 764 data = kzalloc(sizeof(*data), GFP_KERNEL);
765 if (!data) 765 if (!data)
766 return NULL; 766 return NULL;
767 memset(data, 0, sizeof(*data));
768 767
769 ret = zfcp_fsf_exchange_port_data(NULL, adapter, data); 768 ret = zfcp_fsf_exchange_port_data(NULL, adapter, data);
770 if (ret) { 769 if (ret) {
@@ -792,10 +791,9 @@ zfcp_reset_fc_host_stats(struct Scsi_Host *shost)
792 int ret; 791 int ret;
793 792
794 adapter = (struct zfcp_adapter *)shost->hostdata[0]; 793 adapter = (struct zfcp_adapter *)shost->hostdata[0];
795 data = kmalloc(sizeof(*data), GFP_KERNEL); 794 data = kzalloc(sizeof(*data), GFP_KERNEL);
796 if (!data) 795 if (!data)
797 return; 796 return;
798 memset(data, 0, sizeof(*data));
799 797
800 ret = zfcp_fsf_exchange_port_data(NULL, adapter, data); 798 ret = zfcp_fsf_exchange_port_data(NULL, adapter, data);
801 if (ret == 0) { 799 if (ret == 0) {