1. 30 Jun, 2006 2 commits
  2. 28 Jun, 2006 2 commits
  3. 26 Jun, 2006 1 commit
  4. 23 Jun, 2006 12 commits
  5. 21 Jun, 2006 2 commits
  6. 14 Jun, 2006 1 commit
  7. 08 Jun, 2006 1 commit
    • Jens Axboe's avatar
      [PATCH] elevator switching race · bc1c1169
      Jens Axboe authored
      There's a race between shutting down one io scheduler and firing up the
      next, in which a new io could enter and cause the io scheduler to be
      invoked with bad or NULL data.
      To fix this, we need to maintain the queue lock for a bit longer.
      Unfortunately we cannot do that, since the elevator init requires to be
      run without the lock held.  This isn't easily fixable, without also
      changing the mempool API.  So split the initialization into two parts,
      and alloc-init operation and an attach operation.  Then we can
      preallocate the io scheduler and related structures, and run the attach
      inside the lock after we detach the old one.
      This patch has survived 30 minutes of 1 second io scheduler switching
      with a very busy io load.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
  8. 01 Jun, 2006 5 commits
  9. 31 May, 2006 1 commit
  10. 23 May, 2006 1 commit
  11. 12 May, 2006 1 commit
    • Linus Torvalds's avatar
      Revert "[BLOCK] Fix oops on removal of SD/MMC card" · 1a2acc9e
      Linus Torvalds authored
      This reverts commit 56cf6504.
      Both Erik Mouw and Andrew Vasquez independently pinpointed this commit
      as causing problems, where the slab cache for a driver is never released
      (most obviously causing problems when immediately re-loading that
      driver, resulting in a "kmem_cache_create: duplicate cache <xyz>"
      message, but it can also cause other trouble).
      James Bottomley dug into it, and reports:
        "OK, here's the scoop.  The problem patch adds a get of driverfs_dev in
         add_disk(), but doesn't put it again until disk_release() (which occurs
         on final put_disk() of the gendisk).
         However, in SCSI, the driverfs_dev is the sdev_gendev.  That means
         there's a reference held on sdev_gendev  until final disk put.
         Unfortunately, we use the driver model driver_remove to trigger
         del_gendisk (which removes the gendisk from visibility and decrements
         the refcount), so we've introduced an unbreakable deadlock in the
         reference counting with this.
         I suggest simply reversing this patch at the moment.  If Russell and
         Jens can tell me what they're trying to do I'll see if there's another
         way to do it."
      so hereby the patch gets reverted, waiting for a better fix.
      Cc: Jens Axboe <axboe@suse.de>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: James Bottomley <James.Bottomley@SteelEye.com>
      Cc: Erik Mouw <erik@harddisk-recovery.com>
      Cc: Andrew Vasquez <andrew.vasquez@qlogic.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
  12. 11 May, 2006 1 commit
    • Jens Axboe's avatar
      [BLOCK] limit request_fn recursion · dac07ec1
      Jens Axboe authored
      Don't recurse back into the driver even if the unplug threshold is met,
      when the driver asks for a requeue. This is both silly from a logical
      point of view (requeues typically happen due to driver/hardware
      shortage), and also dangerous since we could hit an endless request_fn
      -> requeue -> unplug -> request_fn loop and crash on stack overrun.
      Also limit blk_run_queue() to one level of recursion, similar to how
      blk_start_queue() works.
      This patch fixed a real problem with SLES10 and lpfc, and it could hit
      any SCSI lld that returns non-zero from it's ->queuecommand() handler.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
  13. 05 May, 2006 1 commit
    • Russell King's avatar
      [BLOCK] Fix oops on removal of SD/MMC card · 56cf6504
      Russell King authored
      The block layer keeps a reference (driverfs_dev) to the struct
      device associated with the block device, and uses it internally
      for generating uevents in block_uevent.
      Block device uevents include umounting the partition, which can
      occur after the backing device has been removed.
      Unfortunately, this reference is not counted.  This means that
      if the struct device is removed from the device tree, the block
      layers reference will become stale.
      Guard against this by holding a reference to the struct device
      in add_disk(), and only drop the reference when we're releasing
      the gendisk kobject - in other words when we can be sure that no
      further uevents will be generated for this block device.
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      Acked-by: default avatarJens Axboe <axboe@suse.de>
  14. 26 Apr, 2006 1 commit
  15. 21 Apr, 2006 1 commit
  16. 20 Apr, 2006 2 commits
  17. 18 Apr, 2006 3 commits
  18. 13 Apr, 2006 1 commit
    • Christoph Hellwig's avatar
      [SCSI] unify SCSI_IOCTL_SEND_COMMAND implementations · 21b2f0c8
      Christoph Hellwig authored
      We currently have two implementations of this obsolete ioctl, one in
      the block layer and one in the scsi code.  Both of them have drawbacks.
      This patch kills the scsi layer version after updating the block version
      with the missing bits:
       - argument checking
       - use scatterlist I/O
       - set number of retries based on the submitted command
      This is the last user of non-S/G I/O except for the gdth driver, so
      getting this in ASAP and through the scsi tree would be nie to kill
      the non-S/G I/O path.  Jens, what do you think about adding a check
      for non-S/G I/O in the midlayer?
      Thanks to  Or Gerlitz for testing this patch.
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
  19. 02 Apr, 2006 1 commit