Skip to content

Commit 8500808

Browse files
xhackerustcpalmer-dabbelt
authored andcommitted
riscv: mm: mark noncoherent_supported as __ro_after_init
The noncoherent_supported indicates whether the HW is coherent or not, it won't change after booting, mark it as __ro_after_init. Signed-off-by: Jisheng Zhang <[email protected]> Reviewed-by: Conor Dooley <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Palmer Dabbelt <[email protected]>
1 parent 3b472f8 commit 8500808

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/riscv/mm/dma-noncoherent.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#include <linux/mm.h>
1111
#include <asm/cacheflush.h>
1212

13-
static bool noncoherent_supported;
13+
static bool noncoherent_supported __ro_after_init;
1414

1515
void arch_sync_dma_for_device(phys_addr_t paddr, size_t size,
1616
enum dma_data_direction dir)

0 commit comments

Comments
 (0)