Message ID | 20181004102909.12308-1-yuehaibing@huawei.com (mailing list archive) |
---|---|
State | Deferred |
Headers | show |
Series | [-next] scsi: lpfc: use correct maxch in lpfc_debugfs_nvmestat_data | expand |
diff --git a/drivers/scsi/lpfc/lpfc_debugfs.c b/drivers/scsi/lpfc/lpfc_debugfs.c index aec5b10..fe1ec0e 100644 --- a/drivers/scsi/lpfc/lpfc_debugfs.c +++ b/drivers/scsi/lpfc/lpfc_debugfs.c @@ -923,7 +923,7 @@ lpfc_debugfs_nvmestat_data(struct lpfc_vport *vport, char *buf, int size) maxch = 32; totin = 0; totout = 0; - for (i = 0; i < phba->cfg_nvme_io_channel; i++) { + for (i = 0; i < maxch; i++) { cstat = &lport->cstat[i]; tot = atomic_read(&cstat->fc4NvmeIoCmpls); totin += tot;
'maxch' should be used rather than 'phba->cfg_nvme_io_channel' Fixes:66a210ffb877 ("scsi: lpfc: Add per io channel NVME IO statistics") Signed-off-by: YueHaibing <yuehaibing@huawei.com> --- drivers/scsi/lpfc/lpfc_debugfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)