From 3b30bbd963ac2606b0377b39c9d148d6eeef7dce Mon Sep 17 00:00:00 2001 From: Steven Pratt Date: Tue, 6 Sep 2005 15:17:06 -0700 Subject: [PATCH] readahead: reset cache_hit earlier We don't reset the cache hit count until after readahead does a successful readahead. This seems to leave a corner case open where we miss in cache, but don't restart the readhead right away. Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- mm/readahead.c | 1 + 1 file changed, 1 insertion(+) (limited to 'mm/readahead.c') diff --git a/mm/readahead.c b/mm/readahead.c index b840e7c6ea74..d0b50034e245 100644 --- a/mm/readahead.c +++ b/mm/readahead.c @@ -540,6 +540,7 @@ void handle_ra_miss(struct address_space *mapping, { ra->flags |= RA_FLAG_MISS; ra->flags &= ~RA_FLAG_INCACHE; + ra->cache_hit = 0; } /* -- cgit v1.2.2