2022-09-10 22:56:21

by Thomas Gleixner

[permalink] [raw]
Subject: [patch RFC 05/29] printk: Mark __printk percpu data ready __ro_after_init

This variable cannot change post boot.

Signed-off-by: Thomas Gleixner <[email protected]>
---
kernel/printk/printk.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
@@ -430,7 +430,7 @@ static struct printk_ringbuffer *prb = &
* per_cpu_areas are initialised. This variable is set to true when
* it's safe to access per-CPU data.
*/
-static bool __printk_percpu_data_ready __read_mostly;
+static bool __printk_percpu_data_ready __ro_after_init;

bool printk_percpu_data_ready(void)
{


2022-09-14 12:27:45

by Sergey Senozhatsky

[permalink] [raw]
Subject: Re: [patch RFC 05/29] printk: Mark __printk percpu data ready __ro_after_init

On (22/09/11 00:27), Thomas Gleixner wrote:
>
> This variable cannot change post boot.
>
> Signed-off-by: Thomas Gleixner <[email protected]>

Reviewed-by: Sergey Senozhatsky <[email protected]>