Skip to content
  1. Aug 22, 2006
  2. Aug 21, 2006
  3. Jul 25, 2006
  4. Jul 15, 2006
  5. Jul 06, 2006
  6. Jul 03, 2006
  7. Jun 30, 2006
  8. Jun 28, 2006
  9. Jun 26, 2006
  10. Jun 23, 2006
  11. Jun 21, 2006
  12. Jun 14, 2006
  13. Jun 08, 2006
    • 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>
      bc1c1169
  14. Jun 01, 2006
  15. May 31, 2006
  16. May 23, 2006
  17. May 12, 2006
    • 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>
      1a2acc9e
  18. May 11, 2006
    • 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>
      dac07ec1
  19. May 05, 2006
    • 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>
      56cf6504
Loading