diff options
| author | Anirban Chakraborty <anirban.chakraborty@qlogic.com> | 2009-04-07 01:33:41 -0400 |
|---|---|---|
| committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-05-20 18:21:08 -0400 |
| commit | 68ca949cdb04b4dc71451a999148fbc5f187a220 (patch) | |
| tree | d1d06940e8f128804529386ccea9c0757e61db0f /drivers/scsi/qla2xxx/qla_isr.c | |
| parent | 2afa19a9377ca61b9489e44bf50029574fbe63be (diff) | |
[SCSI] qla2xxx: Add CPU affinity support.
Set the module parameter ql2xmultique_tag to 1 to enable this
feature. In this mode, the total number of response queues
created is equal to the number of online cpus. Turning the block
layer's rq_affinity mode on enables requests to be routed to the
proper cpu and at the same time it enables completion of the IO
in a response queue that is affined to the cpu in the request
path.
Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com>
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_isr.c')
| -rw-r--r-- | drivers/scsi/qla2xxx/qla_isr.c | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c index c8e906c702a1..41e50c2bec0f 100644 --- a/drivers/scsi/qla2xxx/qla_isr.c +++ b/drivers/scsi/qla2xxx/qla_isr.c | |||
| @@ -1718,6 +1718,25 @@ qla24xx_msix_rsp_q(int irq, void *dev_id) | |||
| 1718 | } | 1718 | } |
| 1719 | 1719 | ||
| 1720 | static irqreturn_t | 1720 | static irqreturn_t |
| 1721 | qla25xx_msix_rsp_q(int irq, void *dev_id) | ||
| 1722 | { | ||
| 1723 | struct qla_hw_data *ha; | ||
| 1724 | struct rsp_que *rsp; | ||
| 1725 | |||
| 1726 | rsp = (struct rsp_que *) dev_id; | ||
| 1727 | if (!rsp) { | ||
| 1728 | printk(KERN_INFO | ||
| 1729 | "%s(): NULL response queue pointer\n", __func__); | ||
| 1730 | return IRQ_NONE; | ||
| 1731 | } | ||
| 1732 | ha = rsp->hw; | ||
| 1733 | |||
| 1734 | queue_work_on((int) (rsp->id - 1), ha->wq, &rsp->q_work); | ||
| 1735 | |||
| 1736 | return IRQ_HANDLED; | ||
| 1737 | } | ||
| 1738 | |||
| 1739 | static irqreturn_t | ||
| 1721 | qla24xx_msix_default(int irq, void *dev_id) | 1740 | qla24xx_msix_default(int irq, void *dev_id) |
| 1722 | { | 1741 | { |
| 1723 | scsi_qla_host_t *vha; | 1742 | scsi_qla_host_t *vha; |
| @@ -1806,9 +1825,10 @@ struct qla_init_msix_entry { | |||
| 1806 | irq_handler_t handler; | 1825 | irq_handler_t handler; |
| 1807 | }; | 1826 | }; |
| 1808 | 1827 | ||
| 1809 | static struct qla_init_msix_entry msix_entries[2] = { | 1828 | static struct qla_init_msix_entry msix_entries[3] = { |
| 1810 | { "qla2xxx (default)", qla24xx_msix_default }, | 1829 | { "qla2xxx (default)", qla24xx_msix_default }, |
| 1811 | { "qla2xxx (rsp_q)", qla24xx_msix_rsp_q }, | 1830 | { "qla2xxx (rsp_q)", qla24xx_msix_rsp_q }, |
| 1831 | { "qla2xxx (multiq)", qla25xx_msix_rsp_q }, | ||
| 1812 | }; | 1832 | }; |
| 1813 | 1833 | ||
| 1814 | static void | 1834 | static void |
