]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: add PMD table accounting into MIPS'pmd_alloc_one
authorHuang Pei <huangpei@loongson.cn>
Fri, 11 Jun 2021 07:09:46 +0000 (15:09 +0800)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Mon, 21 Jun 2021 09:27:30 +0000 (11:27 +0200)
commitf157f1d54f5753142b72c715b9dee22632156f3f
tree596f4949f98a8f5e76c575d932590e4f2fec7ddb
parent0e3bd01bbc0b5aea1d6d320b4bcd1f64c58363dd
MIPS: add PMD table accounting into MIPS'pmd_alloc_one

This fixes Page Table accounting bug.

MIPS is the ONLY arch just defining __HAVE_ARCH_PMD_ALLOC_ONE alone.
Since commit 86e94cbba5d169 (mm: account PMD tables like PTE tables),
"pmd_free" in asm-generic with PMD table accounting and "pmd_alloc_one"
in MIPS without PMD table accounting causes PageTable accounting number
negative, which read by global_zone_page_state(), always returns 0.

Signed-off-by: Huang Pei <huangpei@loongson.cn>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/include/asm/pgalloc.h