>From 98fecbcb9edf39b4ab6aab8a85342f77665cac4d Mon Sep 17 00:00:00 2001 From: Jan Kara Date: Fri, 8 Jun 2012 17:08:03 +0200 Subject: [PATCH] writeback: Fix lock imbalance in writeback_sb_inodes() Fix bug introduced by 169ebd90. We have to have wb_list_lock locked when restarting writeback loop after having waited for inode writeback. Signed-off-by: Jan Kara --- fs/fs-writeback.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 8d2fb8c..41a3ccf 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c @@ -664,6 +664,7 @@ static long writeback_sb_inodes(struct super_block *sb, /* Wait for I_SYNC. This function drops i_lock... */ inode_sleep_on_writeback(inode); /* Inode may be gone, start again */ + spin_lock(&wb->list_lock); continue; } inode->i_state |= I_SYNC; -- 1.7.1