Remove get_readahead_bounds(): - ra_max: we already have get_max_readahead() for it - ra_min: is only used by context based readahead, and will be moved there and set to a more reasonable value
Signed-off-by: Fengguang Wu <[EMAIL PROTECTED]> --- mm/readahead.c | 24 ------------------------ 1 file changed, 24 deletions(-) --- linux-2.6.20-rc3-mm1.orig/mm/readahead.c +++ linux-2.6.20-rc3-mm1/mm/readahead.c @@ -780,30 +780,6 @@ out: return nr_pages; } -/* - * ra_min is mainly determined by the size of cache memory. Reasonable? - * - * Table of concrete numbers for 4KB page size: - * inactive + free (MB): 4 8 16 32 64 128 256 512 1024 - * ra_min (KB): 16 16 16 16 20 24 32 48 64 - */ -static inline void get_readahead_bounds(struct file_ra_state *ra, - unsigned long *ra_min, - unsigned long *ra_max) -{ - unsigned long active; - unsigned long inactive; - unsigned long free; - - __get_zone_counts(&active, &inactive, &free, NODE_DATA(numa_node_id())); - - free += inactive; - *ra_max = min(min(ra->ra_pages, 0xFFFFUL), free / 2); - *ra_min = min(min(MIN_RA_PAGES + (free >> 14), - DIV_ROUND_UP(64*1024, PAGE_CACHE_SIZE)), - *ra_max / 8); -} - #endif /* CONFIG_ADAPTIVE_READAHEAD */ /* -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/