1. 04 1月, 2018 26 次提交
  2. 05 12月, 2017 1 次提交
  3. 09 11月, 2017 1 次提交
  4. 17 10月, 2017 1 次提交
  5. 28 9月, 2017 1 次提交
    • G
      scsi: aacraid: Add a small delay after IOP reset · d1b49093
      Guilherme G. Piccoli 提交于
      Commit 0e9973ed ("scsi: aacraid: Add periodic checks to see IOP reset
      status") changed the way driver checks if a reset succeeded. Now, after an
      IOP reset, aacraid immediately start polling a register to verify the reset
      is complete.
      
      This behavior cause regressions on the reset path in PowerPC (at least).
      Since the delay after the IOP reset was removed by the aforementioned patch,
      the fact driver just starts to read a register instantly after the reset
      was issued (by writing in another register) "corrupts" the reset procedure,
      which ends up failing all the time.
      
      The issue highly impacted kdump on PowerPC, since on kdump path we
      proactively issue a reset in adapter (through the reset_devices kernel
      parameter).
      
      This patch (re-)adds a delay right after IOP reset is issued. Empirically
      we measured that 3 seconds is enough, but for safety reasons we delay
      for 5s (and since it was 30s before, 5s is still a small amount).
      
      For reference, without this patch we observe the following messages
      on kdump kernel boot process:
      
        [ 76.294] aacraid 0003:01:00.0: IOP reset failed
        [ 76.294] aacraid 0003:01:00.0: ARC Reset attempt failed
        [ 86.524] aacraid 0003:01:00.0: adapter kernel panic'd ff.
        [ 86.524] aacraid 0003:01:00.0: Controller reset type is 3
        [ 86.524] aacraid 0003:01:00.0: Issuing IOP reset
        [146.534] aacraid 0003:01:00.0: IOP reset failed
        [146.534] aacraid 0003:01:00.0: ARC Reset attempt failed
      
      Fixes: 0e9973ed ("scsi: aacraid: Add periodic checks to see IOP reset status")
      Cc: stable@vger.kernel.org # v4.13+
      Signed-off-by: NGuilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>
      Acked-by: NDave Carroll <david.carroll@microsemi.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      d1b49093
  6. 16 9月, 2017 2 次提交
  7. 31 8月, 2017 3 次提交
  8. 30 8月, 2017 1 次提交
    • B
      scsi: aacraid: Fix command send race condition · 1ae948fa
      Brian King 提交于
      This fixes a potential race condition observed on Power systems.
      
      Several places throughout the aacraid driver call aac_fib_send or
      similar to send a command to the aacraid adapter, then check the return
      code to determine if the command was actually sent to the adapter, then
      update the phase field in the scsi command scratch pad area to track
      that the firmware now owns this command.  However, there is nothing that
      ensures that by the time the aac_fib_send function returns and we go to
      write to the scsi command, that the command hasn't already completed and
      the scsi command has been freed.  This was causing random crashes in the
      TCP stack which was tracked down to be caused by memory that had been a
      struct request + scsi_cmnd being now used for an skbuff. Memory
      poisoning was enabled in the kernel to debug this which showed that the
      last owner of the memory that had been freed was aacraid and that it was
      a struct request.  The memory that was corrupted was the exact data
      pattern of AAC_OWNER_FIRMWARE and it was at the same offset that aacraid
      writes, which is scsicmd->SCp.phase. The patch below resolves this
      issue.
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NBrian King <brking@linux.vnet.ibm.com>
      Tested-by: NWen Xiong <wenxiong@linux.vnet.ibm.com>
      Reviewed-by: NDave Carroll <david.carroll@microsemi.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      1ae948fa
  9. 17 8月, 2017 1 次提交
  10. 08 8月, 2017 3 次提交