Skip to content
  1. Jun 10, 2021
  2. Jun 08, 2021
  3. Jun 03, 2021
  4. Jun 02, 2021
    • Martin K. Petersen's avatar
      Merge branch '5.14/scsi-result' into 5.14/scsi-staging · 1ff28f22
      Martin K. Petersen authored
      
      
      Include Hannes' SCSI command result rework in the staging branch.
      
      [mkp: remove DRIVER_SENSE from mpi3mr]
      
      Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
      1ff28f22
    • Mike Christie's avatar
      scsi: qedi: Wake up if cmd_cleanup_req is set · ed1b86ba
      Mike Christie authored
      
      
      If we got a response then we should always wake up the conn. For both the
      cmd_cleanup_req == 0 or cmd_cleanup_req > 0, we shouldn't dig into
      iscsi_itt_to_task because we don't know what the upper layers are doing.
      
      We can also remove the qedi_clear_task_idx call here because once we signal
      success libiscsi will loop over the affected commands and end up calling
      the cleanup_task callout which will release it.
      
      Link: https://lore.kernel.org/r/20210525181821.7617-29-michael.christie@oracle.com
      Reviewed-by: default avatarManish Rangankar <mrangankar@marvell.com>
      Signed-off-by: default avatarMike Christie <michael.christie@oracle.com>
      Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
      ed1b86ba
    • Mike Christie's avatar
      scsi: qedi: Complete TMF works before disconnect · b40f3894
      Mike Christie authored
      
      
      We need to make sure that abort and reset completion work has completed
      before ep_disconnect returns. After ep_disconnect we can't manipulate
      cmds because libiscsi will call conn_stop and take onwership.
      
      We are trying to make sure abort work and reset completion work has
      completed before we do the cmd clean up in ep_disconnect. The problem is
      that:
      
       1. the work function sets the QEDI_CONN_FW_CLEANUP bit, so if the work was
          still pending we would not see the bit set. We need to do this before
          the work is queued.
      
       2. If we had multiple works queued then we could break from the loop in
          qedi_ep_disconnect early because when abort work 1 completes it could
          clear QEDI_CONN_FW_CLEANUP. qedi_ep_disconnect could then see that
          before work 2 has run.
      
       3. A TMF reset completion work could run after ep_disconnect starts
          cleaning up cmds via qedi_clearsq. ep_disconnect's call to qedi_clearsq
          -> qedi_cleanup_all_io would might think it's done cleaning up cmds,
          but the reset completion work could still be running. We then return
          from ep_disconnect while still doing cleanup.
      
      This replaces the bit with a counter to track the number of queued TMF
      works, and adds a bool to prevent new works from starting from the
      completion path once a ep_disconnect starts.
      
      Link: https://lore.kernel.org/r/20210525181821.7617-28-michael.christie@oracle.com
      Reviewed-by: default avatarManish Rangankar <mrangankar@marvell.com>
      Signed-off-by: default avatarMike Christie <michael.christie@oracle.com>
      Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
      b40f3894