Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7f3976f0 authored by Mike Christie's avatar Mike Christie Committed by Christoph Hellwig
Browse files

qla4xxx: fix get_host_stats error propagation



qla4xxx was not always returning -EXYZ error codes when
qla4xxx_get_host_stats failed.

Signed-off-by: default avatarMike Christie <michaelc@cs.wisc.edu>
Acked-by: default avatarVikas Chaudhary <vikas.chaudhary@qlogic.com>
Reviewed-by: default avatarHannes Reinecke <hare@suse.de>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent a5c277ec
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -1050,6 +1050,7 @@ static int qla4xxx_get_host_stats(struct Scsi_Host *shost, char *buf, int len)
	if (!ql_iscsi_stats) {
		ql4_printk(KERN_ERR, ha,
			   "Unable to allocate memory for iscsi stats\n");
		ret = -ENOMEM;
		goto exit_host_stats;
	}

@@ -1058,6 +1059,7 @@ static int qla4xxx_get_host_stats(struct Scsi_Host *shost, char *buf, int len)
	if (ret != QLA_SUCCESS) {
		ql4_printk(KERN_ERR, ha,
			   "Unable to retrieve iscsi stats\n");
		ret = -EIO;
		goto exit_host_stats;
	}
	host_stats->mactx_frames = le64_to_cpu(ql_iscsi_stats->mac_tx_frames);