]> Git Repo - linux.git/commit
mm: fs: invalidate BH LRU during page migration
authorMinchan Kim <[email protected]>
Wed, 5 May 2021 01:37:00 +0000 (18:37 -0700)
committerLinus Torvalds <[email protected]>
Wed, 5 May 2021 18:27:24 +0000 (11:27 -0700)
commit8cc621d2f45ddd3dc664024a647ee7adf48d79a5
tree5631d2a5224949098bc2d928f673e6baa1c7e3e6
parent361a2a229fa31ab7f2b236b5946e434964d00762
mm: fs: invalidate BH LRU during page migration

Pages containing buffer_heads that are in one of the per-CPU buffer_head
LRU caches will be pinned and thus cannot be migrated.  This can prevent
CMA allocations from succeeding, which are often used on platforms with
co-processors (such as a DSP) that can only use physically contiguous
memory.  It can also prevent memory hot-unplugging from succeeding,
which involves migrating at least MIN_MEMORY_BLOCK_SIZE bytes of memory,
which ranges from 8 MiB to 1 GiB based on the architecture in use.

Correspondingly, invalidate the BH LRU caches before a migration starts
and stop any buffer_head from being cached in the LRU caches, until
migration has finished.

Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Minchan Kim <[email protected]>
Reported-by: Chris Goldsworthy <[email protected]>
Reported-by: Laura Abbott <[email protected]>
Tested-by: Oliver Sang <[email protected]>
Cc: David Hildenbrand <[email protected]>
Cc: John Dias <[email protected]>
Cc: Matthew Wilcox <[email protected]>
Cc: Michal Hocko <[email protected]>
Cc: Suren Baghdasaryan <[email protected]>
Cc: Vlastimil Babka <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
fs/buffer.c
include/linux/buffer_head.h
mm/swap.c
This page took 0.060102 seconds and 4 git commands to generate.