diff mbox series

[v2] MIPS: generic: Use __initconst for const init data

Message ID 1570551309-21021-1-git-send-email-yangtiezhu@loongson.cn (mailing list archive)
State Mainlined
Commit a14bf1dc494aa5126e4f23ebd9fa04991133814e
Delegated to: Paul Burton
Headers show
Series [v2] MIPS: generic: Use __initconst for const init data | expand

Commit Message

Tiezhu Yang Oct. 8, 2019, 4:15 p.m. UTC
Fix the following checkpatch errors:

$ ./scripts/checkpatch.pl --no-tree -f arch/mips/generic/init.c
ERROR: Use of const init definition must use __initconst
#23: FILE: arch/mips/generic/init.c:23:
+static __initdata const void *fdt;

ERROR: Use of const init definition must use __initconst
#24: FILE: arch/mips/generic/init.c:24:
+static __initdata const struct mips_machine *mach;

ERROR: Use of const init definition must use __initconst
#25: FILE: arch/mips/generic/init.c:25:
+static __initdata const void *mach_match_data;

Fixes: eed0eabd12ef ("MIPS: generic: Introduce generic DT-based board support")
Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
---

v2: update the commit message and use the 'Fixes:' tag

 arch/mips/generic/init.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Paul Burton Oct. 8, 2019, 5:55 p.m. UTC | #1
Hello,

Tiezhu Yang wrote:
> Fix the following checkpatch errors:
> 
> $ ./scripts/checkpatch.pl --no-tree -f arch/mips/generic/init.c
> ERROR: Use of const init definition must use __initconst
> #23: FILE: arch/mips/generic/init.c:23:
> +static __initdata const void *fdt;
> 
> ERROR: Use of const init definition must use __initconst
> #24: FILE: arch/mips/generic/init.c:24:
> +static __initdata const struct mips_machine *mach;
> 
> ERROR: Use of const init definition must use __initconst
> #25: FILE: arch/mips/generic/init.c:25:
> +static __initdata const void *mach_match_data;

Applied to mips-next.

> commit a14bf1dc494a
> https://git.kernel.org/mips/c/a14bf1dc494a
> 
> Fixes: eed0eabd12ef ("MIPS: generic: Introduce generic DT-based board support")
> Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
> Signed-off-by: Paul Burton <paul.burton@mips.com>

Thanks,
    Paul

[ This message was auto-generated; if you believe anything is incorrect
  then please email paul.burton@mips.com to report it. ]
diff mbox series

Patch

diff --git a/arch/mips/generic/init.c b/arch/mips/generic/init.c
index d5b8c47..1de215b 100644
--- a/arch/mips/generic/init.c
+++ b/arch/mips/generic/init.c
@@ -20,9 +20,9 @@ 
 #include <asm/smp-ops.h>
 #include <asm/time.h>
 
-static __initdata const void *fdt;
-static __initdata const struct mips_machine *mach;
-static __initdata const void *mach_match_data;
+static __initconst const void *fdt;
+static __initconst const struct mips_machine *mach;
+static __initconst const void *mach_match_data;
 
 void __init prom_init(void)
 {