readahead: split ondemand readahead interface into two functions
Split ondemand readahead interface into two functions. I think this makes it a little clearer for non-readahead experts (like Rusty). Internally they both call ondemand_readahead(), but the page argument is changed to an obvious boolean flag. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Fengguang Wu <wfg@mail.ustc.edu.cn> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
committed by
Linus Torvalds
parent
fe3cba17c4
commit
cf914a7d65
@ -1138,12 +1138,20 @@ int do_page_cache_readahead(struct address_space *mapping, struct file *filp,
|
||||
pgoff_t offset, unsigned long nr_to_read);
|
||||
int force_page_cache_readahead(struct address_space *mapping, struct file *filp,
|
||||
pgoff_t offset, unsigned long nr_to_read);
|
||||
unsigned long page_cache_readahead_ondemand(struct address_space *mapping,
|
||||
struct file_ra_state *ra,
|
||||
struct file *filp,
|
||||
struct page *page,
|
||||
pgoff_t offset,
|
||||
unsigned long size);
|
||||
|
||||
void page_cache_sync_readahead(struct address_space *mapping,
|
||||
struct file_ra_state *ra,
|
||||
struct file *filp,
|
||||
pgoff_t offset,
|
||||
unsigned long size);
|
||||
|
||||
void page_cache_async_readahead(struct address_space *mapping,
|
||||
struct file_ra_state *ra,
|
||||
struct file *filp,
|
||||
struct page *pg,
|
||||
pgoff_t offset,
|
||||
unsigned long size);
|
||||
|
||||
unsigned long max_sane_readahead(unsigned long nr);
|
||||
|
||||
/* Do stack extension */
|
||||
|
Reference in New Issue
Block a user