1. 07 4月, 2017 1 次提交
    • H
      scsi: scsi_error: count medium access timeout only once per EH run · 7a38dc0b
      Hannes Reinecke 提交于
      The current medium access timeout counter will be increased for
      each command, so if there are enough failed commands we'll hit
      the medium access timeout for even a single device failure and
      the following kernel message is displayed:
      
      sd H:C:T:L: [sdXY] Medium access timeout failure. Offlining disk!
      
      Fix this by making the timeout per EH run, ie the counter will
      only be increased once per device and EH run.
      
      Fixes: 18a4d0a2 ("[SCSI] Handle disk devices which can not process medium access commands")
      Cc: Ewan Milne <emilne@redhat.com>
      Cc: Lawrence Obermann <loberman@redhat.com>
      Cc: Benjamin Block <bblock@linux.vnet.ibm.com>
      Cc: Steffen Maier <maier@linux.vnet.ibm.com>
      Signed-off-by: NHannes Reinecke <hare@suse.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      7a38dc0b
  2. 07 2月, 2017 1 次提交
  3. 01 2月, 2017 2 次提交
  4. 28 1月, 2017 2 次提交
  5. 28 10月, 2016 1 次提交
  6. 09 6月, 2016 1 次提交
    • W
      scsi: fix race between simultaneous decrements of ->host_failed · 72d8c36e
      Wei Fang 提交于
      sas_ata_strategy_handler() adds the works of the ata error handler to
      system_unbound_wq. This workqueue asynchronously runs work items, so the
      ata error handler will be performed concurrently on different CPUs. In
      this case, ->host_failed will be decreased simultaneously in
      scsi_eh_finish_cmd() on different CPUs, and become abnormal.
      
      It will lead to permanently inequality between ->host_failed and
      ->host_busy, and scsi error handler thread won't start running. IO
      errors after that won't be handled.
      
      Since all scmds must have been handled in the strategy handler, just
      remove the decrement in scsi_eh_finish_cmd() and zero ->host_busy after
      the strategy handler to fix this race.
      
      Fixes: 50824d6c ("[SCSI] libsas: async ata-eh")
      Cc: stable@vger.kernel.org
      Signed-off-by: NWei Fang <fangwei1@huawei.com>
      Reviewed-by: NJames Bottomley <jejb@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      72d8c36e
  7. 05 4月, 2016 1 次提交
  8. 07 11月, 2015 1 次提交
  9. 07 9月, 2015 1 次提交
  10. 29 8月, 2015 1 次提交
  11. 27 8月, 2015 1 次提交
  12. 26 8月, 2015 1 次提交
  13. 03 8月, 2015 1 次提交
  14. 31 7月, 2015 1 次提交
    • T
      scsi: fix memory leak with scsi-mq · 0c958ecc
      Tony Battersby 提交于
      Fix a memory leak with scsi-mq triggered by commands with large data
      transfer length.
      
      __sg_alloc_table() sets both table->nents and table->orig_nents to the
      same value.  When the scatterlist is DMA-mapped, table->nents is
      overwritten with the (possibly smaller) size of the DMA-mapped
      scatterlist, while table->orig_nents retains the original size of the
      allocated scatterlist.  scsi_free_sgtable() should therefore check
      orig_nents instead of nents, and all code that initializes sdb->table
      without calling __sg_alloc_table() should set both nents and orig_nents.
      
      Fixes: d285203c ("scsi: add support for a blk-mq based I/O path.")
      Cc: <stable@vger.kernel.org> # 3.17+
      Signed-off-by: NTony Battersby <tonyb@cybernetics.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NEwan D. Milne <emilne@redhat.com>
      Signed-off-by: NJames Bottomley <JBottomley@Odin.com>
      0c958ecc
  15. 24 7月, 2015 1 次提交
  16. 01 6月, 2015 1 次提交
  17. 27 3月, 2015 1 次提交
  18. 09 1月, 2015 2 次提交
  19. 31 12月, 2014 1 次提交
  20. 25 11月, 2014 1 次提交
  21. 24 11月, 2014 2 次提交
  22. 12 11月, 2014 7 次提交
  23. 10 11月, 2014 2 次提交
  24. 16 9月, 2014 1 次提交
  25. 29 8月, 2014 1 次提交
    • J
      block,scsi: fixup blk_get_request dead queue scenarios · a492f075
      Joe Lawrence 提交于
      The blk_get_request function may fail in low-memory conditions or during
      device removal (even if __GFP_WAIT is set). To distinguish between these
      errors, modify the blk_get_request call stack to return the appropriate
      ERR_PTR. Verify that all callers check the return status and consider
      IS_ERR instead of a simple NULL pointer check.
      
      For consistency, make a similar change to the blk_mq_alloc_request leg
      of blk_get_request.  It may fail if the queue is dead, or the caller was
      unwilling to wait.
      Signed-off-by: NJoe Lawrence <joe.lawrence@stratus.com>
      Acked-by: Jiri Kosina <jkosina@suse.cz> [for pktdvd]
      Acked-by: Boaz Harrosh <bharrosh@panasas.com> [for osd]
      Reviewed-by: NJeff Moyer <jmoyer@redhat.com>
      Signed-off-by: NJens Axboe <axboe@fb.com>
      a492f075
  26. 27 8月, 2014 1 次提交
  27. 25 7月, 2014 1 次提交
  28. 18 7月, 2014 2 次提交