diff options
author | Hyesoo Yu <hyesoo.yu@samsung.com> | 2023-10-23 10:32:16 +0200 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2023-10-26 01:47:14 +0200 |
commit | 76f26535d1446373d4735a252ea4247c39d64ba6 (patch) | |
tree | 690e6e660c88d34f6a52be642e71800ee6b5bf16 /mm/list_lru.c | |
parent | mm: fix multiple typos in multiple files (diff) | |
download | linux-76f26535d1446373d4735a252ea4247c39d64ba6.tar.xz linux-76f26535d1446373d4735a252ea4247c39d64ba6.zip |
mm: page_alloc: check the order of compound page even when the order is zero
For compound pages, the head sets the PG_head flag and the tail sets the
compound_head to indicate the head page. If a user allocates a compound
page and frees it with a different order, the compound page information
will not be properly initialized. To detect this problem,
compound_order(page) and the order argument are compared, but this is not
checked when the order argument is zero. That error should be checked
regardless of the order.
Link: https://lkml.kernel.org/r/20231023083217.1866451-1-hyesoo.yu@samsung.com
Signed-off-by: Hyesoo Yu <hyesoo.yu@samsung.com>
Reviewed-by: Vishal Moola (Oracle) <vishal.moola@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm/list_lru.c')
0 files changed, 0 insertions, 0 deletions