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

Commit 2f7608fc authored by Mike Christie's avatar Mike Christie Committed by Christoph Hellwig
Browse files

iscsi class: fix get_host_stats error handling



iscsi_get_host_stats was dropping the error code returned
by drivers like qla4xxx.

Signed-off-by: default avatarMike Christie <michaelc@cs.wisc.edu>
Acked-by: default avatarVikas Chaudhary <vikas.chaudhary@qlogic.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent 7f3976f0
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -3467,6 +3467,10 @@ iscsi_get_host_stats(struct iscsi_transport *transport, struct nlmsghdr *nlh)
		memset(buf, 0, host_stats_size);

		err = transport->get_host_stats(shost, buf, host_stats_size);
		if (err) {
			kfree(skbhost_stats);
			goto exit_host_stats;
		}

		actual_size = nlmsg_total_size(sizeof(*ev) + host_stats_size);
		skb_trim(skbhost_stats, NLMSG_ALIGN(actual_size));