1. 23 2月, 2009 1 次提交
  2. 19 2月, 2009 2 次提交
  3. 18 2月, 2009 2 次提交
  4. 12 2月, 2009 1 次提交
    • P
      nbd: fix I/O hang on disconnected nbds · 4d48a542
      Paul Clements 提交于
      Fix a problem that causes I/O to a disconnected (or partially initialized)
      nbd device to hang indefinitely.  To reproduce:
      
      # ioctl NBD_SET_SIZE_BLOCKS /dev/nbd23 514048
      # dd if=/dev/nbd23 of=/dev/null bs=4096 count=1
      
      ...hangs...
      
      This can also occur when an nbd device loses its nbd-client/server
      connection.  Although we clear the queue of any outstanding I/Os after the
      client/server connection fails, any additional I/Os that get queued later
      will hang.
      
      This bug may also be the problem reported in this bug report:
      http://bugzilla.kernel.org/show_bug.cgi?id=12277
      
      Testing would need to be performed to determine if the two issues are the
      same.
      
      This problem was introduced by the new request handling thread code ("NBD:
      allow nbd to be used locally", 3/2008), which entered into mainline around
      2.6.25.
      
      The fix, which is fairly simple, is to restore the check for lo->sock
      being NULL in do_nbd_request.  This causes I/O to an uninitialized nbd to
      immediately fail with an I/O error, as it did prior to the introduction of
      this bug.
      Signed-off-by: NPaul Clements <paul.clements@steeleye.com>
      Reported-by: NJon Nelson <jnelson-kernel-bugzilla@jamponi.net>
      Acked-by: NPavel Machek <pavel@ucw.cz>
      Cc: <stable@kernel.org>		[2.6.26.x, 2.6.27.x, 2.6.28.x]
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      4d48a542
  5. 16 1月, 2009 2 次提交
  6. 13 1月, 2009 1 次提交
    • A
      m68k: amiflop - Get rid of sleep_on calls · 6d0be946
      Andreas Bombe 提交于
      Apart from sleep_on() calls that could be easily converted to
      wait_event() and completion calls amiflop also used a flag in ms_delay()
      and ms_isr() as a custom mutex for ms_delay() without a need for
      explicit unlocking.  I converted that to a standard mutex.
      
      The replacement for the unconditional sleep_on() in fd_motor_on() is a
      complete_all() together with a INIT_COMPLETION() before the mod_timer()
      call.  It appears to me that fd_motor_on() might be called concurrently
      and fd_select() does not guarantee mutual exclusivity in the case the
      same drive gets selected again.
      Signed-off-by: NAndreas Bombe <aeb@debian.org>
      Acked-by: NJörg Dorchain <joerg@dorchain.net>
      Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      6d0be946
  7. 10 1月, 2009 1 次提交
  8. 08 1月, 2009 1 次提交
    • A
      USB: change interface to usb_lock_device_for_reset() · 011b15df
      Alan Stern 提交于
      This patch (as1161) changes the interface to
      usb_lock_device_for_reset().  The existing interface is apparently not
      very clear, judging from the fact that several of its callers don't
      use it correctly.  The new interface always returns 0 for success and
      it always requires the caller to unlock the device afterward.
      
      The new routine will not return immediately if it is called while the
      driver's probe method is running.  Instead it will wait until the
      probe is over and the device has been unlocked.  This shouldn't cause
      any problems; I don't know of any cases where drivers call
      usb_lock_device_for_reset() during probe.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Cc: Pete Zaitcev <zaitcev@redhat.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      011b15df
  9. 07 1月, 2009 1 次提交
  10. 30 12月, 2008 3 次提交
  11. 29 12月, 2008 8 次提交
  12. 19 12月, 2008 1 次提交
  13. 11 12月, 2008 1 次提交
  14. 04 12月, 2008 1 次提交
  15. 25 11月, 2008 1 次提交
  16. 20 11月, 2008 1 次提交
    • R
      cciss: fix DEBUG printk formats · 9f92f471
      Randy Dunlap 提交于
      Fix printk format warnings when CCISS_DEBUG is defined.
      
      drivers/block/cciss.c:2856: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'
      drivers/block/cciss.c:3205: warning: format '%x' expects type 'unsigned int', but argument 2 has type 'long unsigned int'
      drivers/block/cciss.c:3236: warning: format '%x' expects type 'unsigned int', but argument 2 has type '__u64'
      drivers/block/cciss.c:3246: warning: format '%x' expects type 'unsigned int', but argument 2 has type '__u64'
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Cc: Mike Miller <mike.miller@hp.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      9f92f471
  17. 18 11月, 2008 1 次提交
  18. 15 11月, 2008 3 次提交
  19. 14 11月, 2008 2 次提交
    • D
      CRED: Wrap task credential accesses in the block loopback driver · b0fafa81
      David Howells 提交于
      Wrap access to task credentials so that they can be separated more easily from
      the task_struct during the introduction of COW creds.
      
      Change most current->(|e|s|fs)[ug]id to current_(|e|s|fs)[ug]id().
      
      Change some task->e?[ug]id to task_e?[ug]id().  In some places it makes more
      sense to use RCU directly rather than a convenient wrapper; these will be
      addressed by later patches.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Reviewed-by: NJames Morris <jmorris@namei.org>
      Acked-by: NSerge Hallyn <serue@us.ibm.com>
      Cc: Jens Axboe <axboe@kernel.dk>
      Signed-off-by: NJames Morris <jmorris@namei.org>
      b0fafa81
    • P
      ub: stub pre_reset and post_reset to fix oops · d73b7aff
      Pete Zaitcev 提交于
      Due to recent changes to usb_reset_device, the following hang occurs:
      
      events/0      D 0000000000000000     0     6      2
       ffff880037477cc0 0000000000000046 ffff880037477c50 ffffffff80237434
       ffffffff80574c80 00000001000a015c 0000000000000286 ffff8800374757d0
       ffff88002a31c860 ffff880037475a00 0000000036779140 ffff880037475a00
      Call Trace:
       [<ffffffff80237434>] try_to_del_timer_sync+0x52/0x5b
       [<ffffffff8026f86c>] dma_pool_free+0x1a7/0x1ec
       [<ffffffffa02a928a>] ub_disconnect+0x8e/0x1ad [ub]
       [<ffffffff802407c9>] autoremove_wake_function+0x0/0x2e
       [<ffffffff80378959>] usb_unbind_interface+0x5c/0xb7
       [<ffffffff8036ab70>] __device_release_driver+0x95/0xbd
       [<ffffffff8036ac70>] device_release_driver+0x21/0x2d
       [<ffffffff803789f8>] usb_driver_release_interface+0x44/0x83
       [<ffffffff80378ab9>] usb_forced_unbind_intf+0x17/0x1d
       [<ffffffff80371ba4>] usb_reset_device+0x7d/0x114
       [<ffffffffa02aaffd>] ub_reset_task+0x0/0x293 [ub]
       [<ffffffffa02ab1c1>] ub_reset_task+0x1c4/0x293 [ub]
       [<ffffffff8033dd1e>] flush_to_ldisc+0x0/0x1cd
       [<ffffffffa02aaffd>] ub_reset_task+0x0/0x293 [ub]
       [<ffffffff8023d302>] run_workqueue+0x87/0x114
       [<ffffffff8023d467>] worker_thread+0xd8/0xe7
       [<ffffffff802407c9>] autoremove_wake_function+0x0/0x2e
       [<ffffffff8023d38f>] worker_thread+0x0/0xe7
       [<ffffffff802404c1>] kthread+0x47/0x73
       [<ffffffff8022c8dd>] schedule_tail+0x27/0x60
       [<ffffffff8020c249>] child_rip+0xa/0x11
       [<ffffffff8024047a>] kthread+0x0/0x73
       [<ffffffff8020c23f>] child_rip+0x0/0x11
      
      This is because usb_reset_device now unbinds, and that calls disconnect,
      which in case of ub waits until the reset completes... which deadlocks.
      Worse, this deadlocks keventd and this takes whole box down.
      
      I'm going to fix this properly later, but let's unbreak the driver
      quickly for non-composite devices at least.
      Signed-off-by: NPete Zaitcev <zaitcev@redhat.com>
      Cc: Alan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      d73b7aff
  20. 07 11月, 2008 4 次提交
  21. 31 10月, 2008 1 次提交
  22. 21 10月, 2008 1 次提交