浏览代码

iscsi class: fix get_host_stats return code when not supported

When the get_host_stats call was not supported we were
returing EINVAL. This has us return ENOSYS, because for
software iscsi drivers where there is no host it is ok to not
have this callout.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Acked-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Mike Christie 11 年之前
父节点
当前提交
719e5874d0
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/scsi/scsi_transport_iscsi.c

+ 1 - 1
drivers/scsi/scsi_transport_iscsi.c

@@ -3429,7 +3429,7 @@ iscsi_get_host_stats(struct iscsi_transport *transport, struct nlmsghdr *nlh)
 	char *buf;
 
 	if (!transport->get_host_stats)
-		return -EINVAL;
+		return -ENOSYS;
 
 	priv = iscsi_if_transport_lookup(transport);
 	if (!priv)