summaryrefslogtreecommitdiff
path: root/drivers/scsi/pm8001/pm8001_sas.h
diff options
context:
space:
mode:
authorJohn Garry <john.garry@huawei.com>2022-06-10 19:46:42 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2022-06-17 04:45:09 +0300
commit42f22fe36d51a621a065352898e369bd7983107f (patch)
tree11b7def7dba8702c849452f5eeef4eb16e7cda11 /drivers/scsi/pm8001/pm8001_sas.h
parent940f5efa63161642b32b8dd82c17089b8ada7cbb (diff)
downloadlinux-42f22fe36d51a621a065352898e369bd7983107f.tar.xz
scsi: pm8001: Expose hardware queues for pm80xx
In commit 05c6c029a44d ("scsi: pm80xx: Increase number of supported queues"), support for 80xx chip was improved by enabling multiple HW queues. In this, like other SCSI MQ HBA drivers at the time, the HW queues were not exposed to upper layer, and instead the driver managed the queues internally. However, this management duplicates blk-mq code. In addition, the HW queue management is sub-optimal for a system where the number of CPUs exceeds the HW queues - this is because queues are selected in a round-robin fashion, when it would be better to make adjacent CPUs submit on the same queue. And finally, the affinity of the completion queue interrupts is not set to mirror the cpu<->HQ queue mapping, which is suboptimal. As such, for when MSIX is supported, expose HW queues to upper layer. We always use queue index #0 for "internal" commands, i.e. anything which does not come from the block layer, so omit this from the affinity spreading. Link: https://lore.kernel.org/r/1654879602-33497-5-git-send-email-john.garry@huawei.com Tested-by: Damien Le Moal <damien.lemoal@opensource.wdc.com> Signed-off-by: John Garry <john.garry@huawei.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/pm8001/pm8001_sas.h')
-rw-r--r--drivers/scsi/pm8001/pm8001_sas.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/pm8001/pm8001_sas.h b/drivers/scsi/pm8001/pm8001_sas.h
index c761a2fd25e5..c5e3f380a01c 100644
--- a/drivers/scsi/pm8001/pm8001_sas.h
+++ b/drivers/scsi/pm8001/pm8001_sas.h
@@ -55,6 +55,8 @@
#include <scsi/scsi_tcq.h>
#include <scsi/sas_ata.h>
#include <linux/atomic.h>
+#include <linux/blk-mq.h>
+#include <linux/blk-mq-pci.h>
#include "pm8001_defs.h"
#define DRV_NAME "pm80xx"