]> asedeno.scripts.mit.edu Git - linux.git/commit
scsi: lpfc: Limit tracking of tgt queue depth in fast path
authorJames Smart <jsmart2021@gmail.com>
Wed, 1 Aug 2018 00:23:22 +0000 (17:23 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 2 Aug 2018 19:45:19 +0000 (15:45 -0400)
commit2a5b7d626ed2256fd0ef0e799ebc6ef47b7bd283
tree63fb5737e68253ae59db6fa2d5a46fab21b90b02
parent93a3922da428ec0752e8b2ab00c42dadbbf805a9
scsi: lpfc: Limit tracking of tgt queue depth in fast path

Performance is affected when target queue depth is tracked.  An atomic
counter is incremented on the submission path which competes with it being
decremented on the completion path.  In addition, multiple CPUs can
simultaniously be manipulating this counter for the same ndlp.

Reduce the overhead by only performing the target increment/decrement when
the target queue depth is less than the overall adapter depth, thus is
actually meaningful.

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <james.smart@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_disc.h
drivers/scsi/lpfc/lpfc_nportdisc.c
drivers/scsi/lpfc/lpfc_nvme.c
drivers/scsi/lpfc/lpfc_nvme.h
drivers/scsi/lpfc/lpfc_scsi.c
drivers/scsi/lpfc/lpfc_scsi.h