ANDROID: mm: add config for default readahead size
Change the VM_MAX_READAHED value from the default 128KB to a configurable value. This will allow the readahead window to grow to a maximum size bigger than 128KB, which greatly benefits to sequential read throughput and thus boot performance. Bug: 62413151 Test: boot walleye 100ms faster Change-Id: Iad448cf1198056de46654dcb409466802b3b908d Signed-off-by: Wei Wang <wvw@google.com>
This commit is contained in:
parent
4d8bcbb48b
commit
c2403431f7
2 changed files with 9 additions and 1 deletions
|
@ -2009,7 +2009,7 @@ int write_one_page(struct page *page, int wait);
|
||||||
void task_dirty_inc(struct task_struct *tsk);
|
void task_dirty_inc(struct task_struct *tsk);
|
||||||
|
|
||||||
/* readahead.c */
|
/* readahead.c */
|
||||||
#define VM_MAX_READAHEAD 512 /* kbytes */
|
#define VM_MAX_READAHEAD CONFIG_VM_MAX_READAHEAD /* kbytes */
|
||||||
#define VM_MIN_READAHEAD 16 /* kbytes (includes current page) */
|
#define VM_MIN_READAHEAD 16 /* kbytes (includes current page) */
|
||||||
|
|
||||||
int force_page_cache_readahead(struct address_space *mapping, struct file *filp,
|
int force_page_cache_readahead(struct address_space *mapping, struct file *filp,
|
||||||
|
|
|
@ -743,3 +743,11 @@ config PROCESS_RECLAIM
|
||||||
(addr, addr + size-bytes) of the process.
|
(addr, addr + size-bytes) of the process.
|
||||||
|
|
||||||
Any other vaule is ignored.
|
Any other vaule is ignored.
|
||||||
|
|
||||||
|
config VM_MAX_READAHEAD
|
||||||
|
int "default max readahead window size"
|
||||||
|
default 128
|
||||||
|
help
|
||||||
|
This sets the VM_MAX_READAHEAD value to allow the readahead window
|
||||||
|
to grow to a maximum size of configured. This will benefit sequential
|
||||||
|
read throughput and thus early boot performance.
|
||||||
|
|
Loading…
Add table
Reference in a new issue