summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Easi <arun.easi@qlogic.com>2014-09-25 06:14:45 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-10-30 09:43:08 -0700
commit4778734aaa2cbb03f01a552cd7d9eb626ededb25 (patch)
tree8fdf65a8bad429b6af9eb2a021225ce9962bc8dd
parentd20854ce0d0d5db912539e5b1c5d2635a4bcb147 (diff)
qla2xxx: Use correct offset to req-q-out for reserve calculation
commit 75554b68ac1e018bca00d68a430b92ada8ab52dd upstream. Signed-off-by: Arun Easi <arun.easi@qlogic.com> Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/scsi/qla2xxx/qla_target.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/scsi/qla2xxx/qla_target.c b/drivers/scsi/qla2xxx/qla_target.c
index e44fcb53bdaca..bcc449a0c3a7d 100644
--- a/drivers/scsi/qla2xxx/qla_target.c
+++ b/drivers/scsi/qla2xxx/qla_target.c
@@ -1431,12 +1431,10 @@ static inline void qlt_unmap_sg(struct scsi_qla_host *vha,
static int qlt_check_reserve_free_req(struct scsi_qla_host *vha,
uint32_t req_cnt)
{
- struct qla_hw_data *ha = vha->hw;
- device_reg_t __iomem *reg = ha->iobase;
uint32_t cnt;
if (vha->req->cnt < (req_cnt + 2)) {
- cnt = (uint16_t)RD_REG_DWORD(&reg->isp24.req_q_out);
+ cnt = (uint16_t)RD_REG_DWORD(vha->req->req_q_out);
ql_dbg(ql_dbg_tgt, vha, 0xe00a,
"Request ring circled: cnt=%d, vha->->ring_index=%d, "