1. 06 11月, 2008 6 次提交
    • T
      block: fix __blkdev_get() for removable devices · 89f97496
      Tejun Heo 提交于
      Commit 0762b8bd moved disk_get_part()
      in front of recursive get on the whole disk, which caused removable
      devices to try disk_get_part() before rescanning after a new media is
      inserted, which might fail legit open attempts or give the old
      partition.
      
      This patch fixes the problem by moving disk_get_part() after
      __blkdev_get() on the whole disk.
      
      This problem was spotted by Borislav Petkov.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Tested-by: NBorislav Petkov <petkovbb@gmail.com>
      Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
      89f97496
    • S
      generic-ipi: fix the smp_mb() placement · 561920a0
      Suresh Siddha 提交于
      smp_mb() is needed (to make the memory operations visible globally) before
      sending the ipi on the sender and the receiver (on Alpha atleast) needs
      smp_read_barrier_depends() in the handler before reading the call_single_queue
      list in a lock-free fashion.
      
      On x86, x2apic mode register accesses for sending IPI's don't have serializing
      semantics. So the need for smp_mb() before sending the IPI becomes more
      critical in x2apic mode.
      
      Remove the unnecessary smp_mb() in csd_flag_wait(), as the presence of that
      smp_mb() doesn't mean anything on the sender, when the ipi receiver is not
      doing any thing special (like memory fence) after clearing the CSD_FLAG_WAIT.
      Signed-off-by: NSuresh Siddha <suresh.b.siddha@intel.com>
      Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
      561920a0
    • M
      blk: move blk_delete_timer call in end_that_request_last · e78042e5
      Mike Anderson 提交于
      Move the calling  blk_delete_timer to later in end_that_request_last to
      address an issue where blkdev_dequeue_request may have add a timer for the
      request.
      Signed-off-by: NMike Anderson <andmike@linux.vnet.ibm.com>
      Acked-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
      e78042e5
    • T
      block: add timer on blkdev_dequeue_request() not elv_next_request() · 2920ebbd
      Tejun Heo 提交于
      Block queue supports two usage models - one where block driver peeks
      at the front of queue using elv_next_request(), processes it and
      finishes it and the other where block driver peeks at the front of
      queue, dequeue the request using blkdev_dequeue_request() and finishes
      it.  The latter is more flexible as it allows the driver to process
      multiple commands concurrently.
      
      These two inconsistent usage models affect the block layer
      implementation confusing.  For some, elv_next_request() is considered
      the issue point while others consider blkdev_dequeue_request() the
      issue point.
      
      Till now the inconsistency mostly affect only accounting, so it didn't
      really break anything seriously; however, with block layer timeout,
      this inconsistency hits hard.  Block layer considers
      elv_next_request() the issue point and adds timer but SCSI layer
      thinks it was just peeking and when the request can't process the
      command right away, it's just left there without further processing.
      This makes the request dangling on the timer list and, when the timer
      goes off, the request which the SCSI layer and below think is still on
      the block queue ends up in the EH queue, causing various problems - EH
      hang (failed count goes over busy count and EH never wakes up),
      WARN_ON() and oopses as low level driver trying to handle the unknown
      command, etc. depending on the timing.
      
      As SCSI midlayer is the only user of block layer timer at the moment,
      moving blk_add_timer() to elv_dequeue_request() fixes the problem;
      however, this two usage models definitely need to be cleaned up in the
      future.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
      2920ebbd
    • J
      bio: define __BIOVEC_PHYS_MERGEABLE · f92131c3
      Jeremy Fitzhardinge 提交于
      Define __BIOVEC_PHYS_MERGEABLE as the default implementation of
      BIOVEC_PHYS_MERGEABLE, so that its available for reuse within an
      arch-specific definition of BIOVEC_PHYS_MERGEABLE.
      Signed-off-by: NJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
      Signed-off-by: NJens Axboe <jens.axboe@oracle.com>
      f92131c3
    • F
      43381785
  2. 05 11月, 2008 3 次提交
  3. 04 11月, 2008 24 次提交
  4. 03 11月, 2008 7 次提交