Skip to content
Commit 28ecb609 authored by Nick Piggin's avatar Nick Piggin Committed by Chris Mason
Browse files

Btrfs: use add_to_page_cache_lru, use __page_cache_alloc



Pagecache pages should be allocated with __page_cache_alloc, so they
obey pagecache memory policies.

add_to_page_cache_lru is exported, so it should be used. Benefits over
using a private pagevec: neater code, 128 bytes fewer stack used, percpu
lru ordering is preserved, and finally don't need to flush pagevec
before returning so batching may be shared with other LRU insertions.

Signed-off-by: default avatarNick Piggin <npiggin@suse.de&gt;:>
Signed-off-by: default avatarChris Mason <chris.mason@oracle.com>
parent 0cad8a11
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment