]> www.infradead.org Git - users/hch/configfs.git/commit
LoongArch: Add WriteCombine shadow mapping in KASAN
authorKanglong Wang <wangkanglong@loongson.cn>
Tue, 12 Nov 2024 08:35:39 +0000 (16:35 +0800)
committerHuacai Chen <chenhuacai@loongson.cn>
Tue, 12 Nov 2024 08:35:39 +0000 (16:35 +0800)
commit139d42ca51018c1d43ab5f35829179f060d1ab31
treef11989201d08cd2915c382ccdbfac9bb583ba643
parent227ca9f6f6aeb8aa8f0c10430b955f1fe2aeab91
LoongArch: Add WriteCombine shadow mapping in KASAN

Currently, the kernel couldn't boot when ARCH_IOREMAP, ARCH_WRITECOMBINE
and KASAN are enabled together. Because DMW2 is used by kernel now which
is configured as 0xa000000000000000 for WriteCombine, but KASAN has no
segment mapping for it. This patch fix this issue.

Solution: Add the relevant definitions for WriteCombine (DMW2) in KASAN.

Cc: stable@vger.kernel.org
Fixes: 8e02c3b782ec ("LoongArch: Add writecombine support for DMW-based ioremap()")
Signed-off-by: Kanglong Wang <wangkanglong@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
arch/loongarch/include/asm/kasan.h
arch/loongarch/mm/kasan_init.c