kfence: Defer the assignment of the local variable addr
authorEnze Li <lienze@kylinos.cn>
Wed, 6 Sep 2023 14:53:55 +0000 (22:53 +0800)
committerHuacai Chen <chenhuacai@loongson.cn>
Wed, 6 Sep 2023 14:53:55 +0000 (22:53 +0800)
commitec9fee79d48f2f05cb1b95dc901071aa3670f228
treeef1c5e560df1c19a1b20445c227ce87a40ae2e77
parent2363088eba2ecccfb643725e4864af73c4226a04
kfence: Defer the assignment of the local variable addr

The LoongArch architecture is different from other architectures. It
needs to update __kfence_pool during arch_kfence_init_pool().

This patch modifies the assignment location of the local variable addr
in the kfence_init_pool() function to support the case of updating
__kfence_pool in arch_kfence_init_pool().

Acked-by: Marco Elver <elver@google.com>
Signed-off-by: Enze Li <lienze@kylinos.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
mm/kfence/core.c