]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: lpfc: Fix lpfc_nvmet_mrq attribute handling when 0
authorJames Smart <jsmart2021@gmail.com>
Tue, 12 Mar 2019 23:30:10 +0000 (16:30 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 19 Mar 2019 16:57:02 +0000 (12:57 -0400)
commite895a1daf3a0dfef43e703fe7b5699464076d6dc
tree40bab99d417b919e9abe7788a72a0a6d70f48608
parent9b4afd006fc0c9c6ed7ef53e839c7634dc266647
scsi: lpfc: Fix lpfc_nvmet_mrq attribute handling when 0

Currently, when lpfc_nvmet_mrq is 0 it could mean 2 different things
depending on when its looked at. If at module load time it specifies the
default number of hardware queues to allocate, with 0 meaning default to
the number of CPUs. But post module load, a value of zero means to disable
mrq use.

Changed the driver so that enablement of mrq is based on whether nvme
target mode is enabled or not. When enabled, mrq is enabled.  Thus, the
cfg_nvemt_mrq field only specifies the number of mrq queues to enable, with
0 defaulting to the number of cpus.

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <jsmart2021@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_attr.c
drivers/scsi/lpfc/lpfc_init.c
drivers/scsi/lpfc/lpfc_nvmet.h