Commit df87bdf6 authored by Huacai Chen's avatar Huacai Chen Committed by Hongchen Zhang
Browse files

LoongArch: Set _PAGE_DIRTY only if _PAGE_MODIFIED is set in {pmd,pte}_mkwrite()

mainline inclusion
from mainline-v6.1-rc7
commit 54e6cd42
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7362E
CVE: NA

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/arch/loongarch?id=54e6cd42a183b602e3627ad3aaeeed44f7443e67



--------------------------------

Set _PAGE_DIRTY only if _PAGE_MODIFIED is set in {pmd,pte}_mkwrite().
Otherwise, _PAGE_DIRTY silences the TLB modify exception and make us
have no chance to mark a pmd/pte dirty (_PAGE_MODIFIED) for software.

Reviewed-by: default avatarGuo Ren <guoren@kernel.org>
Signed-off-by: default avatarHuacai Chen <chenhuacai@loongson.cn>
Change-Id: I05f95f28b6c2a18c44b41f253a2f4cbb987521b9
parent 1267d8f9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment