diff options
author | Andrew Vasquez <andrew.vasquez@qlogic.com> | 2009-03-24 09:07:55 -0700 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-04-03 09:22:44 -0500 |
commit | 08029990b25b76b1bc167336358bd21812567f2a (patch) | |
tree | 87cb617366a61bd643818996cc6186e817e23b63 /drivers/scsi/qla2xxx/qla_isr.c | |
parent | 534841b3c110b0f149513c7695751879951d3f22 (diff) | |
download | lwn-08029990b25b76b1bc167336358bd21812567f2a.tar.gz lwn-08029990b25b76b1bc167336358bd21812567f2a.zip |
[SCSI] qla2xxx: Refactor request/response-queue register handling.
Original code used an overabundance of indirect pointers to
function helpers. Instead, the driver can exploit the immutable
properties of a queue's ISP-association and ID, which are both
known at queue initialization-time.
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 | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c index f250e5b7897c..8e91f4aec977 100644 --- a/drivers/scsi/qla2xxx/qla_isr.c +++ b/drivers/scsi/qla2xxx/qla_isr.c @@ -1499,7 +1499,6 @@ qla24xx_mbx_completion(scsi_qla_host_t *vha, uint16_t mb0) void qla24xx_process_response_queue(struct rsp_que *rsp) { - struct qla_hw_data *ha = rsp->hw; struct sts_entry_24xx *pkt; struct scsi_qla_host *vha; @@ -1553,7 +1552,7 @@ qla24xx_process_response_queue(struct rsp_que *rsp) } /* Adjust ring index */ - ha->isp_ops->wrt_rsp_reg(ha, rsp->id, rsp->ring_index); + WRT_REG_DWORD(rsp->rsp_q_out, rsp->ring_index); } static void @@ -2117,18 +2116,3 @@ int qla25xx_request_irq(struct rsp_que *rsp) msix->rsp = rsp; return ret; } - -void -qla25xx_wrt_rsp_reg(struct qla_hw_data *ha, uint16_t id, uint16_t index) -{ - device_reg_t __iomem *reg = (void *) ha->mqiobase + QLA_QUE_PAGE * id; - WRT_REG_DWORD(®->isp25mq.rsp_q_out, index); -} - -void -qla24xx_wrt_rsp_reg(struct qla_hw_data *ha, uint16_t id, uint16_t index) -{ - device_reg_t __iomem *reg = (void *) ha->iobase; - WRT_REG_DWORD(®->isp24.rsp_q_out, index); -} - |