diff options
author | Jisheng Zhang <jszhang@kernel.org> | 2021-03-30 02:23:54 +0800 |
---|---|---|
committer | Palmer Dabbelt <palmerdabbelt@google.com> | 2021-04-26 08:25:10 -0700 |
commit | 300f62c37d4601e5b7967c6399917dc6880070bc (patch) | |
tree | 53b10298134de2e7faa35d57d269d85cda8ca8e6 /arch/riscv/kernel/sbi.c | |
parent | e6a302248cec96c3af4cbfcedc44b0de8a26ebe0 (diff) | |
download | linux-300f62c37d4601e5b7967c6399917dc6880070bc.tar.gz linux-300f62c37d4601e5b7967c6399917dc6880070bc.tar.bz2 linux-300f62c37d4601e5b7967c6399917dc6880070bc.zip |
riscv: Constify sbi_ipi_ops
Constify the sbi_ipi_ops so that it will be placed in the .rodata
section. This will cause attempts to modify it to fail when strict
page permissions are in place.
Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
Diffstat (limited to 'arch/riscv/kernel/sbi.c')
-rw-r--r-- | arch/riscv/kernel/sbi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/riscv/kernel/sbi.c b/arch/riscv/kernel/sbi.c index a404d648ef79..38f94926f2ee 100644 --- a/arch/riscv/kernel/sbi.c +++ b/arch/riscv/kernel/sbi.c @@ -571,7 +571,7 @@ static void sbi_send_cpumask_ipi(const struct cpumask *target) sbi_send_ipi(cpumask_bits(&hartid_mask)); } -static struct riscv_ipi_ops sbi_ipi_ops = { +static const struct riscv_ipi_ops sbi_ipi_ops = { .ipi_inject = sbi_send_cpumask_ipi }; |