Skip to contentSkip to conversation

ext4: Fix lazyinit hang after removing request

PATCH Applied Lukas Czerner 2 participants 2 messages Oct 29, 2010 – Nov 2, 2010 ext4 file system

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ext4: Fix lazyinit hang after removing request

When the request has been removed from the list and no other request has been issued, we will end up with next wakeup scheduled to MAX_JIFFY_OFFSET which is bad. So check for that.

---
 fs/ext4/super.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
fs/ext4/super.c +2 -1
index 0348ce0..29c3078 100644
@@ -2740,7 +2740,8 @@ cont_thread:
 		if (freezing(current))
 			refrigerator();
 
-		if (time_after_eq(jiffies, next_wakeup)) {
+		if ((time_after_eq(jiffies, next_wakeup)) ||
+		    (MAX_JIFFY_OFFSET == next_wakeup)) {
 			cond_resched();
 			continue;
 		}
Signature · 1 line
1.7.2.3
maintainer Applied
#1 lore raw
Quoted 5 lines · Lukas Czerner

When the request has been removed from the list and no other request has been issued, we will end up with next wakeup scheduled to MAX_JIFFY_OFFSET which is bad. So check for that.

Queued for pushing to Linus for 2.6.27-rc2, thanks.

- Ted