1. 23 9月, 2014 2 次提交
  2. 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
  3. 23 8月, 2014 1 次提交
  4. 20 8月, 2014 1 次提交
    • G
      scsi: Fix qemu boot hang problem · 480cadc2
      Guenter Roeck 提交于
      The latest kernel fails to boot qemu arm images when using scsi
      for disk access. Boot gets stuck after the following messages.
      
      brd: module loaded
      sym53c8xx 0000:00:0c.0: enabling device (0100 -> 0103)
      sym0: <895a> rev 0x0 at pci 0000:00:0c.0 irq 93
      sym0: No NVRAM, ID 7, Fast-40, LVD, parity checking
      sym0: SCSI BUS has been reset.
      scsi host0: sym-2.2.3
      
      Bisect points to commit 71e75c97 ("scsi: convert device_busy to
      atomic_t"). Code inspection shows the following suspicious change
      in scsi_request_fn.
      
      out_delay:
      -       if (sdev->device_busy == 0 && !scsi_device_blocked(sdev))
      +       if (atomic_read(&sdev->device_busy) && !scsi_device_blocked(sdev))
      		blk_delay_queue(q, SCSI_QUEUE_DELAY);
      	}
      
      'sdev->device_busy == 0' was replaced with 'atomic_read(&sdev->device_busy)',
      meaning the logic was reversed. Changing this expression to
      '!atomic_read(&sdev->device_busy)' fixes the problem.
      Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
      Reviewed-by: NHannes Reinecke <hare@suse.de>
      Acked-by: NJens Axboe <axboe@fb.com>
      Reviewed-by: NVenkatesh Srinivas <venkateshs@google.com>
      Reviewed-by: NWebb Scales <webbnh@hp.com>
      Cc: Christoph Hellwig <hch@lst.de>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      480cadc2
  5. 16 8月, 2014 1 次提交
    • G
      [SCSI] fix qemu boot hang problem · 045065d8
      Guenter Roeck 提交于
      The latest kernel fails to boot qemu arm images when using scsi
      for disk access. Boot gets stuck after the following messages.
      
      brd: module loaded
      sym53c8xx 0000:00:0c.0: enabling device (0100 -> 0103)
      sym0: <895a> rev 0x0 at pci 0000:00:0c.0 irq 93
      sym0: No NVRAM, ID 7, Fast-40, LVD, parity checking
      sym0: SCSI BUS has been reset.
      scsi host0: sym-2.2.3
      
      Bisect points to commit 71e75c97 ("scsi: convert device_busy to
      atomic_t"). Code inspection shows the following suspicious change
      in scsi_request_fn.
      
      out_delay:
      -       if (sdev->device_busy == 0 && !scsi_device_blocked(sdev))
      +       if (atomic_read(&sdev->device_busy) && !scsi_device_blocked(sdev))
      		blk_delay_queue(q, SCSI_QUEUE_DELAY);
      	}
      
      'sdev->device_busy == 0' was replaced with 'atomic_read(&sdev->device_busy)',
      meaning the logic was reversed. Changing this expression to
      '!atomic_read(&sdev->device_busy)' fixes the problem.
      Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
      Reviewed-by: NHannes Reinecke <hare@suse.de>
      Acked-by: NJens Axboe <axboe@fb.com>
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Fixes: 71e75c97Signed-off-by: NJames Bottomley <JBottomley@Parallels.com>
      045065d8
  6. 26 7月, 2014 5 次提交
  7. 25 7月, 2014 8 次提交
  8. 18 7月, 2014 8 次提交
  9. 06 6月, 2014 1 次提交
    • J
      block: add blk_rq_set_block_pc() · f27b087b
      Jens Axboe 提交于
      With the optimizations around not clearing the full request at alloc
      time, we are leaving some of the needed init for REQ_TYPE_BLOCK_PC
      up to the user allocating the request.
      
      Add a blk_rq_set_block_pc() that sets the command type to
      REQ_TYPE_BLOCK_PC, and properly initializes the members associated
      with this type of request. Update callers to use this function instead
      of manipulating rq->cmd_type directly.
      
      Includes fixes from Christoph Hellwig <hch@lst.de> for my half-assed
      attempt.
      Signed-off-by: NJens Axboe <axboe@fb.com>
      f27b087b
  10. 19 5月, 2014 3 次提交
  11. 22 4月, 2014 1 次提交
  12. 21 4月, 2014 2 次提交
  13. 16 4月, 2014 1 次提交
    • J
      block: remove struct request buffer member · b4f42e28
      Jens Axboe 提交于
      This was used in the olden days, back when onions were proper
      yellow. Basically it mapped to the current buffer to be
      transferred. With highmem being added more than a decade ago,
      most drivers map pages out of a bio, and rq->buffer isn't
      pointing at anything valid.
      
      Convert old style drivers to just use bio_data().
      
      For the discard payload use case, just reference the page
      in the bio.
      Signed-off-by: NJens Axboe <axboe@fb.com>
      b4f42e28
  14. 10 4月, 2014 2 次提交
  15. 16 3月, 2014 3 次提交