diff options
author | Samuel Holland <samuel@sholland.org> | 2022-05-29 13:32:11 -0500 |
---|---|---|
committer | Anup Patel <anup@brainfault.org> | 2022-05-30 10:32:35 +0530 |
commit | fab0379bb60d6e177018b53f07718b69ba34948d (patch) | |
tree | 780d1bdbb8ea444a227e7a3b9c1972014b92404b /lib/utils/timer | |
parent | f067bb84cf2dd6493ff3fa49294d3ec80481ad75 (diff) | |
download | opensbi-fab0379bb60d6e177018b53f07718b69ba34948d.zip opensbi-fab0379bb60d6e177018b53f07718b69ba34948d.tar.gz opensbi-fab0379bb60d6e177018b53f07718b69ba34948d.tar.bz2 |
lib: utils/fdt: Require match data to be const
Match data stores hardware attributes which do not change at runtime, so
it does not need to be mutable. Make it const.
Reviewed-by: Guo Ren <guoren@kernel.org>
Reviewed-by: Xiang W <wxjstz@126.com>
Reviewed-by: Anup Patel <anup@brainfault.org>
Signed-off-by: Samuel Holland <samuel@sholland.org>
Diffstat (limited to 'lib/utils/timer')
-rw-r--r-- | lib/utils/timer/fdt_timer_mtimer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/utils/timer/fdt_timer_mtimer.c b/lib/utils/timer/fdt_timer_mtimer.c index 1ad8508..82239d5 100644 --- a/lib/utils/timer/fdt_timer_mtimer.c +++ b/lib/utils/timer/fdt_timer_mtimer.c @@ -107,7 +107,7 @@ static int timer_mtimer_cold_init(void *fdt, int nodeoff, return 0; } -static unsigned long clint_offset = CLINT_MTIMER_OFFSET; +static const unsigned long clint_offset = CLINT_MTIMER_OFFSET; static const struct fdt_match timer_mtimer_match[] = { { .compatible = "riscv,clint0", .data = &clint_offset }, |