diff options
author | Dave Kleikamp <shaggy@linux.vnet.ibm.com> | 2007-01-18 04:18:35 +0100 |
---|---|---|
committer | Dave Kleikamp <shaggy@linux.vnet.ibm.com> | 2007-01-18 04:18:35 +0100 |
commit | 4aa0d230c2cfc1ac4bcf7c5466f9943cf14233a9 (patch) | |
tree | b873dce6146f4880c6c48ab53c0079566f52a60b /fs/jfs/jfs_lock.h | |
parent | JFS: Add lockdep annotations (diff) | |
download | linux-4aa0d230c2cfc1ac4bcf7c5466f9943cf14233a9.tar.xz linux-4aa0d230c2cfc1ac4bcf7c5466f9943cf14233a9.zip |
JFS: call io_schedule() instead of schedule() to avoid deadlock
The introduction of Jens Axboe's explicit i/o plugging patches introduced a
deadlock in jfs. This was caused by the process initiating I/O not
unplugging the queue before waiting on the commit thread. The commit
thread itself was waiting for that I/O to complete. Calling io_schedule()
rather than schedule() unplugs the I/O queue avoiding the deadlock, and it
appears to be the right function to call in any case.
Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
Diffstat (limited to 'fs/jfs/jfs_lock.h')
-rw-r--r-- | fs/jfs/jfs_lock.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/jfs/jfs_lock.h b/fs/jfs/jfs_lock.h index 7d78e83d7c40..df48ece4b7a3 100644 --- a/fs/jfs/jfs_lock.h +++ b/fs/jfs/jfs_lock.h @@ -42,7 +42,7 @@ do { \ if (cond) \ break; \ unlock_cmd; \ - schedule(); \ + io_schedule(); \ lock_cmd; \ } \ current->state = TASK_RUNNING; \ |