lkml.org 
[lkml]   [2011]   [Jul]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 2/3] mm/readahead: Remove file_ra_state from arguments of count_history_pages.
Date
count_history_pages doesn't require readahead state to calculate the offset from history.

Signed-off-by: Raghavendra D Prabhu <rprabhu@wnohang.net>
---
mm/readahead.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/mm/readahead.c b/mm/readahead.c
index 867f9dd..925d3b3 100644
--- a/mm/readahead.c
+++ b/mm/readahead.c
@@ -343,7 +343,6 @@ static unsigned long get_next_ra_size(struct file_ra_state *ra,
* - thrashing threshold in memory tight systems
*/
static pgoff_t count_history_pages(struct address_space *mapping,
- struct file_ra_state *ra,
pgoff_t offset, unsigned long max)
{
pgoff_t head;
@@ -366,7 +365,7 @@ static int try_context_readahead(struct address_space *mapping,
{
pgoff_t size;

- size = count_history_pages(mapping, ra, offset, max);
+ size = count_history_pages(mapping, offset, max);

/*
* no history pages:
--
1.7.6


\
 
 \ /
  Last update: 2011-07-09 21:45    [W:0.053 / U:2.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site