Skip to content

Commit

Permalink
ieee1394: fix another deadlock in nodemgr
Browse files Browse the repository at this point in the history
A "modprobe ohci1394; sleep 1.5; modprobe -r ohci1394" could get stuck
in uninterruptible state, especially if an external node was connected.
http://bugzilla.kernel.org/show_bug.cgi?id=7792

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
  • Loading branch information
Stefan Richter committed Feb 17, 2007
1 parent 3dc5ea9 commit a65421e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/ieee1394/nodemgr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1681,7 +1681,8 @@ static int nodemgr_host_thread(void *__hi)
for (;;) {
/* Sleep until next bus reset */
set_current_state(TASK_INTERRUPTIBLE);
if (get_hpsb_generation(host) == generation)
if (get_hpsb_generation(host) == generation &&
!kthread_should_stop())
schedule();
__set_current_state(TASK_RUNNING);

Expand Down

0 comments on commit a65421e

Please sign in to comment.