lkml.org 
[lkml]   [2019]   [Nov]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH AUTOSEL 4.19 148/205] scsi: lpfc: Correct invalid EQ doorbell write on if_type=6
    Date
    From: James Smart <jsmart2021@gmail.com>

    [ Upstream commit aad59d5d34738d6fd8c359df8048a84cd443e504 ]

    During attachment, the driver writes the EQ doorbell to disable potential
    interrupts from an EQ. The current EQ doorbell format used for clearing the
    interrupt is incorrect and uses an if_type=2 format, making the operation act
    on the wrong EQ.

    Correct the code to use the proper if_type=6 EQ doorbell format.

    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>
    Signed-off-by: Sasha Levin <sashal@kernel.org>
    ---
    drivers/scsi/lpfc/lpfc_sli.c | 6 +-----
    1 file changed, 1 insertion(+), 5 deletions(-)

    diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
    index a490e63c94b67..e704297618e06 100644
    --- a/drivers/scsi/lpfc/lpfc_sli.c
    +++ b/drivers/scsi/lpfc/lpfc_sli.c
    @@ -392,11 +392,7 @@ lpfc_sli4_if6_eq_clr_intr(struct lpfc_queue *q)
    struct lpfc_register doorbell;

    doorbell.word0 = 0;
    - bf_set(lpfc_eqcq_doorbell_eqci, &doorbell, 1);
    - bf_set(lpfc_eqcq_doorbell_qt, &doorbell, LPFC_QUEUE_TYPE_EVENT);
    - bf_set(lpfc_eqcq_doorbell_eqid_hi, &doorbell,
    - (q->queue_id >> LPFC_EQID_HI_FIELD_SHIFT));
    - bf_set(lpfc_eqcq_doorbell_eqid_lo, &doorbell, q->queue_id);
    + bf_set(lpfc_if6_eq_doorbell_eqid, &doorbell, q->queue_id);
    writel(doorbell.word0, q->phba->sli4_hba.EQDBregaddr);
    }

    --
    2.20.1
    \
     
     \ /
      Last update: 2019-11-08 13:06    [W:4.358 / U:0.040 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site