xtensa: annotate dtb_start variable as static __initdata
PATCH 1/1 xtensa: annotate dtb_start variable as static __initdata
The 'dtb_start' variable is only used within arch/xtensa/kernel/setup.c. Mark it as 'static'.
It is only used by parse_tag_fdt() and init_arch(), both of which are annotated as __init. Therefore, dtb_start can be annotated as __initdata, so it will discarded after boot.
---
arch/xtensa/kernel/setup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/xtensa/kernel/setup.c +1 -1
@@ -55,7 +55,7 @@ extern int initrd_below_start_ok;#endif #ifdef CONFIG_USE_OF -void *dtb_start = __dtb_start; +static void *dtb_start__initdata = __dtb_start;#endif extern unsigned long loops_per_jiffy;
Signature · 1 line
2.43.0
Quoted 10 lines · Masahiro Yamada
The '
dtb_start' variable is only used withinarch/xtensa/kernel/setup.c. Mark it as 'static'.It is only used by
parse_tag_fdt()andinit_arch(), both of which are annotated as__init. Therefore,dtb_startcan be annotated as__initdata, so it will discarded after boot.Signed-off-by Masahiro Yamada <[email protected]>---
Ping?
Quoted 20 lines
arch/xtensa/kernel/setup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)arch/xtensa/kernel/setup.c +1
-2@@ -55,7 +55,7 @@ extern int initrd_below_start_ok;#endif #ifdef CONFIG_USE_OF -void *dtb_start = __dtb_start; +static void *dtb_start__initdata = __dtb_start;#endif extern unsigned long loops_per_jiffy; --2.43.0
Signature · 2 lines
Best Regards Masahiro Yamada
Max Filippov
maintainerQuoted 6 lines · Masahiro Yamada
Quoted 4 lines · Masahiro Yamada
The '
dtb_start' variable is only used withinarch/xtensa/kernel/setup.c. Mark it as 'static'.
Quoted 8 lines
Quoted 6 lines
It is only used by
parse_tag_fdt()andinit_arch(), both of which are annotated as__init. Therefore,dtb_startcan be annotated as__initdata, so it will discarded after boot.Signed-off-by Masahiro Yamada <[email protected]>---
Ping?
Thanks. Applied to my xtensa tree.
-- Max