Skip to content

Commit f5bd5fc

Browse files
MrVandlezcano
authored andcommitted
clocksource/drivers/imx-sysctr: Mark two variable with __ro_after_init
The variables 'sys_ctr_base' and 'cmpcr' are not be updated after init, so mark them as __ro_after_init. Cc: Kees Cook <[email protected]> Signed-off-by: Peng Fan <[email protected]> Reviewed-by: Kees Cook <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Daniel Lezcano <[email protected]>
1 parent a2807f6 commit f5bd5fc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/clocksource/timer-imx-sysctr.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020

2121
#define SYS_CTR_CLK_DIV 0x3
2222

23-
static void __iomem *sys_ctr_base;
24-
static u32 cmpcr;
23+
static void __iomem *sys_ctr_base __ro_after_init;
24+
static u32 cmpcr __ro_after_init;
2525

2626
static void sysctr_timer_enable(bool enable)
2727
{

0 commit comments

Comments
 (0)