1. 15 12月, 2016 1 次提交
  2. 16 7月, 2016 12 次提交
  3. 24 2月, 2016 4 次提交
  4. 08 1月, 2016 5 次提交
  5. 27 8月, 2015 6 次提交
  6. 25 7月, 2015 4 次提交
    • A
      qla2xxx: added sess generations to detect RSCN update races · df673274
      Alexei Potashnik 提交于
      RSCN processing in qla2xxx driver can run in parallel with ELS/IO
      processing. As such the decision to remove disappeared fc port's
      session could be stale, because a new login sequence has occurred
      since and created a brand new session.
      
      Previous mechanism of dealing with this by delaying deletion request
      was prone to erroneous deletions if the event that was supposed to
      cancel the deletion never arrived or has been delayed in processing.
      
      New mechanism relies on a time-like generation counter to serialize
      RSCN updates relative to ELS/IO updates.
      
      Cc: <stable@vger.kernel.org> # v3.18+
      Signed-off-by: NAlexei Potashnik <alexei@purestorage.com>
      Signed-off-by: NHimanshu Madhani <himanshu.madhani@qlogic.com>
      Signed-off-by: NNicholas Bellinger <nab@linux-iscsi.org>
      df673274
    • A
      qla2xxx: delay plogi/prli ack until existing sessions are deleted · a6ca8878
      Alexei Potashnik 提交于
      - keep qla_tgt_sess object on the session list until it's freed
      
      - modify use of sess->deleted flag to differentiate delayed
        session deletion that can be cancelled from irreversible one:
        QLA_SESS_DELETION_PENDING vs QLA_SESS_DELETION_IN_PROGRESS
      
      - during IN_PROGRESS deletion all newly arrived commands and TMRs will
        be rejected, existing commands and TMRs will be terminated when
        given by the core to the fabric or simply dropped if session logout
        has already happened (logout terminates all existing exchanges)
      
      - new PLOGI will initiate deletion of the following sessions
        (unless deletion is already IN_PROGRESS):
        - with the same port_name (with logout)
        - different port_name, different loop_id but the same port_id
          (with logout)
        - different port_name, different port_id, but the same loop_id
          (without logout)
      
      - additionally each new PLOGI will store imm notify iocb in the
        same port_name session being deleted. When deletion process
        completes this iocb will be acked. Only the most recent PLOGI
        iocb is stored. The older ones will be terminated when replaced.
      
      - new PRLI will initiate deletion of the following sessions
        (unless deletion is already IN_PROGRESS):
        - different port_name, different port_id, but the same loop_id
         (without logout)
      
      Cc: <stable@vger.kernel.org> # v3.18+
      Signed-off-by: NAlexei Potashnik <alexei@purestorage.com>
      Acked-by: NQuinn Tran <quinn.tran@qlogic.com>
      Signed-off-by: NHimanshu Madhani <himanshu.madhani@qlogic.com>
      Signed-off-by: NNicholas Bellinger <nab@linux-iscsi.org>
      a6ca8878
    • S
      qla2xxx: cleanup cmd in qla workqueue before processing TMR · 8b2f5ff3
      Swapnil Nagle 提交于
      Since cmds go into qla_tgt_wq and TMRs don't, it's possible that TMR
      like TASK_ABORT can be queued over the cmd for which it was meant.
      To avoid this race, use a per-port list to keep track of cmds that
      are enqueued to qla_tgt_wq but not yet processed. When a TMR arrives,
      iterate through this list and remove any cmds that match the TMR.
      This patch supports TASK_ABORT and LUN_RESET.
      
      Cc: <stable@vger.kernel.org> # v3.18+
      Signed-off-by: NSwapnil Nagle <swapnil.nagle@purestorage.com>
      Signed-off-by: NAlexei Potashnik <alexei@purestorage.com>
      Acked-by: NQuinn Tran <quinn.tran@qlogic.com>
      Signed-off-by: NHimanshu Madhani <himanshu.madhani@qlogic.com>
      Signed-off-by: NNicholas Bellinger <nab@linux-iscsi.org>
      8b2f5ff3
    • R
      qla2xxx: kill sessions/log out initiator on RSCN and port down events · b2032fd5
      Roland Dreier 提交于
      To fix some issues talking to ESX, this patch modifies the qla2xxx driver
      so that it never logs into remote ports.  This has the side effect of
      getting rid of the "rports" entirely, which means we never log out of
      initiators and never tear down sessions when an initiator goes away.
      
      This is mostly OK, except that we can run into trouble if we have
      initiator A assigned FC address X:Y:Z by the fabric talking to us, and
      then initiator A goes away.  Some time (could be a long time) later,
      initiator B comes along and also gets FC address X:Y:Z (which is
      available again, because initiator A is gone).  If initiator B starts
      talking to us, then we'll still have the session for initiator A, and
      since we look up incoming IO based on the FC address X:Y:Z, initiator B
      will end up using ACLs for initiator A.
      
      Fix this by:
      
       1. Handling RSCN events somewhat differently; instead of completely
          skipping the processing of fcports, we look through the list, and if
          an fcport disappears, we tell the target code the tear down the
          session and tell the HBA FW to release the N_Port handle.
      
       2. Handling "port down" events by flushing all of our sessions.  The
          firmware was already releasing the N_Port handle but we want the
          target code to drop all the sessions too.
      
      Cc: <stable@vger.kernel.org> # v3.18+
      Signed-off-by: NRoland Dreier <roland@purestorage.com>
      Signed-off-by: NAlexei Potashnik <alexei@purestorage.com>
      Acked-by: NQuinn Tran <quinn.tran@qlogic.com>
      Signed-off-by: NHimanshu Madhani <himanshu.madhani@qlogic.com>
      Signed-off-by: NNicholas Bellinger <nab@linux-iscsi.org>
      b2032fd5
  7. 10 4月, 2015 3 次提交
  8. 25 9月, 2014 5 次提交