Just in case someone aggressively set a huge readahead size. Cc: Nick Piggin Cc: Linus Torvalds Signed-off-by: Wu Fengguang --- mm/readahead.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- mm.orig/mm/readahead.c +++ mm/mm/readahead.c @@ -382,7 +382,7 @@ ondemand_readahead(struct address_space bool hit_readahead_marker, pgoff_t offset, unsigned long req_size) { - int max = ra->ra_pages; /* max readahead pages */ + unsigned long max = max_sane_readahead(ra->ra_pages); pgoff_t prev_offset; int sequential; -- -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org