diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2023-02-11 02:34:48 +0300 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2023-02-11 02:34:48 +0300 |
commit | f67d6b26649379f8520abe6a6c7ed335310bf01e (patch) | |
tree | c161fce6517753dcacdcea21804f6e2c90164a33 /include/linux/mm.h | |
parent | 223ec6ab265ead0b319bc2f15d0d1be05078a74b (diff) | |
parent | ce4d9a1ea35ac5429e822c4106cb2859d5c71f3e (diff) | |
download | linux-f67d6b26649379f8520abe6a6c7ed335310bf01e.tar.xz |
Merge branch 'mm-hotfixes-stable' into mm-stable
To pick up depended-upon changes
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r-- | include/linux/mm.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index 4a0695ef969a..9454b7eb055b 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -137,7 +137,7 @@ extern int mmap_rnd_compat_bits __read_mostly; * define their own version of this macro in <asm/pgtable.h> */ #if BITS_PER_LONG == 64 -/* This function must be updated when the size of struct page grows above 80 +/* This function must be updated when the size of struct page grows above 96 * or reduces below 56. The idea that compiler optimizes out switch() * statement, and only leaves move/store instructions. Also the compiler can * combine write statements if they are both assignments and can be reordered, @@ -148,12 +148,18 @@ static inline void __mm_zero_struct_page(struct page *page) { unsigned long *_pp = (void *)page; - /* Check that struct page is either 56, 64, 72, or 80 bytes */ + /* Check that struct page is either 56, 64, 72, 80, 88 or 96 bytes */ BUILD_BUG_ON(sizeof(struct page) & 7); BUILD_BUG_ON(sizeof(struct page) < 56); - BUILD_BUG_ON(sizeof(struct page) > 80); + BUILD_BUG_ON(sizeof(struct page) > 96); switch (sizeof(struct page)) { + case 96: + _pp[11] = 0; + fallthrough; + case 88: + _pp[10] = 0; + fallthrough; case 80: _pp[9] = 0; fallthrough; |