]> git.dujemihanovic.xyz Git - linux.git/commit
LoongArch: Introduce hardware page table walker
authorHuacai Chen <chenhuacai@loongson.cn>
Thu, 29 Jun 2023 12:58:44 +0000 (20:58 +0800)
committerHuacai Chen <chenhuacai@loongson.cn>
Thu, 29 Jun 2023 12:58:44 +0000 (20:58 +0800)
commit01158487af60cd3915e8c31924144caf29cb0767
tree01bdd88063128e646a6fdc394a9c2d8c7a138316
parente031a5f3f1eddb961a6ded8a21ab8189d8760860
LoongArch: Introduce hardware page table walker

Loongson-3A6000 and newer processors have hardware page table walker
(PTW) support. PTW can handle all fastpaths of TLBI/TLBL/TLBS/TLBM
exceptions by hardware, software only need to handle slowpaths (page
faults).

BTW, PTW doesn't append _PAGE_MODIFIED for page table entries, so we
change pmd_dirty() and pte_dirty() to also check _PAGE_DIRTY for the
"dirty" attribute.

Signed-off-by: Liang Gao <gaoliang@loongson.cn>
Signed-off-by: Jun Yi <yijun@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
arch/loongarch/include/asm/cpu-features.h
arch/loongarch/include/asm/cpu.h
arch/loongarch/include/asm/loongarch.h
arch/loongarch/include/asm/pgtable.h
arch/loongarch/include/asm/tlb.h
arch/loongarch/include/uapi/asm/hwcap.h
arch/loongarch/kernel/cpu-probe.c
arch/loongarch/kernel/proc.c
arch/loongarch/mm/tlb.c
arch/loongarch/mm/tlbex.S