]> git.hungrycats.org Git - linux/commitdiff
riscv: Move create_tmp_mapping() to init sections
authorAlexandre Ghiti <alexghiti@rivosinc.com>
Tue, 4 Jul 2023 07:43:57 +0000 (09:43 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 13 Sep 2023 07:48:38 +0000 (09:48 +0200)
commit 9bdd924803787ceeb10f1ea399e91d75fb05d3a7 upstream.

This function is only used at boot time so mark it as __init.

Fixes: 96f9d4daf745 ("riscv: Rework kasan population functions")
Signed-off-by: Alexandre Ghiti <alexghiti@rivosinc.com>
Link: https://lore.kernel.org/r/20230704074357.233982-2-alexghiti@rivosinc.com
Cc: stable@vger.kernel.org
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/riscv/mm/kasan_init.c

index a01bc15dce2441d82b1508d16fb827364183fe29..bd64be7432b4fa9eb2e60430d00bb60102a4ec9a 100644 (file)
@@ -438,7 +438,7 @@ static void __init kasan_shallow_populate(void *start, void *end)
        kasan_shallow_populate_pgd(vaddr, vend);
 }
 
-static void create_tmp_mapping(void)
+static void __init create_tmp_mapping(void)
 {
        void *ptr;
        p4d_t *base_p4d;