* [PATCH 1/7] checkpatch.pl: Make common.h check boarder
@ 2023-10-12 23:03 Tom Rini
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
` (6 more replies)
0 siblings, 7 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Simon Glass
At this point in time we should not add common.h to any new files, so
make checkpatch.pl complain.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Simon Glass <sjg@chromium.org>
This causes a bunch of patman tests, for checkpatch, to now fail and I
don't really understand why, at all. And that was before I added a test
for the new error, which I had hoped would clear up the problem.
---
scripts/checkpatch.pl | 8 +++++++-
tools/patman/test_checkpatch.py | 7 ++++++-
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 488d73a0ed77..c3314da8a3c7 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2636,12 +2636,18 @@ sub u_boot_line {
"All CONFIG symbols are managed by Kconfig\n" . $herecurr);
}
- # Don't put common.h and dm.h in header files
+ # Don't put dm.h in header files
if ($realfile =~ /\.h$/ && $rawline =~ /^\+#include\s*<(common|dm)\.h>*/) {
ERROR("BARRED_INCLUDE_IN_HDR",
"Avoid including common.h and dm.h in header files\n" . $herecurr);
}
+ # Don't add common.h to files
+ if ($rawline =~ /^\+#include\s*<(common|dm)\.h>*/) {
+ ERROR("BARRED_INCLUDE_COMMON_H",
+ "Do not add common.h to files\n" . $herecurr);
+ }
+
# Do not disable fdt / initrd relocation
if ($rawline =~ /^\+.*(fdt|initrd)_high=0xffffffff/) {
ERROR("DISABLE_FDT_OR_INITRD_RELOC",
diff --git a/tools/patman/test_checkpatch.py b/tools/patman/test_checkpatch.py
index a8bb364e42b2..187736d617d5 100644
--- a/tools/patman/test_checkpatch.py
+++ b/tools/patman/test_checkpatch.py
@@ -401,10 +401,15 @@ index 0000000..2234c87
def test_barred_include_in_hdr(self):
"""Test for using a barred include in a header file"""
pm = PatchMaker()
- #pm.add_line('include/myfile.h', '#include <common.h>')
pm.add_line('include/myfile.h', '#include <dm.h>')
self.check_single_message(pm, 'BARRED_INCLUDE_IN_HDR', 'error')
+ def test_barred_include_common_h(self):
+ """Test for adding common.h to a file"""
+ pm = PatchMaker()
+ pm.add_line('include/myfile.h', '#include <common.h>')
+ self.check_single_message(pm, 'BARRED_INCLUDE_COMMON_H', 'error')
+
def test_config_is_enabled_config(self):
"""Test for accidental CONFIG_IS_ENABLED(CONFIG_*) calls"""
pm = PatchMaker()
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 2/7] include: Add <linux/types.h> in a few places
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
2023-10-13 15:14 ` Simon Glass
2023-10-24 23:15 ` Tom Rini
2023-10-12 23:03 ` [PATCH 3/7] arc: Remove common.h usage Tom Rini
` (5 subsequent siblings)
6 siblings, 2 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Simon Glass
These files references a number of types that are defined in
<linux/types.h> (and so forth), so include it here rather than rely on
indirect inclusion.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Simon Glass <sjg@chromium.org>
---
include/bootstage.h | 1 +
include/cache.h | 2 ++
include/cpu.h | 2 ++
3 files changed, 5 insertions(+)
diff --git a/include/bootstage.h b/include/bootstage.h
index f9376c320c96..affb0e5c6a6a 100644
--- a/include/bootstage.h
+++ b/include/bootstage.h
@@ -11,6 +11,7 @@
#ifndef _BOOTSTAGE_H
#define _BOOTSTAGE_H
+#include <linux/types.h>
#include <linux/kconfig.h>
/* Flags for each bootstage record */
diff --git a/include/cache.h b/include/cache.h
index b12fec259156..296ae3c8b48e 100644
--- a/include/cache.h
+++ b/include/cache.h
@@ -6,6 +6,8 @@
#ifndef __CACHE_H
#define __CACHE_H
+#include <linux/types.h>
+
struct udevice;
/*
diff --git a/include/cpu.h b/include/cpu.h
index be02a1671298..2077ff30634b 100644
--- a/include/cpu.h
+++ b/include/cpu.h
@@ -7,6 +7,8 @@
#ifndef __CPU_H
#define __CPU_H
+#include <linux/types.h>
+
struct udevice;
/**
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 3/7] arc: Remove common.h usage
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
2023-10-13 9:21 ` Alexey Brodkin
2023-10-24 23:15 ` Tom Rini
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
` (4 subsequent siblings)
6 siblings, 2 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Alexey Brodkin, Eugeniy Paltsev, uboot-snps-arc
We can remove common.h from most cases of the code here, and only a few
places need an additional header instead.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Alexey Brodkin <alexey.brodkin@synopsys.com>
Cc: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Cc: uboot-snps-arc@synopsys.com
---
arch/arc/lib/bootm.c | 1 -
arch/arc/lib/cache.c | 1 -
arch/arc/lib/cpu.c | 1 -
arch/arc/lib/init_helpers.c | 1 -
arch/arc/lib/interrupts.c | 2 +-
arch/arc/lib/relocate.c | 1 -
arch/arc/lib/reset.c | 1 -
board/abilis/tb100/tb100.c | 1 -
board/synopsys/axs10x/axs10x.c | 1 -
board/synopsys/emsdp/emsdp.c | 1 -
board/synopsys/hsdk/clk-lib.h | 1 -
board/synopsys/hsdk/env-lib.c | 2 ++
board/synopsys/hsdk/env-lib.h | 1 -
board/synopsys/hsdk/hsdk.c | 1 -
board/synopsys/iot_devkit/iot_devkit.c | 1 -
board/synopsys/nsim/nsim.c | 1 -
16 files changed, 3 insertions(+), 15 deletions(-)
diff --git a/arch/arc/lib/bootm.c b/arch/arc/lib/bootm.c
index 2dd003445f8f..44ec5864a1c6 100644
--- a/arch/arc/lib/bootm.c
+++ b/arch/arc/lib/bootm.c
@@ -3,7 +3,6 @@
* Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <bootstage.h>
#include <env.h>
#include <image.h>
diff --git a/arch/arc/lib/cache.c b/arch/arc/lib/cache.c
index d97a5787424e..22e748868a74 100644
--- a/arch/arc/lib/cache.c
+++ b/arch/arc/lib/cache.c
@@ -4,7 +4,6 @@
*/
#include <config.h>
-#include <common.h>
#include <cpu_func.h>
#include <asm/global_data.h>
#include <linux/bitops.h>
diff --git a/arch/arc/lib/cpu.c b/arch/arc/lib/cpu.c
index 156785796183..803dfd425580 100644
--- a/arch/arc/lib/cpu.c
+++ b/arch/arc/lib/cpu.c
@@ -3,7 +3,6 @@
* Copyright (C) 2013-2014, 2018 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <clock_legacy.h>
#include <init.h>
#include <malloc.h>
diff --git a/arch/arc/lib/init_helpers.c b/arch/arc/lib/init_helpers.c
index 023eae190759..858b388cc0b9 100644
--- a/arch/arc/lib/init_helpers.c
+++ b/arch/arc/lib/init_helpers.c
@@ -5,7 +5,6 @@
#include <init.h>
#include <asm/cache.h>
-#include <common.h>
int init_cache_f_r(void)
{
diff --git a/arch/arc/lib/interrupts.c b/arch/arc/lib/interrupts.c
index db21fbb11428..523b44cb95a4 100644
--- a/arch/arc/lib/interrupts.c
+++ b/arch/arc/lib/interrupts.c
@@ -3,8 +3,8 @@
* Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <irq_func.h>
+#include <vsprintf.h>
#include <asm/arcregs.h>
#include <asm/ptrace.h>
diff --git a/arch/arc/lib/relocate.c b/arch/arc/lib/relocate.c
index fd6f4fbc9304..95b6d5150c78 100644
--- a/arch/arc/lib/relocate.c
+++ b/arch/arc/lib/relocate.c
@@ -3,7 +3,6 @@
* Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <elf.h>
#include <log.h>
#include <asm/sections.h>
diff --git a/arch/arc/lib/reset.c b/arch/arc/lib/reset.c
index b8589d0f0a47..fa60fa963381 100644
--- a/arch/arc/lib/reset.c
+++ b/arch/arc/lib/reset.c
@@ -4,7 +4,6 @@
*/
#include <command.h>
-#include <common.h>
#include <cpu_func.h>
__weak void reset_cpu(void)
diff --git a/board/abilis/tb100/tb100.c b/board/abilis/tb100/tb100.c
index 89e73225a7df..3dc9e14ef8c0 100644
--- a/board/abilis/tb100/tb100.c
+++ b/board/abilis/tb100/tb100.c
@@ -3,7 +3,6 @@
* (C) Copyright 2014 Pierrick Hascoet, Abilis Systems
*/
-#include <common.h>
#include <cpu_func.h>
#include <net.h>
#include <netdev.h>
diff --git a/board/synopsys/axs10x/axs10x.c b/board/synopsys/axs10x/axs10x.c
index 75e4d037623e..95297a18357f 100644
--- a/board/synopsys/axs10x/axs10x.c
+++ b/board/synopsys/axs10x/axs10x.c
@@ -3,7 +3,6 @@
* Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <cpu_func.h>
#include <dwmmc.h>
#include <init.h>
diff --git a/board/synopsys/emsdp/emsdp.c b/board/synopsys/emsdp/emsdp.c
index a3cee23411d0..adec7d321994 100644
--- a/board/synopsys/emsdp/emsdp.c
+++ b/board/synopsys/emsdp/emsdp.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <command.h>
#include <cpu_func.h>
#include <dwmmc.h>
diff --git a/board/synopsys/hsdk/clk-lib.h b/board/synopsys/hsdk/clk-lib.h
index 970bcd4a17e7..e1140a10b23a 100644
--- a/board/synopsys/hsdk/clk-lib.h
+++ b/board/synopsys/hsdk/clk-lib.h
@@ -7,7 +7,6 @@
#ifndef __BOARD_CLK_LIB_H
#define __BOARD_CLK_LIB_H
-#include <common.h>
#include <linux/bitops.h>
enum clk_ctl_ops {
diff --git a/board/synopsys/hsdk/env-lib.c b/board/synopsys/hsdk/env-lib.c
index d85e8167332f..85a2249f17f2 100644
--- a/board/synopsys/hsdk/env-lib.c
+++ b/board/synopsys/hsdk/env-lib.c
@@ -7,6 +7,8 @@
#include "env-lib.h"
#include <env.h>
#include <log.h>
+#include <vsprintf.h>
+#include <linux/errno.h>
#include <linux/printk.h>
#define MAX_CMD_LEN 25
diff --git a/board/synopsys/hsdk/env-lib.h b/board/synopsys/hsdk/env-lib.h
index 48c17c4d4f62..cabca1d0f3d3 100644
--- a/board/synopsys/hsdk/env-lib.h
+++ b/board/synopsys/hsdk/env-lib.h
@@ -7,7 +7,6 @@
#ifndef __BOARD_ENV_LIB_H
#define __BOARD_ENV_LIB_H
-#include <common.h>
#include <config.h>
#include <linux/kernel.h>
diff --git a/board/synopsys/hsdk/hsdk.c b/board/synopsys/hsdk/hsdk.c
index 6cbc89ae7874..8eb10f2226fc 100644
--- a/board/synopsys/hsdk/hsdk.c
+++ b/board/synopsys/hsdk/hsdk.c
@@ -4,7 +4,6 @@
* Author: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
*/
-#include <common.h>
#include <command.h>
#include <config.h>
#include <cpu_func.h>
diff --git a/board/synopsys/iot_devkit/iot_devkit.c b/board/synopsys/iot_devkit/iot_devkit.c
index 650958f94c26..dec49e3ce5d6 100644
--- a/board/synopsys/iot_devkit/iot_devkit.c
+++ b/board/synopsys/iot_devkit/iot_devkit.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <malloc.h>
diff --git a/board/synopsys/nsim/nsim.c b/board/synopsys/nsim/nsim.c
index 00e5cc36414b..5953b365fd20 100644
--- a/board/synopsys/nsim/nsim.c
+++ b/board/synopsys/nsim/nsim.c
@@ -3,7 +3,6 @@
* Copyright (C) 2020 Synopsys, Inc. All rights reserved.
*/
-#include <common.h>
#include <init.h>
#include <dm/device.h>
#include <virtio_types.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 4/7] m68k: Remove common.h usage
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
2023-10-12 23:03 ` [PATCH 3/7] arc: Remove common.h usage Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
2023-10-13 15:14 ` Simon Glass
` (2 more replies)
2023-10-12 23:03 ` [PATCH 5/7] microblaze: " Tom Rini
` (3 subsequent siblings)
6 siblings, 3 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Angelo Dureghello
We can remove common.h from most cases of the code here, and only a few
places need an additional header instead.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Angelo Dureghello <angelo@kernel-space.org>
---
arch/m68k/cpu/mcf523x/cpu.c | 1 -
arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
arch/m68k/cpu/mcf523x/interrupts.c | 1 -
arch/m68k/cpu/mcf523x/speed.c | 1 -
arch/m68k/cpu/mcf52x2/cpu.c | 1 -
arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
arch/m68k/cpu/mcf52x2/speed.c | 1 -
arch/m68k/cpu/mcf530x/cpu.c | 1 -
arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
arch/m68k/cpu/mcf530x/interrupts.c | 1 -
arch/m68k/cpu/mcf530x/speed.c | 1 -
arch/m68k/cpu/mcf532x/cpu.c | 1 -
arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
arch/m68k/cpu/mcf532x/interrupts.c | 1 -
arch/m68k/cpu/mcf532x/speed.c | 1 -
arch/m68k/cpu/mcf5445x/cpu.c | 1 -
arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
arch/m68k/cpu/mcf5445x/dspi.c | 1 -
arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
arch/m68k/cpu/mcf5445x/speed.c | 1 -
arch/m68k/cpu/mcf5445x/start.S | 1 -
arch/m68k/include/asm/immap.h | 1 +
arch/m68k/include/asm/immap_520x.h | 1 +
arch/m68k/include/asm/immap_5235.h | 1 +
arch/m68k/include/asm/immap_5272.h | 1 +
arch/m68k/include/asm/immap_5275.h | 1 +
arch/m68k/include/asm/immap_5282.h | 1 +
arch/m68k/include/asm/immap_5301x.h | 1 +
arch/m68k/include/asm/immap_5307.h | 2 ++
arch/m68k/include/asm/immap_5329.h | 1 +
arch/m68k/include/asm/immap_5441x.h | 1 +
arch/m68k/lib/bdinfo.c | 3 ++-
arch/m68k/lib/bootm.c | 1 -
arch/m68k/lib/cache.c | 2 +-
arch/m68k/lib/fec.c | 2 +-
arch/m68k/lib/interrupts.c | 2 +-
arch/m68k/lib/time.c | 1 -
arch/m68k/lib/traps.c | 1 -
39 files changed, 17 insertions(+), 30 deletions(-)
diff --git a/arch/m68k/cpu/mcf523x/cpu.c b/arch/m68k/cpu/mcf523x/cpu.c
index bef67767b425..c843a381ea1f 100644
--- a/arch/m68k/cpu/mcf523x/cpu.c
+++ b/arch/m68k/cpu/mcf523x/cpu.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <init.h>
#include <net.h>
#include <vsprintf.h>
diff --git a/arch/m68k/cpu/mcf523x/cpu_init.c b/arch/m68k/cpu/mcf523x/cpu_init.c
index 10be73822fa5..a05cbdcb3852 100644
--- a/arch/m68k/cpu/mcf523x/cpu_init.c
+++ b/arch/m68k/cpu/mcf523x/cpu_init.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <watchdog.h>
diff --git a/arch/m68k/cpu/mcf523x/interrupts.c b/arch/m68k/cpu/mcf523x/interrupts.c
index 09c7f9e67cc7..46c9207a93bb 100644
--- a/arch/m68k/cpu/mcf523x/interrupts.c
+++ b/arch/m68k/cpu/mcf523x/interrupts.c
@@ -6,7 +6,6 @@
*/
/* CPU specific interrupt routine */
-#include <common.h>
#include <irq_func.h>
#include <asm/immap.h>
#include <asm/io.h>
diff --git a/arch/m68k/cpu/mcf523x/speed.c b/arch/m68k/cpu/mcf523x/speed.c
index 6b08a12af0b6..2eb43cc7eb9a 100644
--- a/arch/m68k/cpu/mcf523x/speed.c
+++ b/arch/m68k/cpu/mcf523x/speed.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf52x2/cpu.c b/arch/m68k/cpu/mcf52x2/cpu.c
index 5042a38b3e9e..6bfde5e9bd70 100644
--- a/arch/m68k/cpu/mcf52x2/cpu.c
+++ b/arch/m68k/cpu/mcf52x2/cpu.c
@@ -13,7 +13,6 @@
* Copyright (C) 2012 Freescale Semiconductor, Inc. All Rights Reserved.
*/
-#include <common.h>
#include <init.h>
#include <net.h>
#include <vsprintf.h>
diff --git a/arch/m68k/cpu/mcf52x2/cpu_init.c b/arch/m68k/cpu/mcf52x2/cpu_init.c
index 99eb61f16758..4506eb39edfc 100644
--- a/arch/m68k/cpu/mcf52x2/cpu_init.c
+++ b/arch/m68k/cpu/mcf52x2/cpu_init.c
@@ -17,7 +17,7 @@
* Copyright (C) 2008 Arthur Shipkowski (art@videon-central.com)
*/
-#include <common.h>
+#include <config.h>
#include <cpu_func.h>
#include <init.h>
#include <watchdog.h>
@@ -25,7 +25,6 @@
#include <asm/io.h>
#if defined(CONFIG_CMD_NET)
-#include <config.h>
#include <net.h>
#include <asm/fec.h>
#endif
diff --git a/arch/m68k/cpu/mcf52x2/interrupts.c b/arch/m68k/cpu/mcf52x2/interrupts.c
index c5ed06007369..264bdc7d6c7e 100644
--- a/arch/m68k/cpu/mcf52x2/interrupts.c
+++ b/arch/m68k/cpu/mcf52x2/interrupts.c
@@ -7,7 +7,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <irq_func.h>
#include <watchdog.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf52x2/speed.c b/arch/m68k/cpu/mcf52x2/speed.c
index 6c7628252b59..538e4c623d42 100644
--- a/arch/m68k/cpu/mcf52x2/speed.c
+++ b/arch/m68k/cpu/mcf52x2/speed.c
@@ -7,7 +7,6 @@
* Hayden Fraser (Hayden.Fraser@freescale.com)
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf530x/cpu.c b/arch/m68k/cpu/mcf530x/cpu.c
index 53a25d8362cd..92a0ef76895c 100644
--- a/arch/m68k/cpu/mcf530x/cpu.c
+++ b/arch/m68k/cpu/mcf530x/cpu.c
@@ -4,7 +4,6 @@
*
*/
-#include <common.h>
#include <command.h>
#include <init.h>
#include <vsprintf.h>
diff --git a/arch/m68k/cpu/mcf530x/cpu_init.c b/arch/m68k/cpu/mcf530x/cpu_init.c
index dad47d87ab31..8f6e668d103a 100644
--- a/arch/m68k/cpu/mcf530x/cpu_init.c
+++ b/arch/m68k/cpu/mcf530x/cpu_init.c
@@ -4,7 +4,6 @@
*
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <watchdog.h>
diff --git a/arch/m68k/cpu/mcf530x/interrupts.c b/arch/m68k/cpu/mcf530x/interrupts.c
index 11686202dc73..99cf86385037 100644
--- a/arch/m68k/cpu/mcf530x/interrupts.c
+++ b/arch/m68k/cpu/mcf530x/interrupts.c
@@ -4,7 +4,6 @@
*
*/
-#include <common.h>
#include <irq_func.h>
#include <asm/immap.h>
#include <asm/io.h>
diff --git a/arch/m68k/cpu/mcf530x/speed.c b/arch/m68k/cpu/mcf530x/speed.c
index c8d079016f2e..6542fc43ab10 100644
--- a/arch/m68k/cpu/mcf530x/speed.c
+++ b/arch/m68k/cpu/mcf530x/speed.c
@@ -4,7 +4,6 @@
*
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf532x/cpu.c b/arch/m68k/cpu/mcf532x/cpu.c
index 18d20a892655..6973af9d045d 100644
--- a/arch/m68k/cpu/mcf532x/cpu.c
+++ b/arch/m68k/cpu/mcf532x/cpu.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <init.h>
#include <net.h>
#include <vsprintf.h>
diff --git a/arch/m68k/cpu/mcf532x/cpu_init.c b/arch/m68k/cpu/mcf532x/cpu_init.c
index 844d2cd7600f..62a45f96314d 100644
--- a/arch/m68k/cpu/mcf532x/cpu_init.c
+++ b/arch/m68k/cpu/mcf532x/cpu_init.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <watchdog.h>
diff --git a/arch/m68k/cpu/mcf532x/interrupts.c b/arch/m68k/cpu/mcf532x/interrupts.c
index 4f72fa88e58c..e37893c3e535 100644
--- a/arch/m68k/cpu/mcf532x/interrupts.c
+++ b/arch/m68k/cpu/mcf532x/interrupts.c
@@ -6,7 +6,6 @@
*/
/* CPU specific interrupt routine */
-#include <common.h>
#include <irq_func.h>
#include <asm/immap.h>
#include <asm/io.h>
diff --git a/arch/m68k/cpu/mcf532x/speed.c b/arch/m68k/cpu/mcf532x/speed.c
index 32ffac08135d..166916526eb9 100644
--- a/arch/m68k/cpu/mcf532x/speed.c
+++ b/arch/m68k/cpu/mcf532x/speed.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf5445x/cpu.c b/arch/m68k/cpu/mcf5445x/cpu.c
index d9a71c6b920d..b811ac355e4d 100644
--- a/arch/m68k/cpu/mcf5445x/cpu.c
+++ b/arch/m68k/cpu/mcf5445x/cpu.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <init.h>
#include <net.h>
#include <vsprintf.h>
diff --git a/arch/m68k/cpu/mcf5445x/cpu_init.c b/arch/m68k/cpu/mcf5445x/cpu_init.c
index bc3a2f3aed63..3277617120c7 100644
--- a/arch/m68k/cpu/mcf5445x/cpu_init.c
+++ b/arch/m68k/cpu/mcf5445x/cpu_init.c
@@ -8,7 +8,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <watchdog.h>
diff --git a/arch/m68k/cpu/mcf5445x/dspi.c b/arch/m68k/cpu/mcf5445x/dspi.c
index 456af171a4e2..13eb6ecee101 100644
--- a/arch/m68k/cpu/mcf5445x/dspi.c
+++ b/arch/m68k/cpu/mcf5445x/dspi.c
@@ -6,7 +6,6 @@
* CPU specific dspi routines
*/
-#include <common.h>
#include <asm/immap.h>
#include <asm/io.h>
diff --git a/arch/m68k/cpu/mcf5445x/interrupts.c b/arch/m68k/cpu/mcf5445x/interrupts.c
index 400f3dee879e..913290086dca 100644
--- a/arch/m68k/cpu/mcf5445x/interrupts.c
+++ b/arch/m68k/cpu/mcf5445x/interrupts.c
@@ -9,7 +9,6 @@
*/
/* CPU specific interrupt routine */
-#include <common.h>
#include <irq_func.h>
#include <asm/immap.h>
#include <asm/io.h>
diff --git a/arch/m68k/cpu/mcf5445x/speed.c b/arch/m68k/cpu/mcf5445x/speed.c
index 5c78eb983496..41cb9e999adc 100644
--- a/arch/m68k/cpu/mcf5445x/speed.c
+++ b/arch/m68k/cpu/mcf5445x/speed.c
@@ -5,7 +5,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/processor.h>
diff --git a/arch/m68k/cpu/mcf5445x/start.S b/arch/m68k/cpu/mcf5445x/start.S
index 5c3bfff79183..f0264671d386 100644
--- a/arch/m68k/cpu/mcf5445x/start.S
+++ b/arch/m68k/cpu/mcf5445x/start.S
@@ -7,7 +7,6 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
#include <asm-offsets.h>
#include <config.h>
#include <asm/cache.h>
diff --git a/arch/m68k/include/asm/immap.h b/arch/m68k/include/asm/immap.h
index aafa4f40cb35..411b00899c25 100644
--- a/arch/m68k/include/asm/immap.h
+++ b/arch/m68k/include/asm/immap.h
@@ -9,6 +9,7 @@
#ifndef __IMMAP_H
#define __IMMAP_H
+#include <config.h>
#if defined(CONFIG_MCF520x)
#include <asm/immap_520x.h>
#include <asm/m520x.h>
diff --git a/arch/m68k/include/asm/immap_520x.h b/arch/m68k/include/asm/immap_520x.h
index 7c7443b96885..d3c2f4a4091d 100644
--- a/arch/m68k/include/asm/immap_520x.h
+++ b/arch/m68k/include/asm/immap_520x.h
@@ -36,6 +36,7 @@
#define MMAP_GPIO (CFG_SYS_MBAR + 0x000A4000)
#define MMAP_SDRAM (CFG_SYS_MBAR + 0x000A8000)
+#include <linux/types.h>
#include <asm/coldfire/crossbar.h>
#include <asm/coldfire/edma.h>
#include <asm/coldfire/eport.h>
diff --git a/arch/m68k/include/asm/immap_5235.h b/arch/m68k/include/asm/immap_5235.h
index a1825c2a944f..d9b0be1d7d41 100644
--- a/arch/m68k/include/asm/immap_5235.h
+++ b/arch/m68k/include/asm/immap_5235.h
@@ -46,6 +46,7 @@
#define MMAP_ETPU (CFG_SYS_MBAR + 0x001D0000)
#define MMAP_CAN2 (CFG_SYS_MBAR + 0x001F0000)
+#include <linux/types.h>
#include <asm/coldfire/eport.h>
#include <asm/coldfire/flexbus.h>
#include <asm/coldfire/flexcan.h>
diff --git a/arch/m68k/include/asm/immap_5272.h b/arch/m68k/include/asm/immap_5272.h
index c5c3cc751258..5378ed1aac16 100644
--- a/arch/m68k/include/asm/immap_5272.h
+++ b/arch/m68k/include/asm/immap_5272.h
@@ -27,6 +27,7 @@
#define MMAP_FEC (CFG_SYS_MBAR + 0x00000840)
#define MMAP_USB (CFG_SYS_MBAR + 0x00001000)
+#include <linux/types.h>
#include <asm/coldfire/pwm.h>
/* System configuration registers */
diff --git a/arch/m68k/include/asm/immap_5275.h b/arch/m68k/include/asm/immap_5275.h
index 9b8d71d30d44..c4cce3f94f14 100644
--- a/arch/m68k/include/asm/immap_5275.h
+++ b/arch/m68k/include/asm/immap_5275.h
@@ -49,6 +49,7 @@
#define MMAP_USB (CFG_SYS_MBAR + 0x001C0000)
#define MMAP_PWM0 (CFG_SYS_MBAR + 0x001D0000)
+#include <linux/types.h>
#include <asm/coldfire/eport.h>
#include <asm/coldfire/flexbus.h>
#include <asm/coldfire/intctrl.h>
diff --git a/arch/m68k/include/asm/immap_5282.h b/arch/m68k/include/asm/immap_5282.h
index f810a4dd5cb5..e5f400e6ae32 100644
--- a/arch/m68k/include/asm/immap_5282.h
+++ b/arch/m68k/include/asm/immap_5282.h
@@ -45,6 +45,7 @@
#define MMAP_CFMC (CFG_SYS_MBAR + 0x001D0000)
#define MMAP_CFMMEM (CFG_SYS_MBAR + 0x04000000)
+#include <linux/types.h>
#include <asm/coldfire/eport.h>
#include <asm/coldfire/flexbus.h>
#include <asm/coldfire/flexcan.h>
diff --git a/arch/m68k/include/asm/immap_5301x.h b/arch/m68k/include/asm/immap_5301x.h
index e1f7858b1007..3ade4f04756c 100644
--- a/arch/m68k/include/asm/immap_5301x.h
+++ b/arch/m68k/include/asm/immap_5301x.h
@@ -50,6 +50,7 @@
#define MMAP_IIM (CFG_SYS_MBAR + 0x000C8000)
#define MMAP_ESDHC (CFG_SYS_MBAR + 0x000CC000)
+#include <linux/types.h>
#include <asm/coldfire/crossbar.h>
#include <asm/coldfire/dspi.h>
#include <asm/coldfire/edma.h>
diff --git a/arch/m68k/include/asm/immap_5307.h b/arch/m68k/include/asm/immap_5307.h
index d6442d95b4ba..d96dd146efb0 100644
--- a/arch/m68k/include/asm/immap_5307.h
+++ b/arch/m68k/include/asm/immap_5307.h
@@ -17,6 +17,8 @@
#define MMAP_UART1 (CFG_SYS_MBAR + 0x00000200)
#define MMAP_GPIO (CFG_SYS_MBAR + 0x00000244)
+#include <linux/types.h>
+
typedef struct sim {
u8 rsr;
u8 sypcr;
diff --git a/arch/m68k/include/asm/immap_5329.h b/arch/m68k/include/asm/immap_5329.h
index dbf3a2260eed..6f1795a207a1 100644
--- a/arch/m68k/include/asm/immap_5329.h
+++ b/arch/m68k/include/asm/immap_5329.h
@@ -51,6 +51,7 @@
#define MMAP_SSI 0xFC0BC000
#define MMAP_PLL 0xFC0C0000
+#include <linux/types.h>
#include <asm/coldfire/crossbar.h>
#include <asm/coldfire/edma.h>
#include <asm/coldfire/eport.h>
diff --git a/arch/m68k/include/asm/immap_5441x.h b/arch/m68k/include/asm/immap_5441x.h
index 708d0db755a8..c8f3effe2407 100644
--- a/arch/m68k/include/asm/immap_5441x.h
+++ b/arch/m68k/include/asm/immap_5441x.h
@@ -76,6 +76,7 @@
#define MMAP_CCM 0xEC090000
#define MMAP_GPIO 0xEC094000
+#include <linux/types.h>
#include <asm/coldfire/crossbar.h>
#include <asm/coldfire/dspi.h>
#include <asm/coldfire/edma.h>
diff --git a/arch/m68k/lib/bdinfo.c b/arch/m68k/lib/bdinfo.c
index 0b4629f1c8a7..3719f11c03c6 100644
--- a/arch/m68k/lib/bdinfo.c
+++ b/arch/m68k/lib/bdinfo.c
@@ -6,8 +6,9 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
+#include <config.h>
#include <init.h>
+#include <asm/u-boot.h>
#include <asm/global_data.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/arch/m68k/lib/bootm.c b/arch/m68k/lib/bootm.c
index f18bed235d45..79d8b34c0d56 100644
--- a/arch/m68k/lib/bootm.c
+++ b/arch/m68k/lib/bootm.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
#include <bootstage.h>
#include <command.h>
#include <env.h>
diff --git a/arch/m68k/lib/cache.c b/arch/m68k/lib/cache.c
index 57e5632fdb5b..de04124404cf 100644
--- a/arch/m68k/lib/cache.c
+++ b/arch/m68k/lib/cache.c
@@ -4,7 +4,7 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
+#include <config.h>
#include <cpu_func.h>
#include <asm/immap.h>
#include <asm/cache.h>
diff --git a/arch/m68k/lib/fec.c b/arch/m68k/lib/fec.c
index eecea7a02354..d6f238e4b347 100644
--- a/arch/m68k/lib/fec.c
+++ b/arch/m68k/lib/fec.c
@@ -3,8 +3,8 @@
* (C) 2019 Angelo Dureghello <angelo.dureghello@timesys.com>
*/
-#include <common.h>
#include <asm/global_data.h>
+#include <linux/errno.h>
#include <linux/libfdt.h>
#include <fdt_support.h>
diff --git a/arch/m68k/lib/interrupts.c b/arch/m68k/lib/interrupts.c
index 799daab5612d..175ec689533e 100644
--- a/arch/m68k/lib/interrupts.c
+++ b/arch/m68k/lib/interrupts.c
@@ -7,7 +7,7 @@
* TsiChung Liew (Tsi-Chung.Liew@freescale.com)
*/
-#include <common.h>
+#include <stdio.h>
#include <irq_func.h>
#include <watchdog.h>
#include <asm/processor.h>
diff --git a/arch/m68k/lib/time.c b/arch/m68k/lib/time.c
index 61db1e6c5002..4249488c01d1 100644
--- a/arch/m68k/lib/time.c
+++ b/arch/m68k/lib/time.c
@@ -6,7 +6,6 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
#include <init.h>
#include <irq_func.h>
#include <time.h>
diff --git a/arch/m68k/lib/traps.c b/arch/m68k/lib/traps.c
index 28fe803928ea..c283351181d8 100644
--- a/arch/m68k/lib/traps.c
+++ b/arch/m68k/lib/traps.c
@@ -7,7 +7,6 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
#include <init.h>
#include <watchdog.h>
#include <command.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 5/7] microblaze: Remove common.h usage
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
` (2 preceding siblings ...)
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
2023-10-13 7:11 ` Michal Simek
2023-10-24 23:16 ` Tom Rini
2023-10-12 23:03 ` [PATCH 6/7] mips: " Tom Rini
` (2 subsequent siblings)
6 siblings, 2 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Michal Simek
We can remove common.h from most cases of the code here, and only a few
places need an additional header instead.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Michal Simek <michal.simek@amd.com>
---
arch/microblaze/cpu/cache.c | 1 -
arch/microblaze/cpu/cpuinfo.c | 1 -
arch/microblaze/cpu/exception.c | 2 +-
arch/microblaze/cpu/interrupts.c | 3 ++-
arch/microblaze/cpu/pvr.c | 1 -
arch/microblaze/cpu/relocate.c | 3 ++-
arch/microblaze/cpu/spl.c | 1 -
arch/microblaze/include/asm/cpuinfo.h | 2 ++
arch/microblaze/lib/bootm.c | 1 -
board/xilinx/microblaze-generic/microblaze-generic.c | 1 -
10 files changed, 7 insertions(+), 9 deletions(-)
diff --git a/arch/microblaze/cpu/cache.c b/arch/microblaze/cpu/cache.c
index 829e6c7ae605..75ec0a8fd24f 100644
--- a/arch/microblaze/cpu/cache.c
+++ b/arch/microblaze/cpu/cache.c
@@ -5,7 +5,6 @@
* Michal SIMEK <monstr@monstr.eu>
*/
-#include <common.h>
#include <cpu_func.h>
#include <asm/asm.h>
#include <asm/cache.h>
diff --git a/arch/microblaze/cpu/cpuinfo.c b/arch/microblaze/cpu/cpuinfo.c
index 6b15d6ca41c0..2bfdf767f3a5 100644
--- a/arch/microblaze/cpu/cpuinfo.c
+++ b/arch/microblaze/cpu/cpuinfo.c
@@ -2,7 +2,6 @@
/*
* Copyright (C) 2022, Ovidiu Panait <ovpanait@gmail.com>
*/
-#include <common.h>
#include <asm/cpuinfo.h>
#include <asm/global_data.h>
diff --git a/arch/microblaze/cpu/exception.c b/arch/microblaze/cpu/exception.c
index 9414776afa7f..6b329fc7b3a2 100644
--- a/arch/microblaze/cpu/exception.c
+++ b/arch/microblaze/cpu/exception.c
@@ -5,8 +5,8 @@
* Michal SIMEK <monstr@monstr.eu>
*/
-#include <common.h>
#include <hang.h>
+#include <stdio.h>
#include <asm/asm.h>
void _hw_exception_handler (void)
diff --git a/arch/microblaze/cpu/interrupts.c b/arch/microblaze/cpu/interrupts.c
index ac53208bda67..244f7fd15eba 100644
--- a/arch/microblaze/cpu/interrupts.c
+++ b/arch/microblaze/cpu/interrupts.c
@@ -7,7 +7,8 @@
* Yasushi SHOJI <yashi@atmark-techno.com>
*/
-#include <common.h>
+#include <log.h>
+#include <vsprintf.h>
#include <asm/asm.h>
void enable_interrupts(void)
diff --git a/arch/microblaze/cpu/pvr.c b/arch/microblaze/cpu/pvr.c
index 23c0f912d435..71aea0b9380c 100644
--- a/arch/microblaze/cpu/pvr.c
+++ b/arch/microblaze/cpu/pvr.c
@@ -2,7 +2,6 @@
/*
* Copyright (C) 2022, Ovidiu Panait <ovpanait@gmail.com>
*/
-#include <common.h>
#include <asm/asm.h>
#include <asm/pvr.h>
diff --git a/arch/microblaze/cpu/relocate.c b/arch/microblaze/cpu/relocate.c
index 7a15fb2ec397..e46fe5bdd5d7 100644
--- a/arch/microblaze/cpu/relocate.c
+++ b/arch/microblaze/cpu/relocate.c
@@ -4,8 +4,9 @@
* Michal Simek <michal.simek@amd.com>
*/
-#include <common.h>
#include <elf.h>
+#include <log.h>
+#include <linux/types.h>
#define R_MICROBLAZE_NONE 0
#define R_MICROBLAZE_32 1
diff --git a/arch/microblaze/cpu/spl.c b/arch/microblaze/cpu/spl.c
index c21beafdb810..cb224bd25423 100644
--- a/arch/microblaze/cpu/spl.c
+++ b/arch/microblaze/cpu/spl.c
@@ -5,7 +5,6 @@
* Michal Simek <michal.simek@amd.com>
*/
-#include <common.h>
#include <command.h>
#include <image.h>
#include <log.h>
diff --git a/arch/microblaze/include/asm/cpuinfo.h b/arch/microblaze/include/asm/cpuinfo.h
index 3c58e52217c4..fbd9418a2f8b 100644
--- a/arch/microblaze/include/asm/cpuinfo.h
+++ b/arch/microblaze/include/asm/cpuinfo.h
@@ -6,6 +6,8 @@
#ifndef __ASM_MICROBLAZE_CPUINFO_H
#define __ASM_MICROBLAZE_CPUINFO_H
+#include <linux/types.h>
+
/**
* struct microblaze_cpuinfo - CPU info for microblaze processor core.
*
diff --git a/arch/microblaze/lib/bootm.c b/arch/microblaze/lib/bootm.c
index 930384f4015f..f3ec4b741b88 100644
--- a/arch/microblaze/lib/bootm.c
+++ b/arch/microblaze/lib/bootm.c
@@ -7,7 +7,6 @@
* Yasushi SHOJI <yashi@atmark-techno.com>
*/
-#include <common.h>
#include <bootstage.h>
#include <command.h>
#include <cpu_func.h>
diff --git a/board/xilinx/microblaze-generic/microblaze-generic.c b/board/xilinx/microblaze-generic/microblaze-generic.c
index a427ac94a170..2b035d535892 100644
--- a/board/xilinx/microblaze-generic/microblaze-generic.c
+++ b/board/xilinx/microblaze-generic/microblaze-generic.c
@@ -10,7 +10,6 @@
* header files
*/
-#include <common.h>
#include <config.h>
#include <env.h>
#include <init.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 6/7] mips: Remove common.h usage
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
` (3 preceding siblings ...)
2023-10-12 23:03 ` [PATCH 5/7] microblaze: " Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
2023-10-24 23:16 ` Tom Rini
2023-10-12 23:03 ` [PATCH 7/7] riscv: " Tom Rini
2023-10-13 15:15 ` [PATCH 1/7] checkpatch.pl: Make common.h check boarder Simon Glass
6 siblings, 1 reply; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Daniel Schwierzeck
We can remove common.h from most cases of the code here, and only a few
places need an additional header instead.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
---
arch/mips/cpu/cpu.c | 1 -
arch/mips/cpu/interrupts.c | 1 -
arch/mips/cpu/time.c | 1 -
arch/mips/include/asm/cacheops.h | 1 +
arch/mips/lib/boot.c | 1 -
arch/mips/lib/bootm.c | 1 -
arch/mips/lib/cache.c | 1 -
arch/mips/lib/reloc.c | 1 -
arch/mips/lib/spl.c | 1 -
arch/mips/lib/stack.c | 1 -
arch/mips/lib/traps.c | 3 ++-
arch/mips/mach-ath79/ar933x/clk.c | 1 -
arch/mips/mach-ath79/ar933x/ddr.c | 1 -
arch/mips/mach-ath79/ar934x/clk.c | 1 -
arch/mips/mach-ath79/ar934x/cpu.c | 2 --
arch/mips/mach-ath79/ar934x/ddr.c | 1 -
arch/mips/mach-ath79/cpu.c | 1 -
arch/mips/mach-ath79/dram.c | 1 -
arch/mips/mach-ath79/qca953x/clk.c | 1 -
arch/mips/mach-ath79/qca953x/ddr.c | 1 -
arch/mips/mach-ath79/qca956x/clk.c | 1 -
arch/mips/mach-ath79/qca956x/cpu.c | 2 --
arch/mips/mach-ath79/qca956x/ddr.c | 1 -
arch/mips/mach-ath79/reset.c | 1 -
arch/mips/mach-bmips/dram.c | 1 -
arch/mips/mach-jz47xx/jz4780/gpio.c | 1 -
arch/mips/mach-jz47xx/jz4780/jz4780.c | 1 -
arch/mips/mach-jz47xx/jz4780/pll.c | 1 -
arch/mips/mach-jz47xx/jz4780/reset.c | 1 -
arch/mips/mach-jz47xx/jz4780/sdram.c | 1 -
arch/mips/mach-jz47xx/jz4780/timer.c | 1 -
arch/mips/mach-mscc/cpu.c | 1 -
arch/mips/mach-mscc/dram.c | 1 -
arch/mips/mach-mscc/gpio.c | 1 -
arch/mips/mach-mscc/include/mach/ddr.h | 1 +
arch/mips/mach-mscc/phy.c | 1 -
arch/mips/mach-mscc/reset.c | 2 --
arch/mips/mach-mtmips/cpu.c | 1 -
arch/mips/mach-mtmips/ddr_cal.c | 1 -
arch/mips/mach-mtmips/ddr_init.c | 1 -
arch/mips/mach-mtmips/mt7628/ddr.c | 1 -
arch/mips/mach-mtmips/mt7628/init.c | 1 -
arch/mips/mach-mtmips/mt7628/serial.c | 1 -
arch/mips/mach-mtmips/spl.c | 1 -
arch/mips/mach-pic32/cpu.c | 1 -
arch/mips/mach-pic32/reset.c | 1 -
46 files changed, 4 insertions(+), 47 deletions(-)
diff --git a/arch/mips/cpu/cpu.c b/arch/mips/cpu/cpu.c
index f0e20da28f76..acfc9dc43f17 100644
--- a/arch/mips/cpu/cpu.c
+++ b/arch/mips/cpu/cpu.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, <wd@denx.de>
*/
-#include <common.h>
#include <command.h>
#include <init.h>
#include <linux/compiler.h>
diff --git a/arch/mips/cpu/interrupts.c b/arch/mips/cpu/interrupts.c
index b3ba9aaeae1e..f7f9a185ed49 100644
--- a/arch/mips/cpu/interrupts.c
+++ b/arch/mips/cpu/interrupts.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, <wd@denx.de>
*/
-#include <common.h>
#include <irq_func.h>
int interrupt_init(void)
diff --git a/arch/mips/cpu/time.c b/arch/mips/cpu/time.c
index 5e7a7144d027..210709d3b81d 100644
--- a/arch/mips/cpu/time.c
+++ b/arch/mips/cpu/time.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
#include <time.h>
#include <asm/mipsregs.h>
diff --git a/arch/mips/include/asm/cacheops.h b/arch/mips/include/asm/cacheops.h
index 641e2ad58dec..c1015c885e14 100644
--- a/arch/mips/include/asm/cacheops.h
+++ b/arch/mips/include/asm/cacheops.h
@@ -11,6 +11,7 @@
#include <asm/cache.h>
#ifndef __ASSEMBLY__
+#include <linux/types.h>
static inline void mips_cache(int op, const volatile void *addr)
{
diff --git a/arch/mips/lib/boot.c b/arch/mips/lib/boot.c
index 1b29d637ce9b..749625aa9748 100644
--- a/arch/mips/lib/boot.c
+++ b/arch/mips/lib/boot.c
@@ -3,7 +3,6 @@
* Copyright (C) 2020 Stefan Roese <sr@denx.de>
*/
-#include <common.h>
#include <command.h>
#include <cpu_func.h>
#include <asm/global_data.h>
diff --git a/arch/mips/lib/bootm.c b/arch/mips/lib/bootm.c
index ab92bd06b0ee..d6d2f7d9d031 100644
--- a/arch/mips/lib/bootm.c
+++ b/arch/mips/lib/bootm.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*/
-#include <common.h>
#include <bootstage.h>
#include <env.h>
#include <image.h>
diff --git a/arch/mips/lib/cache.c b/arch/mips/lib/cache.c
index d23b38d6b93f..d365578b926c 100644
--- a/arch/mips/lib/cache.c
+++ b/arch/mips/lib/cache.c
@@ -4,7 +4,6 @@
* Wolfgang Denk, DENX Software Engineering, <wd@denx.de>
*/
-#include <common.h>
#include <cpu_func.h>
#include <malloc.h>
#include <asm/cache.h>
diff --git a/arch/mips/lib/reloc.c b/arch/mips/lib/reloc.c
index 9cf6809f4068..69dd63a31d21 100644
--- a/arch/mips/lib/reloc.c
+++ b/arch/mips/lib/reloc.c
@@ -26,7 +26,6 @@
* terminating R_MIPS_NONE reloc includes no offset.
*/
-#include <common.h>
#include <cpu_func.h>
#include <init.h>
#include <asm/relocs.h>
diff --git a/arch/mips/lib/spl.c b/arch/mips/lib/spl.c
index f96fda5b2de9..b4087546dd1d 100644
--- a/arch/mips/lib/spl.c
+++ b/arch/mips/lib/spl.c
@@ -3,7 +3,6 @@
* Copyright (C) 2020 Stefan Roese <sr@denx.de>
*/
-#include <common.h>
#include <cpu_func.h>
#include <log.h>
#include <spl.h>
diff --git a/arch/mips/lib/stack.c b/arch/mips/lib/stack.c
index 930d21856d90..5797271ae94e 100644
--- a/arch/mips/lib/stack.c
+++ b/arch/mips/lib/stack.c
@@ -1,6 +1,5 @@
// SPDX-License-Identifier: GPL-2.0+
-#include <common.h>
#include <init.h>
#include <log.h>
#include <asm/global_data.h>
diff --git a/arch/mips/lib/traps.c b/arch/mips/lib/traps.c
index 7a682f256a65..40469d1be090 100644
--- a/arch/mips/lib/traps.c
+++ b/arch/mips/lib/traps.c
@@ -10,9 +10,9 @@
* Copyright (C) 2014, Imagination Technologies Ltd.
*/
-#include <common.h>
#include <asm/global_data.h>
#include <asm/ptrace.h>
+#include <config.h>
#include <cpu_func.h>
#include <hang.h>
#include <init.h>
@@ -20,6 +20,7 @@
#include <asm/mipsregs.h>
#include <asm/addrspace.h>
#include <asm/system.h>
+#include <asm/u-boot.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/arch/mips/mach-ath79/ar933x/clk.c b/arch/mips/mach-ath79/ar933x/clk.c
index 68d48939d7d2..86fc40a657e1 100644
--- a/arch/mips/mach-ath79/ar933x/clk.c
+++ b/arch/mips/mach-ath79/ar933x/clk.c
@@ -3,7 +3,6 @@
* Copyright (C) 2015-2016 Wills Wang <wills.wang@live.com>
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/io.h>
diff --git a/arch/mips/mach-ath79/ar933x/ddr.c b/arch/mips/mach-ath79/ar933x/ddr.c
index 09166ecf8f07..a932efbfbd79 100644
--- a/arch/mips/mach-ath79/ar933x/ddr.c
+++ b/arch/mips/mach-ath79/ar933x/ddr.c
@@ -4,7 +4,6 @@
* Based on Atheros LSDK/QSDK
*/
-#include <common.h>
#include <asm/io.h>
#include <asm/addrspace.h>
#include <asm/types.h>
diff --git a/arch/mips/mach-ath79/ar934x/clk.c b/arch/mips/mach-ath79/ar934x/clk.c
index 6ed4057353a8..bdaa6839a2bd 100644
--- a/arch/mips/mach-ath79/ar934x/clk.c
+++ b/arch/mips/mach-ath79/ar934x/clk.c
@@ -3,7 +3,6 @@
* Copyright (C) 2016 Marek Vasut <marex@denx.de>
*/
-#include <common.h>
#include <clock_legacy.h>
#include <command.h>
#include <hang.h>
diff --git a/arch/mips/mach-ath79/ar934x/cpu.c b/arch/mips/mach-ath79/ar934x/cpu.c
index 7daac0367149..f2e4ef191eb5 100644
--- a/arch/mips/mach-ath79/ar934x/cpu.c
+++ b/arch/mips/mach-ath79/ar934x/cpu.c
@@ -3,7 +3,5 @@
* Copyright (C) 2016 Marek Vasut <marex@denx.de>
*/
-#include <common.h>
-
/* The lowlevel_init() is not needed on AR934x */
void lowlevel_init(void) {}
diff --git a/arch/mips/mach-ath79/ar934x/ddr.c b/arch/mips/mach-ath79/ar934x/ddr.c
index 9df48b97ef46..e260783d9597 100644
--- a/arch/mips/mach-ath79/ar934x/ddr.c
+++ b/arch/mips/mach-ath79/ar934x/ddr.c
@@ -5,7 +5,6 @@
* Based on RAM init sequence by Piotr Dymacz <pepe2k@gmail.com>
*/
-#include <common.h>
#include <asm/global_data.h>
#include <asm/io.h>
#include <asm/addrspace.h>
diff --git a/arch/mips/mach-ath79/cpu.c b/arch/mips/mach-ath79/cpu.c
index 79f419088a99..24160ef11521 100644
--- a/arch/mips/mach-ath79/cpu.c
+++ b/arch/mips/mach-ath79/cpu.c
@@ -3,7 +3,6 @@
* Copyright (C) 2015-2016 Wills Wang <wills.wang@live.com>
*/
-#include <common.h>
#include <init.h>
#include <asm/io.h>
#include <asm/addrspace.h>
diff --git a/arch/mips/mach-ath79/dram.c b/arch/mips/mach-ath79/dram.c
index 545b1199e106..247691d3378f 100644
--- a/arch/mips/mach-ath79/dram.c
+++ b/arch/mips/mach-ath79/dram.c
@@ -3,7 +3,6 @@
* Copyright (C) 2015-2016 Wills Wang <wills.wang@live.com>
*/
-#include <common.h>
#include <init.h>
#include <asm/global_data.h>
#include <linux/sizes.h>
diff --git a/arch/mips/mach-ath79/qca953x/clk.c b/arch/mips/mach-ath79/qca953x/clk.c
index f5438ef1c8d9..379085f1ff7f 100644
--- a/arch/mips/mach-ath79/qca953x/clk.c
+++ b/arch/mips/mach-ath79/qca953x/clk.c
@@ -3,7 +3,6 @@
* Copyright (C) 2015-2016 Wills Wang <wills.wang@live.com>
*/
-#include <common.h>
#include <clock_legacy.h>
#include <asm/global_data.h>
#include <asm/io.h>
diff --git a/arch/mips/mach-ath79/qca953x/ddr.c b/arch/mips/mach-ath79/qca953x/ddr.c
index 78f2370e09ce..0eb69d3a0fb1 100644
--- a/arch/mips/mach-ath79/qca953x/ddr.c
+++ b/arch/mips/mach-ath79/qca953x/ddr.c
@@ -4,7 +4,6 @@
* Based on Atheros LSDK/QSDK
*/
-#include <common.h>
#include <asm/io.h>
#include <asm/addrspace.h>
#include <asm/types.h>
diff --git a/arch/mips/mach-ath79/qca956x/clk.c b/arch/mips/mach-ath79/qca956x/clk.c
index 6a58dba91f3f..6138a915efcd 100644
--- a/arch/mips/mach-ath79/qca956x/clk.c
+++ b/arch/mips/mach-ath79/qca956x/clk.c
@@ -3,7 +3,6 @@
* Copyright (C) 2019 Rosy Song <rosysong@rosinson.com>
*/
-#include <common.h>
#include <clock_legacy.h>
#include <log.h>
#include <asm/global_data.h>
diff --git a/arch/mips/mach-ath79/qca956x/cpu.c b/arch/mips/mach-ath79/qca956x/cpu.c
index 08a8c84e72dd..7da8d0e60f19 100644
--- a/arch/mips/mach-ath79/qca956x/cpu.c
+++ b/arch/mips/mach-ath79/qca956x/cpu.c
@@ -3,7 +3,5 @@
* Copyright (C) 2019 Rosy Song <rosysong@rosinson.com>
*/
-#include <common.h>
-
/* The lowlevel_init() is not needed on QCA956X */
void lowlevel_init(void) {}
diff --git a/arch/mips/mach-ath79/qca956x/ddr.c b/arch/mips/mach-ath79/qca956x/ddr.c
index f9cf8daa2242..2e46e24f4830 100644
--- a/arch/mips/mach-ath79/qca956x/ddr.c
+++ b/arch/mips/mach-ath79/qca956x/ddr.c
@@ -5,7 +5,6 @@
* Based on QSDK
*/
-#include <common.h>
#include <asm/global_data.h>
#include <asm/io.h>
#include <asm/addrspace.h>
diff --git a/arch/mips/mach-ath79/reset.c b/arch/mips/mach-ath79/reset.c
index 6cd5e77fd15a..62da8b92a7d4 100644
--- a/arch/mips/mach-ath79/reset.c
+++ b/arch/mips/mach-ath79/reset.c
@@ -4,7 +4,6 @@
* Copyright (C) 2018-2019 Rosy Song <rosysong@rosinson.com>
*/
-#include <common.h>
#include <linux/bitops.h>
#include <linux/delay.h>
#include <linux/errno.h>
diff --git a/arch/mips/mach-bmips/dram.c b/arch/mips/mach-bmips/dram.c
index bba6cd6f4aaf..eec8b44e47ea 100644
--- a/arch/mips/mach-bmips/dram.c
+++ b/arch/mips/mach-bmips/dram.c
@@ -4,7 +4,6 @@
* Copyright (C) 2017 Álvaro Fernández Rojas <noltari@gmail.com>
*/
-#include <common.h>
#include <init.h>
#include <log.h>
#include <ram.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/gpio.c b/arch/mips/mach-jz47xx/jz4780/gpio.c
index d4884e7fa9f1..7f6717efc16f 100644
--- a/arch/mips/mach-jz47xx/jz4780/gpio.c
+++ b/arch/mips/mach-jz47xx/jz4780/gpio.c
@@ -1,7 +1,6 @@
// SPDX-License-Identifier: GPL-2.0+
#include <config.h>
-#include <common.h>
#include <asm/io.h>
#include <linux/bitops.h>
#include <mach/jz4780.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/jz4780.c b/arch/mips/mach-jz47xx/jz4780/jz4780.c
index 56fdf04bca9d..1d6fb6a4e27c 100644
--- a/arch/mips/mach-jz47xx/jz4780/jz4780.c
+++ b/arch/mips/mach-jz47xx/jz4780/jz4780.c
@@ -7,7 +7,6 @@
*/
#include <config.h>
-#include <common.h>
#include <cpu_func.h>
#include <hang.h>
#include <image.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/pll.c b/arch/mips/mach-jz47xx/jz4780/pll.c
index 4519b478ccb0..8ef00f99a106 100644
--- a/arch/mips/mach-jz47xx/jz4780/pll.c
+++ b/arch/mips/mach-jz47xx/jz4780/pll.c
@@ -7,7 +7,6 @@
*/
#include <config.h>
-#include <common.h>
#include <asm/io.h>
#include <linux/bitops.h>
#include <linux/delay.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/reset.c b/arch/mips/mach-jz47xx/jz4780/reset.c
index bf6addccb5de..d2e9eb79e6df 100644
--- a/arch/mips/mach-jz47xx/jz4780/reset.c
+++ b/arch/mips/mach-jz47xx/jz4780/reset.c
@@ -7,7 +7,6 @@
*/
#include <config.h>
-#include <common.h>
#include <asm/io.h>
#include <linux/bitops.h>
#include <mach/jz4780.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/sdram.c b/arch/mips/mach-jz47xx/jz4780/sdram.c
index 690f3c5601da..09296ee21ada 100644
--- a/arch/mips/mach-jz47xx/jz4780/sdram.c
+++ b/arch/mips/mach-jz47xx/jz4780/sdram.c
@@ -9,7 +9,6 @@
* Copyright (c) 2006-2013 Ingenic Semiconductor
*/
-#include <common.h>
#include <hang.h>
#include <init.h>
#include <asm/io.h>
diff --git a/arch/mips/mach-jz47xx/jz4780/timer.c b/arch/mips/mach-jz47xx/jz4780/timer.c
index 82bb9e8c3bfa..94ef505f18fe 100644
--- a/arch/mips/mach-jz47xx/jz4780/timer.c
+++ b/arch/mips/mach-jz47xx/jz4780/timer.c
@@ -7,7 +7,6 @@
*/
#include <config.h>
-#include <common.h>
#include <div64.h>
#include <init.h>
#include <irq_func.h>
diff --git a/arch/mips/mach-mscc/cpu.c b/arch/mips/mach-mscc/cpu.c
index d484eb92c419..22b1b98e0ef4 100644
--- a/arch/mips/mach-mscc/cpu.c
+++ b/arch/mips/mach-mscc/cpu.c
@@ -3,7 +3,6 @@
* Copyright (c) 2018 Microsemi Corporation
*/
-#include <common.h>
#include <init.h>
#include <asm/global_data.h>
#include <linux/bitops.h>
diff --git a/arch/mips/mach-mscc/dram.c b/arch/mips/mach-mscc/dram.c
index f7fbd33cc4b9..c7c2040a11ab 100644
--- a/arch/mips/mach-mscc/dram.c
+++ b/arch/mips/mach-mscc/dram.c
@@ -3,7 +3,6 @@
* Copyright (c) 2018 Microsemi Corporation
*/
-#include <common.h>
#include <init.h>
#include <asm/global_data.h>
diff --git a/arch/mips/mach-mscc/gpio.c b/arch/mips/mach-mscc/gpio.c
index d6b4c5d7684b..6cd0e2436e78 100644
--- a/arch/mips/mach-mscc/gpio.c
+++ b/arch/mips/mach-mscc/gpio.c
@@ -3,7 +3,6 @@
* Copyright (c) 2018 Microsemi Corporation
*/
-#include <common.h>
#include <asm/io.h>
#include <linux/bitops.h>
diff --git a/arch/mips/mach-mscc/include/mach/ddr.h b/arch/mips/mach-mscc/include/mach/ddr.h
index 75fb3ca00d2c..3ba33d27c178 100644
--- a/arch/mips/mach-mscc/include/mach/ddr.h
+++ b/arch/mips/mach-mscc/include/mach/ddr.h
@@ -6,6 +6,7 @@
#ifndef __ASM_MACH_DDR_H
#define __ASM_MACH_DDR_H
+#include <config.h>
#include <asm/cacheops.h>
#include <asm/io.h>
#include <asm/reboot.h>
diff --git a/arch/mips/mach-mscc/phy.c b/arch/mips/mach-mscc/phy.c
index 83d3e5bdd28f..444d1f5315d5 100644
--- a/arch/mips/mach-mscc/phy.c
+++ b/arch/mips/mach-mscc/phy.c
@@ -3,7 +3,6 @@
* Copyright (c) 2018 Microsemi Corporation
*/
-#include <common.h>
#include <log.h>
#include <asm/io.h>
diff --git a/arch/mips/mach-mscc/reset.c b/arch/mips/mach-mscc/reset.c
index a1214573b51a..ca9a7c679d94 100644
--- a/arch/mips/mach-mscc/reset.c
+++ b/arch/mips/mach-mscc/reset.c
@@ -3,8 +3,6 @@
* Copyright (c) 2018 Microsemi Corporation
*/
-#include <common.h>
-
#include <asm/sections.h>
#include <asm/io.h>
diff --git a/arch/mips/mach-mtmips/cpu.c b/arch/mips/mach-mtmips/cpu.c
index e88dab10c76e..243938a0ebb7 100644
--- a/arch/mips/mach-mtmips/cpu.c
+++ b/arch/mips/mach-mtmips/cpu.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018 Stefan Roese <sr@denx.de>
*/
-#include <common.h>
#include <event.h>
#include <init.h>
#include <malloc.h>
diff --git a/arch/mips/mach-mtmips/ddr_cal.c b/arch/mips/mach-mtmips/ddr_cal.c
index 762619a960f3..e2e1760a6468 100644
--- a/arch/mips/mach-mtmips/ddr_cal.c
+++ b/arch/mips/mach-mtmips/ddr_cal.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <asm/addrspace.h>
#include <asm/cacheops.h>
#include <asm/global_data.h>
diff --git a/arch/mips/mach-mtmips/ddr_init.c b/arch/mips/mach-mtmips/ddr_init.c
index 9c986daea6f5..cab53561e42e 100644
--- a/arch/mips/mach-mtmips/ddr_init.c
+++ b/arch/mips/mach-mtmips/ddr_init.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <linux/bitops.h>
#include <linux/delay.h>
#include <linux/io.h>
diff --git a/arch/mips/mach-mtmips/mt7628/ddr.c b/arch/mips/mach-mtmips/mt7628/ddr.c
index 4e72459906e8..198bf262f92b 100644
--- a/arch/mips/mach-mtmips/mt7628/ddr.c
+++ b/arch/mips/mach-mtmips/mt7628/ddr.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <asm/addrspace.h>
#include <asm/global_data.h>
#include <linux/bitops.h>
diff --git a/arch/mips/mach-mtmips/mt7628/init.c b/arch/mips/mach-mtmips/mt7628/init.c
index 6b535129df12..2996fd9ef4ee 100644
--- a/arch/mips/mach-mtmips/mt7628/init.c
+++ b/arch/mips/mach-mtmips/mt7628/init.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <clk.h>
#include <dm.h>
#include <asm/global_data.h>
diff --git a/arch/mips/mach-mtmips/mt7628/serial.c b/arch/mips/mach-mtmips/mt7628/serial.c
index e5f3f87a6737..11a2149e1273 100644
--- a/arch/mips/mach-mtmips/mt7628/serial.c
+++ b/arch/mips/mach-mtmips/mt7628/serial.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <asm/io.h>
#include "mt7628.h"
diff --git a/arch/mips/mach-mtmips/spl.c b/arch/mips/mach-mtmips/spl.c
index fe5b49e702f1..0208bc423dfb 100644
--- a/arch/mips/mach-mtmips/spl.c
+++ b/arch/mips/mach-mtmips/spl.c
@@ -5,7 +5,6 @@
* Author: Weijie Gao <weijie.gao@mediatek.com>
*/
-#include <common.h>
#include <init.h>
#include <spl.h>
#include <asm/sections.h>
diff --git a/arch/mips/mach-pic32/cpu.c b/arch/mips/mach-pic32/cpu.c
index 7ed306e045ea..dbf8c9cd221d 100644
--- a/arch/mips/mach-pic32/cpu.c
+++ b/arch/mips/mach-pic32/cpu.c
@@ -4,7 +4,6 @@
* Purna Chandra Mandal <purna.mandal@microchip.com>
*
*/
-#include <common.h>
#include <clk.h>
#include <dm.h>
#include <event.h>
diff --git a/arch/mips/mach-pic32/reset.c b/arch/mips/mach-pic32/reset.c
index 8071b13f7b48..efd6985b44a1 100644
--- a/arch/mips/mach-pic32/reset.c
+++ b/arch/mips/mach-pic32/reset.c
@@ -4,7 +4,6 @@
*
*/
-#include <common.h>
#include <asm/io.h>
#include <mach/pic32.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 7/7] riscv: Remove common.h usage
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
` (4 preceding siblings ...)
2023-10-12 23:03 ` [PATCH 6/7] mips: " Tom Rini
@ 2023-10-12 23:03 ` Tom Rini
[not found] ` <SEZPR03MB8064C345D63766D2E86B2184C1D2A@SEZPR03MB8064.apcprd03.prod.outlook.com>
2023-10-24 23:16 ` Tom Rini
2023-10-13 15:15 ` [PATCH 1/7] checkpatch.pl: Make common.h check boarder Simon Glass
6 siblings, 2 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-12 23:03 UTC (permalink / raw)
To: u-boot; +Cc: Rick Chen, Leo
We can remove common.h from most cases of the code here, and only a few
places need an additional header instead.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Rick Chen <rick@andestech.com>
Cc: Leo <ycliang@andestech.com>
---
arch/riscv/cpu/andesv5/cache.c | 1 -
arch/riscv/cpu/andesv5/cpu.c | 1 -
arch/riscv/cpu/andesv5/spl.c | 1 -
arch/riscv/cpu/cpu.c | 1 -
arch/riscv/cpu/fu540/dram.c | 1 -
arch/riscv/cpu/fu740/dram.c | 1 -
arch/riscv/cpu/generic/cpu.c | 1 -
arch/riscv/cpu/generic/dram.c | 1 -
arch/riscv/cpu/jh7110/dram.c | 1 -
arch/riscv/cpu/jh7110/spl.c | 1 -
arch/riscv/cpu/mtrap.S | 1 -
arch/riscv/cpu/start.S | 1 -
arch/riscv/include/asm/arch-andes/csr.h | 1 +
arch/riscv/include/asm/arch-jh7110/eeprom.h | 2 ++
arch/riscv/include/asm/dma-mapping.h | 1 -
arch/riscv/include/asm/smp.h | 2 ++
arch/riscv/lib/aclint_ipi.c | 1 -
arch/riscv/lib/andes_plicsw.c | 1 -
arch/riscv/lib/asm-offsets.c | 1 -
arch/riscv/lib/boot.c | 3 +--
arch/riscv/lib/bootm.c | 1 -
arch/riscv/lib/cache.c | 1 -
arch/riscv/lib/fdt_fixup.c | 1 -
arch/riscv/lib/image.c | 1 -
arch/riscv/lib/interrupts.c | 1 -
arch/riscv/lib/reset.c | 1 -
arch/riscv/lib/sbi.c | 2 +-
arch/riscv/lib/sbi_ipi.c | 1 -
arch/riscv/lib/sifive_cache.c | 2 +-
arch/riscv/lib/smp.c | 1 -
arch/riscv/lib/spl.c | 1 -
board/AndesTech/ae350/ae350.c | 2 +-
board/sifive/unmatched/hifive-platform-i2c-eeprom.c | 1 -
board/sifive/unmatched/unmatched.c | 1 -
34 files changed, 9 insertions(+), 32 deletions(-)
diff --git a/arch/riscv/cpu/andesv5/cache.c b/arch/riscv/cpu/andesv5/cache.c
index 40d77f671c87..269bb27f75a6 100644
--- a/arch/riscv/cpu/andesv5/cache.c
+++ b/arch/riscv/cpu/andesv5/cache.c
@@ -6,7 +6,6 @@
#include <asm/csr.h>
#include <asm/asm.h>
-#include <common.h>
#include <cache.h>
#include <cpu_func.h>
#include <dm.h>
diff --git a/arch/riscv/cpu/andesv5/cpu.c b/arch/riscv/cpu/andesv5/cpu.c
index 06e379bcb1fe..63bc24cdfc7c 100644
--- a/arch/riscv/cpu/andesv5/cpu.c
+++ b/arch/riscv/cpu/andesv5/cpu.c
@@ -5,7 +5,6 @@
*/
/* CPU specific code */
-#include <common.h>
#include <cpu_func.h>
#include <irq_func.h>
#include <asm/cache.h>
diff --git a/arch/riscv/cpu/andesv5/spl.c b/arch/riscv/cpu/andesv5/spl.c
index 413849043b18..a13dc4095a45 100644
--- a/arch/riscv/cpu/andesv5/spl.c
+++ b/arch/riscv/cpu/andesv5/spl.c
@@ -3,7 +3,6 @@
* Copyright (C) 2023 Andes Technology Corporation
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
*/
-#include <common.h>
#include <cpu_func.h>
#include <hang.h>
#include <init.h>
diff --git a/arch/riscv/cpu/cpu.c b/arch/riscv/cpu/cpu.c
index c1a9638c1ab7..ebd39cb41a60 100644
--- a/arch/riscv/cpu/cpu.c
+++ b/arch/riscv/cpu/cpu.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <cpu.h>
#include <dm.h>
#include <dm/lists.h>
diff --git a/arch/riscv/cpu/fu540/dram.c b/arch/riscv/cpu/fu540/dram.c
index 94d8018407e6..7b5a3471ac88 100644
--- a/arch/riscv/cpu/fu540/dram.c
+++ b/arch/riscv/cpu/fu540/dram.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <fdtdec.h>
#include <init.h>
#include <asm/global_data.h>
diff --git a/arch/riscv/cpu/fu740/dram.c b/arch/riscv/cpu/fu740/dram.c
index 8657fcd165c3..61f551763f1c 100644
--- a/arch/riscv/cpu/fu740/dram.c
+++ b/arch/riscv/cpu/fu740/dram.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <fdtdec.h>
#include <init.h>
#include <linux/sizes.h>
diff --git a/arch/riscv/cpu/generic/cpu.c b/arch/riscv/cpu/generic/cpu.c
index d78e1a3453af..f13c18942f3d 100644
--- a/arch/riscv/cpu/generic/cpu.c
+++ b/arch/riscv/cpu/generic/cpu.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <irq_func.h>
#include <asm/cache.h>
diff --git a/arch/riscv/cpu/generic/dram.c b/arch/riscv/cpu/generic/dram.c
index 94d8018407e6..7b5a3471ac88 100644
--- a/arch/riscv/cpu/generic/dram.c
+++ b/arch/riscv/cpu/generic/dram.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <fdtdec.h>
#include <init.h>
#include <asm/global_data.h>
diff --git a/arch/riscv/cpu/jh7110/dram.c b/arch/riscv/cpu/jh7110/dram.c
index 1a9fa46d14b9..664b9b93eb62 100644
--- a/arch/riscv/cpu/jh7110/dram.c
+++ b/arch/riscv/cpu/jh7110/dram.c
@@ -4,7 +4,6 @@
* Author: Yanhong Wang <yanhong.wang@starfivetech.com>
*/
-#include <common.h>
#include <fdtdec.h>
#include <init.h>
#include <linux/sizes.h>
diff --git a/arch/riscv/cpu/jh7110/spl.c b/arch/riscv/cpu/jh7110/spl.c
index 4047b10efe83..6bdf8b9c72f0 100644
--- a/arch/riscv/cpu/jh7110/spl.c
+++ b/arch/riscv/cpu/jh7110/spl.c
@@ -3,7 +3,6 @@
* Copyright (C) 2022 StarFive Technology Co., Ltd.
* Author: Yanhong Wang<yanhong.wang@starfivetech.com>
*/
-#include <common.h>
#include <asm/arch/eeprom.h>
#include <asm/csr.h>
#include <asm/sections.h>
diff --git a/arch/riscv/cpu/mtrap.S b/arch/riscv/cpu/mtrap.S
index e40c7bd3f4ff..6eb3ed1d5a88 100644
--- a/arch/riscv/cpu/mtrap.S
+++ b/arch/riscv/cpu/mtrap.S
@@ -11,7 +11,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <asm/encoding.h>
#ifdef CONFIG_32BIT
diff --git a/arch/riscv/cpu/start.S b/arch/riscv/cpu/start.S
index 30cf6743701b..6cecadfac56d 100644
--- a/arch/riscv/cpu/start.S
+++ b/arch/riscv/cpu/start.S
@@ -11,7 +11,6 @@
#include <asm-offsets.h>
#include <config.h>
-#include <common.h>
#include <elf.h>
#include <system-constants.h>
#include <asm/encoding.h>
diff --git a/arch/riscv/include/asm/arch-andes/csr.h b/arch/riscv/include/asm/arch-andes/csr.h
index c7ed920cde57..393d51c6dde1 100644
--- a/arch/riscv/include/asm/arch-andes/csr.h
+++ b/arch/riscv/include/asm/arch-andes/csr.h
@@ -7,6 +7,7 @@
#define _ASM_ANDES_CSR_H
#include <asm/asm.h>
+#include <linux/bitops.h>
#include <linux/const.h>
#define CSR_MCACHE_CTL 0x7ca
diff --git a/arch/riscv/include/asm/arch-jh7110/eeprom.h b/arch/riscv/include/asm/arch-jh7110/eeprom.h
index f354d5c60cdc..d2776d5b6cb3 100644
--- a/arch/riscv/include/asm/arch-jh7110/eeprom.h
+++ b/arch/riscv/include/asm/arch-jh7110/eeprom.h
@@ -7,6 +7,8 @@
#ifndef _ASM_RISCV_EEPROM_H
#define _ASM_RISCV_EEPROM_H
+#include <linux/types.h>
+
u8 get_pcb_revision_from_eeprom(void);
u32 get_ddr_size_from_eeprom(void);
diff --git a/arch/riscv/include/asm/dma-mapping.h b/arch/riscv/include/asm/dma-mapping.h
index 6ecadab41cd9..d0cc5d7c7757 100644
--- a/arch/riscv/include/asm/dma-mapping.h
+++ b/arch/riscv/include/asm/dma-mapping.h
@@ -9,7 +9,6 @@
#ifndef __ASM_RISCV_DMA_MAPPING_H
#define __ASM_RISCV_DMA_MAPPING_H
-#include <common.h>
#include <linux/types.h>
#include <asm/cache.h>
#include <cpu_func.h>
diff --git a/arch/riscv/include/asm/smp.h b/arch/riscv/include/asm/smp.h
index 4284a332e98f..ee749dd11954 100644
--- a/arch/riscv/include/asm/smp.h
+++ b/arch/riscv/include/asm/smp.h
@@ -7,6 +7,8 @@
#ifndef _ASM_RISCV_SMP_H
#define _ASM_RISCV_SMP_H
+#include <linux/types.h>
+
/**
* struct ipi_data - Inter-processor interrupt (IPI) data structure
*
diff --git a/arch/riscv/lib/aclint_ipi.c b/arch/riscv/lib/aclint_ipi.c
index 90b8e128cb16..dcd7e5e6b344 100644
--- a/arch/riscv/lib/aclint_ipi.c
+++ b/arch/riscv/lib/aclint_ipi.c
@@ -8,7 +8,6 @@
* associated with software and timer interrupts.
*/
-#include <common.h>
#include <dm.h>
#include <regmap.h>
#include <syscon.h>
diff --git a/arch/riscv/lib/andes_plicsw.c b/arch/riscv/lib/andes_plicsw.c
index 75184080890f..c188bfffc7c2 100644
--- a/arch/riscv/lib/andes_plicsw.c
+++ b/arch/riscv/lib/andes_plicsw.c
@@ -8,7 +8,6 @@
* similar to RISC-V PLIC.
*/
-#include <common.h>
#include <dm.h>
#include <asm/global_data.h>
#include <dm/device-internal.h>
diff --git a/arch/riscv/lib/asm-offsets.c b/arch/riscv/lib/asm-offsets.c
index 452dfcea97f7..875bb9a6d983 100644
--- a/arch/riscv/lib/asm-offsets.c
+++ b/arch/riscv/lib/asm-offsets.c
@@ -8,7 +8,6 @@
* assembly language modules.
*/
-#include <common.h>
#include <asm/global_data.h>
#include <linux/kbuild.h>
diff --git a/arch/riscv/lib/boot.c b/arch/riscv/lib/boot.c
index 778d011f7cea..03014c56dce2 100644
--- a/arch/riscv/lib/boot.c
+++ b/arch/riscv/lib/boot.c
@@ -4,8 +4,7 @@
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
*/
-#include <common.h>
-#include <command.h>
+#include <asm/u-boot.h>
unsigned long do_go_exec(ulong (*entry)(int, char * const []),
int argc, char *const argv[])
diff --git a/arch/riscv/lib/bootm.c b/arch/riscv/lib/bootm.c
index cc30efc90498..f9e1e18ae026 100644
--- a/arch/riscv/lib/bootm.c
+++ b/arch/riscv/lib/bootm.c
@@ -6,7 +6,6 @@
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
*/
-#include <common.h>
#include <bootstage.h>
#include <command.h>
#include <dm.h>
diff --git a/arch/riscv/lib/cache.c b/arch/riscv/lib/cache.c
index 686e699efbcd..c46b49eb0ac6 100644
--- a/arch/riscv/lib/cache.c
+++ b/arch/riscv/lib/cache.c
@@ -4,7 +4,6 @@
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
*/
-#include <common.h>
#include <cpu_func.h>
void invalidate_icache_all(void)
diff --git a/arch/riscv/lib/fdt_fixup.c b/arch/riscv/lib/fdt_fixup.c
index 36c16e9be2ae..c658e72bd39e 100644
--- a/arch/riscv/lib/fdt_fixup.c
+++ b/arch/riscv/lib/fdt_fixup.c
@@ -6,7 +6,6 @@
#define LOG_CATEGORY LOGC_ARCH
-#include <common.h>
#include <fdt_support.h>
#include <log.h>
#include <mapmem.h>
diff --git a/arch/riscv/lib/image.c b/arch/riscv/lib/image.c
index a65a5b8d17c1..a82f48e9a505 100644
--- a/arch/riscv/lib/image.c
+++ b/arch/riscv/lib/image.c
@@ -6,7 +6,6 @@
* Based on arm/lib/image.c
*/
-#include <common.h>
#include <image.h>
#include <mapmem.h>
#include <errno.h>
diff --git a/arch/riscv/lib/interrupts.c b/arch/riscv/lib/interrupts.c
index e966afa7e3e3..02dbcfd42380 100644
--- a/arch/riscv/lib/interrupts.c
+++ b/arch/riscv/lib/interrupts.c
@@ -10,7 +10,6 @@
*/
#include <linux/compat.h>
-#include <common.h>
#include <efi_loader.h>
#include <hang.h>
#include <irq_func.h>
diff --git a/arch/riscv/lib/reset.c b/arch/riscv/lib/reset.c
index 8779c619cc5a..712e1bdb8e1d 100644
--- a/arch/riscv/lib/reset.c
+++ b/arch/riscv/lib/reset.c
@@ -3,7 +3,6 @@
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
*/
-#include <common.h>
#include <command.h>
#include <hang.h>
diff --git a/arch/riscv/lib/sbi.c b/arch/riscv/lib/sbi.c
index 55a3bc3b5c9d..35a7d3b12f51 100644
--- a/arch/riscv/lib/sbi.c
+++ b/arch/riscv/lib/sbi.c
@@ -7,7 +7,7 @@
* Taken from Linux arch/riscv/kernel/sbi.c
*/
-#include <common.h>
+#include <errno.h>
#include <asm/encoding.h>
#include <asm/sbi.h>
diff --git a/arch/riscv/lib/sbi_ipi.c b/arch/riscv/lib/sbi_ipi.c
index d02e2b4c4882..511d3816da84 100644
--- a/arch/riscv/lib/sbi_ipi.c
+++ b/arch/riscv/lib/sbi_ipi.c
@@ -4,7 +4,6 @@
* Lukas Auer <lukas.auer@aisec.fraunhofer.de>
*/
-#include <common.h>
#include <asm/encoding.h>
#include <asm/sbi.h>
diff --git a/arch/riscv/lib/sifive_cache.c b/arch/riscv/lib/sifive_cache.c
index 28154878fcc8..39b0248c3234 100644
--- a/arch/riscv/lib/sifive_cache.c
+++ b/arch/riscv/lib/sifive_cache.c
@@ -3,9 +3,9 @@
* Copyright (C) 2021 SiFive, Inc
*/
-#include <common.h>
#include <cache.h>
#include <cpu_func.h>
+#include <log.h>
#include <dm.h>
void enable_caches(void)
diff --git a/arch/riscv/lib/smp.c b/arch/riscv/lib/smp.c
index f3cd8b9044a8..a692f065edd7 100644
--- a/arch/riscv/lib/smp.c
+++ b/arch/riscv/lib/smp.c
@@ -4,7 +4,6 @@
* Lukas Auer <lukas.auer@aisec.fraunhofer.de>
*/
-#include <common.h>
#include <cpu_func.h>
#include <dm.h>
#include <asm/barrier.h>
diff --git a/arch/riscv/lib/spl.c b/arch/riscv/lib/spl.c
index 9b242ed82129..9a7a4f6ac8d3 100644
--- a/arch/riscv/lib/spl.c
+++ b/arch/riscv/lib/spl.c
@@ -3,7 +3,6 @@
* Copyright (C) 2019 Fraunhofer AISEC,
* Lukas Auer <lukas.auer@aisec.fraunhofer.de>
*/
-#include <common.h>
#include <cpu_func.h>
#include <hang.h>
#include <init.h>
diff --git a/board/AndesTech/ae350/ae350.c b/board/AndesTech/ae350/ae350.c
index 1c2288b6ce9f..36375d9def99 100644
--- a/board/AndesTech/ae350/ae350.c
+++ b/board/AndesTech/ae350/ae350.c
@@ -4,7 +4,7 @@
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
*/
-#include <common.h>
+#include <config.h>
#include <cpu_func.h>
#include <flash.h>
#include <image.h>
diff --git a/board/sifive/unmatched/hifive-platform-i2c-eeprom.c b/board/sifive/unmatched/hifive-platform-i2c-eeprom.c
index 2b985b9b228e..938cedea6481 100644
--- a/board/sifive/unmatched/hifive-platform-i2c-eeprom.c
+++ b/board/sifive/unmatched/hifive-platform-i2c-eeprom.c
@@ -9,7 +9,6 @@
* Timur Tabi (timur@freescale.com)
*/
-#include <common.h>
#include <command.h>
#include <env.h>
#include <i2c.h>
diff --git a/board/sifive/unmatched/unmatched.c b/board/sifive/unmatched/unmatched.c
index 6675548c2bf8..c8696270ba27 100644
--- a/board/sifive/unmatched/unmatched.c
+++ b/board/sifive/unmatched/unmatched.c
@@ -6,7 +6,6 @@
* Pragnesh Patel <pragnesh.patel@sifive.com>
*/
-#include <common.h>
#include <cpu_func.h>
#include <dm.h>
#include <asm/sections.h>
--
2.34.1
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 5/7] microblaze: Remove common.h usage
2023-10-12 23:03 ` [PATCH 5/7] microblaze: " Tom Rini
@ 2023-10-13 7:11 ` Michal Simek
2023-10-24 23:16 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Michal Simek @ 2023-10-13 7:11 UTC (permalink / raw)
To: Tom Rini, u-boot
On 10/13/23 01:03, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Michal Simek <michal.simek@amd.com>
> ---
> arch/microblaze/cpu/cache.c | 1 -
> arch/microblaze/cpu/cpuinfo.c | 1 -
> arch/microblaze/cpu/exception.c | 2 +-
> arch/microblaze/cpu/interrupts.c | 3 ++-
> arch/microblaze/cpu/pvr.c | 1 -
> arch/microblaze/cpu/relocate.c | 3 ++-
> arch/microblaze/cpu/spl.c | 1 -
> arch/microblaze/include/asm/cpuinfo.h | 2 ++
> arch/microblaze/lib/bootm.c | 1 -
> board/xilinx/microblaze-generic/microblaze-generic.c | 1 -
> 10 files changed, 7 insertions(+), 9 deletions(-)
>
> diff --git a/arch/microblaze/cpu/cache.c b/arch/microblaze/cpu/cache.c
> index 829e6c7ae605..75ec0a8fd24f 100644
> --- a/arch/microblaze/cpu/cache.c
> +++ b/arch/microblaze/cpu/cache.c
> @@ -5,7 +5,6 @@
> * Michal SIMEK <monstr@monstr.eu>
> */
>
> -#include <common.h>
> #include <cpu_func.h>
> #include <asm/asm.h>
> #include <asm/cache.h>
> diff --git a/arch/microblaze/cpu/cpuinfo.c b/arch/microblaze/cpu/cpuinfo.c
> index 6b15d6ca41c0..2bfdf767f3a5 100644
> --- a/arch/microblaze/cpu/cpuinfo.c
> +++ b/arch/microblaze/cpu/cpuinfo.c
> @@ -2,7 +2,6 @@
> /*
> * Copyright (C) 2022, Ovidiu Panait <ovpanait@gmail.com>
> */
> -#include <common.h>
> #include <asm/cpuinfo.h>
> #include <asm/global_data.h>
>
> diff --git a/arch/microblaze/cpu/exception.c b/arch/microblaze/cpu/exception.c
> index 9414776afa7f..6b329fc7b3a2 100644
> --- a/arch/microblaze/cpu/exception.c
> +++ b/arch/microblaze/cpu/exception.c
> @@ -5,8 +5,8 @@
> * Michal SIMEK <monstr@monstr.eu>
> */
>
> -#include <common.h>
> #include <hang.h>
> +#include <stdio.h>
> #include <asm/asm.h>
>
> void _hw_exception_handler (void)
> diff --git a/arch/microblaze/cpu/interrupts.c b/arch/microblaze/cpu/interrupts.c
> index ac53208bda67..244f7fd15eba 100644
> --- a/arch/microblaze/cpu/interrupts.c
> +++ b/arch/microblaze/cpu/interrupts.c
> @@ -7,7 +7,8 @@
> * Yasushi SHOJI <yashi@atmark-techno.com>
> */
>
> -#include <common.h>
> +#include <log.h>
> +#include <vsprintf.h>
> #include <asm/asm.h>
>
> void enable_interrupts(void)
> diff --git a/arch/microblaze/cpu/pvr.c b/arch/microblaze/cpu/pvr.c
> index 23c0f912d435..71aea0b9380c 100644
> --- a/arch/microblaze/cpu/pvr.c
> +++ b/arch/microblaze/cpu/pvr.c
> @@ -2,7 +2,6 @@
> /*
> * Copyright (C) 2022, Ovidiu Panait <ovpanait@gmail.com>
> */
> -#include <common.h>
> #include <asm/asm.h>
> #include <asm/pvr.h>
>
> diff --git a/arch/microblaze/cpu/relocate.c b/arch/microblaze/cpu/relocate.c
> index 7a15fb2ec397..e46fe5bdd5d7 100644
> --- a/arch/microblaze/cpu/relocate.c
> +++ b/arch/microblaze/cpu/relocate.c
> @@ -4,8 +4,9 @@
> * Michal Simek <michal.simek@amd.com>
> */
>
> -#include <common.h>
> #include <elf.h>
> +#include <log.h>
> +#include <linux/types.h>
>
> #define R_MICROBLAZE_NONE 0
> #define R_MICROBLAZE_32 1
> diff --git a/arch/microblaze/cpu/spl.c b/arch/microblaze/cpu/spl.c
> index c21beafdb810..cb224bd25423 100644
> --- a/arch/microblaze/cpu/spl.c
> +++ b/arch/microblaze/cpu/spl.c
> @@ -5,7 +5,6 @@
> * Michal Simek <michal.simek@amd.com>
> */
>
> -#include <common.h>
> #include <command.h>
> #include <image.h>
> #include <log.h>
> diff --git a/arch/microblaze/include/asm/cpuinfo.h b/arch/microblaze/include/asm/cpuinfo.h
> index 3c58e52217c4..fbd9418a2f8b 100644
> --- a/arch/microblaze/include/asm/cpuinfo.h
> +++ b/arch/microblaze/include/asm/cpuinfo.h
> @@ -6,6 +6,8 @@
> #ifndef __ASM_MICROBLAZE_CPUINFO_H
> #define __ASM_MICROBLAZE_CPUINFO_H
>
> +#include <linux/types.h>
> +
> /**
> * struct microblaze_cpuinfo - CPU info for microblaze processor core.
> *
> diff --git a/arch/microblaze/lib/bootm.c b/arch/microblaze/lib/bootm.c
> index 930384f4015f..f3ec4b741b88 100644
> --- a/arch/microblaze/lib/bootm.c
> +++ b/arch/microblaze/lib/bootm.c
> @@ -7,7 +7,6 @@
> * Yasushi SHOJI <yashi@atmark-techno.com>
> */
>
> -#include <common.h>
> #include <bootstage.h>
> #include <command.h>
> #include <cpu_func.h>
> diff --git a/board/xilinx/microblaze-generic/microblaze-generic.c b/board/xilinx/microblaze-generic/microblaze-generic.c
> index a427ac94a170..2b035d535892 100644
> --- a/board/xilinx/microblaze-generic/microblaze-generic.c
> +++ b/board/xilinx/microblaze-generic/microblaze-generic.c
> @@ -10,7 +10,6 @@
> * header files
> */
>
> -#include <common.h>
> #include <config.h>
> #include <env.h>
> #include <init.h>
I build it and no problem seen that's why.
Acked-by: Michal Simek <michal.simek@amd.com>
If you want me to take it via my tree please let me know but I expect you will
take it directly.
Thanks,
Michal
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 7/7] riscv: Remove common.h usage
[not found] ` <SEZPR03MB8064C345D63766D2E86B2184C1D2A@SEZPR03MB8064.apcprd03.prod.outlook.com>
@ 2023-10-13 8:52 ` Rick Chen
0 siblings, 0 replies; 26+ messages in thread
From: Rick Chen @ 2023-10-13 8:52 UTC (permalink / raw)
To: Tom Rini, U-Boot Mailing List; +Cc: rick, Leo Liang
> From: Tom Rini <trini@konsulko.com>
> Sent: Friday, October 13, 2023 7:04 AM
> To: u-boot@lists.denx.de
> Cc: Rick Jian-Zhi Chen(陳建志) <rick@andestech.com>; Leo Yu-Chi Liang(梁育齊) <ycliang@andestech.com>
> Subject: [PATCH 7/7] riscv: Remove common.h usage
>
> We can remove common.h from most cases of the code here, and only a few places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Rick Chen <rick@andestech.com>
> Cc: Leo <ycliang@andestech.com>
> ---
Reviewed-by: Rick Chen <rick@andestech.com>
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 3/7] arc: Remove common.h usage
2023-10-12 23:03 ` [PATCH 3/7] arc: Remove common.h usage Tom Rini
@ 2023-10-13 9:21 ` Alexey Brodkin
2023-10-24 23:15 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Alexey Brodkin @ 2023-10-13 9:21 UTC (permalink / raw)
To: Tom Rini; +Cc: Eugeniy Paltsev, uboot-snps-arc@synopsys.com,
u-boot@lists.denx.de
Hi Tom,
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Alexey Brodkin <alexey.brodkin@synopsys.com>
> Cc: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
> Cc: uboot-snps-arc@synopsys.com
> ---
> arch/arc/lib/bootm.c | 1 -
> arch/arc/lib/cache.c | 1 -
> arch/arc/lib/cpu.c | 1 -
> arch/arc/lib/init_helpers.c | 1 -
> arch/arc/lib/interrupts.c | 2 +-
> arch/arc/lib/relocate.c | 1 -
> arch/arc/lib/reset.c | 1 -
> board/abilis/tb100/tb100.c | 1 -
> board/synopsys/axs10x/axs10x.c | 1 -
> board/synopsys/emsdp/emsdp.c | 1 -
> board/synopsys/hsdk/clk-lib.h | 1 -
> board/synopsys/hsdk/env-lib.c | 2 ++
> board/synopsys/hsdk/env-lib.h | 1 -
> board/synopsys/hsdk/hsdk.c | 1 -
> board/synopsys/iot_devkit/iot_devkit.c | 1 -
> board/synopsys/nsim/nsim.c | 1 -
> 16 files changed, 3 insertions(+), 15 deletions(-)
Thanks for the improvement!
Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
@ 2023-10-13 15:14 ` Simon Glass
2023-10-13 15:17 ` Tom Rini
2023-10-13 20:53 ` Angelo Dureghello
2023-10-24 23:16 ` Tom Rini
2 siblings, 1 reply; 26+ messages in thread
From: Simon Glass @ 2023-10-13 15:14 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Angelo Dureghello
Hi Tom,
On Thu, 12 Oct 2023 at 16:11, Tom Rini <trini@konsulko.com> wrote:
>
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Angelo Dureghello <angelo@kernel-space.org>
> ---
> arch/m68k/cpu/mcf523x/cpu.c | 1 -
> arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf523x/interrupts.c | 1 -
> arch/m68k/cpu/mcf523x/speed.c | 1 -
> arch/m68k/cpu/mcf52x2/cpu.c | 1 -
> arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
> arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
> arch/m68k/cpu/mcf52x2/speed.c | 1 -
> arch/m68k/cpu/mcf530x/cpu.c | 1 -
> arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf530x/interrupts.c | 1 -
> arch/m68k/cpu/mcf530x/speed.c | 1 -
> arch/m68k/cpu/mcf532x/cpu.c | 1 -
> arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf532x/interrupts.c | 1 -
> arch/m68k/cpu/mcf532x/speed.c | 1 -
> arch/m68k/cpu/mcf5445x/cpu.c | 1 -
> arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf5445x/dspi.c | 1 -
> arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
> arch/m68k/cpu/mcf5445x/speed.c | 1 -
> arch/m68k/cpu/mcf5445x/start.S | 1 -
> arch/m68k/include/asm/immap.h | 1 +
> arch/m68k/include/asm/immap_520x.h | 1 +
> arch/m68k/include/asm/immap_5235.h | 1 +
> arch/m68k/include/asm/immap_5272.h | 1 +
> arch/m68k/include/asm/immap_5275.h | 1 +
> arch/m68k/include/asm/immap_5282.h | 1 +
> arch/m68k/include/asm/immap_5301x.h | 1 +
> arch/m68k/include/asm/immap_5307.h | 2 ++
> arch/m68k/include/asm/immap_5329.h | 1 +
> arch/m68k/include/asm/immap_5441x.h | 1 +
> arch/m68k/lib/bdinfo.c | 3 ++-
> arch/m68k/lib/bootm.c | 1 -
> arch/m68k/lib/cache.c | 2 +-
> arch/m68k/lib/fec.c | 2 +-
> arch/m68k/lib/interrupts.c | 2 +-
> arch/m68k/lib/time.c | 1 -
> arch/m68k/lib/traps.c | 1 -
> 39 files changed, 17 insertions(+), 30 deletions(-)
I just wondered what we do about '#ifdef CFG_...' which presumably is
not included without common.h ? How does that work?
Regards,
Simon
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 2/7] include: Add <linux/types.h> in a few places
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
@ 2023-10-13 15:14 ` Simon Glass
2023-10-24 23:15 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Simon Glass @ 2023-10-13 15:14 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot
On Thu, 12 Oct 2023 at 16:04, Tom Rini <trini@konsulko.com> wrote:
>
> These files references a number of types that are defined in
> <linux/types.h> (and so forth), so include it here rather than rely on
> indirect inclusion.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Simon Glass <sjg@chromium.org>
> ---
> include/bootstage.h | 1 +
> include/cache.h | 2 ++
> include/cpu.h | 2 ++
> 3 files changed, 5 insertions(+)
>
Reviewed-by: Simon Glass <sjg@chromium.org>
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 1/7] checkpatch.pl: Make common.h check boarder
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
` (5 preceding siblings ...)
2023-10-12 23:03 ` [PATCH 7/7] riscv: " Tom Rini
@ 2023-10-13 15:15 ` Simon Glass
2023-10-13 15:16 ` Tom Rini
6 siblings, 1 reply; 26+ messages in thread
From: Simon Glass @ 2023-10-13 15:15 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot
On Thu, 12 Oct 2023 at 16:04, Tom Rini <trini@konsulko.com> wrote:
>
> At this point in time we should not add common.h to any new files, so
> make checkpatch.pl complain.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Simon Glass <sjg@chromium.org>
>
> This causes a bunch of patman tests, for checkpatch, to now fail and I
> don't really understand why, at all. And that was before I added a test
> for the new error, which I had hoped would clear up the problem.
> ---
> scripts/checkpatch.pl | 8 +++++++-
> tools/patman/test_checkpatch.py | 7 ++++++-
> 2 files changed, 13 insertions(+), 2 deletions(-)
Reviewed-by: Simon Glass <sjg@chromium.org>
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 1/7] checkpatch.pl: Make common.h check boarder
2023-10-13 15:15 ` [PATCH 1/7] checkpatch.pl: Make common.h check boarder Simon Glass
@ 2023-10-13 15:16 ` Tom Rini
2023-10-13 15:49 ` Simon Glass
0 siblings, 1 reply; 26+ messages in thread
From: Tom Rini @ 2023-10-13 15:16 UTC (permalink / raw)
To: Simon Glass; +Cc: u-boot
[-- Attachment #1: Type: text/plain, Size: 936 bytes --]
On Fri, Oct 13, 2023 at 08:15:00AM -0700, Simon Glass wrote:
> On Thu, 12 Oct 2023 at 16:04, Tom Rini <trini@konsulko.com> wrote:
> >
> > At this point in time we should not add common.h to any new files, so
> > make checkpatch.pl complain.
> >
> > Signed-off-by: Tom Rini <trini@konsulko.com>
> > ---
> > Cc: Simon Glass <sjg@chromium.org>
> >
> > This causes a bunch of patman tests, for checkpatch, to now fail and I
> > don't really understand why, at all. And that was before I added a test
> > for the new error, which I had hoped would clear up the problem.
> > ---
> > scripts/checkpatch.pl | 8 +++++++-
> > tools/patman/test_checkpatch.py | 7 ++++++-
> > 2 files changed, 13 insertions(+), 2 deletions(-)
>
> Reviewed-by: Simon Glass <sjg@chromium.org>
It can't be reviewed, as I can't actually apply it, as it causes CI to
fail as patman tests now fail, and I don't know why.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-13 15:14 ` Simon Glass
@ 2023-10-13 15:17 ` Tom Rini
2023-10-13 16:57 ` Simon Glass
0 siblings, 1 reply; 26+ messages in thread
From: Tom Rini @ 2023-10-13 15:17 UTC (permalink / raw)
To: Simon Glass; +Cc: u-boot, Angelo Dureghello
[-- Attachment #1: Type: text/plain, Size: 2572 bytes --]
On Fri, Oct 13, 2023 at 08:14:57AM -0700, Simon Glass wrote:
> Hi Tom,
>
> On Thu, 12 Oct 2023 at 16:11, Tom Rini <trini@konsulko.com> wrote:
> >
> > We can remove common.h from most cases of the code here, and only a few
> > places need an additional header instead.
> >
> > Signed-off-by: Tom Rini <trini@konsulko.com>
> > ---
> > Cc: Angelo Dureghello <angelo@kernel-space.org>
> > ---
> > arch/m68k/cpu/mcf523x/cpu.c | 1 -
> > arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf523x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf523x/speed.c | 1 -
> > arch/m68k/cpu/mcf52x2/cpu.c | 1 -
> > arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
> > arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
> > arch/m68k/cpu/mcf52x2/speed.c | 1 -
> > arch/m68k/cpu/mcf530x/cpu.c | 1 -
> > arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf530x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf530x/speed.c | 1 -
> > arch/m68k/cpu/mcf532x/cpu.c | 1 -
> > arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf532x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf532x/speed.c | 1 -
> > arch/m68k/cpu/mcf5445x/cpu.c | 1 -
> > arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf5445x/dspi.c | 1 -
> > arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf5445x/speed.c | 1 -
> > arch/m68k/cpu/mcf5445x/start.S | 1 -
> > arch/m68k/include/asm/immap.h | 1 +
> > arch/m68k/include/asm/immap_520x.h | 1 +
> > arch/m68k/include/asm/immap_5235.h | 1 +
> > arch/m68k/include/asm/immap_5272.h | 1 +
> > arch/m68k/include/asm/immap_5275.h | 1 +
> > arch/m68k/include/asm/immap_5282.h | 1 +
> > arch/m68k/include/asm/immap_5301x.h | 1 +
> > arch/m68k/include/asm/immap_5307.h | 2 ++
> > arch/m68k/include/asm/immap_5329.h | 1 +
> > arch/m68k/include/asm/immap_5441x.h | 1 +
> > arch/m68k/lib/bdinfo.c | 3 ++-
> > arch/m68k/lib/bootm.c | 1 -
> > arch/m68k/lib/cache.c | 2 +-
> > arch/m68k/lib/fec.c | 2 +-
> > arch/m68k/lib/interrupts.c | 2 +-
> > arch/m68k/lib/time.c | 1 -
> > arch/m68k/lib/traps.c | 1 -
> > 39 files changed, 17 insertions(+), 30 deletions(-)
>
> I just wondered what we do about '#ifdef CFG_...' which presumably is
> not included without common.h ? How does that work?
The first header in common.h is config.h which is where many CFG_...
instances are.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 1/7] checkpatch.pl: Make common.h check boarder
2023-10-13 15:16 ` Tom Rini
@ 2023-10-13 15:49 ` Simon Glass
0 siblings, 0 replies; 26+ messages in thread
From: Simon Glass @ 2023-10-13 15:49 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot
Hi Tom,
On Fri, 13 Oct 2023 at 08:16, Tom Rini <trini@konsulko.com> wrote:
>
> On Fri, Oct 13, 2023 at 08:15:00AM -0700, Simon Glass wrote:
> > On Thu, 12 Oct 2023 at 16:04, Tom Rini <trini@konsulko.com> wrote:
> > >
> > > At this point in time we should not add common.h to any new files, so
> > > make checkpatch.pl complain.
> > >
> > > Signed-off-by: Tom Rini <trini@konsulko.com>
> > > ---
> > > Cc: Simon Glass <sjg@chromium.org>
> > >
> > > This causes a bunch of patman tests, for checkpatch, to now fail and I
> > > don't really understand why, at all. And that was before I added a test
> > > for the new error, which I had hoped would clear up the problem.
> > > ---
> > > scripts/checkpatch.pl | 8 +++++++-
> > > tools/patman/test_checkpatch.py | 7 ++++++-
> > > 2 files changed, 13 insertions(+), 2 deletions(-)
> >
> > Reviewed-by: Simon Glass <sjg@chromium.org>
>
> It can't be reviewed, as I can't actually apply it, as it causes CI to
> fail as patman tests now fail, and I don't know why.
Well the code looks OK to me. I will take a look.
Regards,
Simon
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-13 15:17 ` Tom Rini
@ 2023-10-13 16:57 ` Simon Glass
0 siblings, 0 replies; 26+ messages in thread
From: Simon Glass @ 2023-10-13 16:57 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Angelo Dureghello
Hi Tom,
On Fri, 13 Oct 2023 at 08:17, Tom Rini <trini@konsulko.com> wrote:
>
> On Fri, Oct 13, 2023 at 08:14:57AM -0700, Simon Glass wrote:
> > Hi Tom,
> >
> > On Thu, 12 Oct 2023 at 16:11, Tom Rini <trini@konsulko.com> wrote:
> > >
> > > We can remove common.h from most cases of the code here, and only a few
> > > places need an additional header instead.
> > >
> > > Signed-off-by: Tom Rini <trini@konsulko.com>
> > > ---
> > > Cc: Angelo Dureghello <angelo@kernel-space.org>
> > > ---
> > > arch/m68k/cpu/mcf523x/cpu.c | 1 -
> > > arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
> > > arch/m68k/cpu/mcf523x/interrupts.c | 1 -
> > > arch/m68k/cpu/mcf523x/speed.c | 1 -
> > > arch/m68k/cpu/mcf52x2/cpu.c | 1 -
> > > arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
> > > arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
> > > arch/m68k/cpu/mcf52x2/speed.c | 1 -
> > > arch/m68k/cpu/mcf530x/cpu.c | 1 -
> > > arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
> > > arch/m68k/cpu/mcf530x/interrupts.c | 1 -
> > > arch/m68k/cpu/mcf530x/speed.c | 1 -
> > > arch/m68k/cpu/mcf532x/cpu.c | 1 -
> > > arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
> > > arch/m68k/cpu/mcf532x/interrupts.c | 1 -
> > > arch/m68k/cpu/mcf532x/speed.c | 1 -
> > > arch/m68k/cpu/mcf5445x/cpu.c | 1 -
> > > arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
> > > arch/m68k/cpu/mcf5445x/dspi.c | 1 -
> > > arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
> > > arch/m68k/cpu/mcf5445x/speed.c | 1 -
> > > arch/m68k/cpu/mcf5445x/start.S | 1 -
> > > arch/m68k/include/asm/immap.h | 1 +
> > > arch/m68k/include/asm/immap_520x.h | 1 +
> > > arch/m68k/include/asm/immap_5235.h | 1 +
> > > arch/m68k/include/asm/immap_5272.h | 1 +
> > > arch/m68k/include/asm/immap_5275.h | 1 +
> > > arch/m68k/include/asm/immap_5282.h | 1 +
> > > arch/m68k/include/asm/immap_5301x.h | 1 +
> > > arch/m68k/include/asm/immap_5307.h | 2 ++
> > > arch/m68k/include/asm/immap_5329.h | 1 +
> > > arch/m68k/include/asm/immap_5441x.h | 1 +
> > > arch/m68k/lib/bdinfo.c | 3 ++-
> > > arch/m68k/lib/bootm.c | 1 -
> > > arch/m68k/lib/cache.c | 2 +-
> > > arch/m68k/lib/fec.c | 2 +-
> > > arch/m68k/lib/interrupts.c | 2 +-
> > > arch/m68k/lib/time.c | 1 -
> > > arch/m68k/lib/traps.c | 1 -
> > > 39 files changed, 17 insertions(+), 30 deletions(-)
> >
> > I just wondered what we do about '#ifdef CFG_...' which presumably is
> > not included without common.h ? How does that work?
>
> The first header in common.h is config.h which is where many CFG_...
> instances are.
OK, so that comes later...
Regards,
Simon
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
2023-10-13 15:14 ` Simon Glass
@ 2023-10-13 20:53 ` Angelo Dureghello
2023-10-13 20:55 ` Tom Rini
2023-10-24 23:16 ` Tom Rini
2 siblings, 1 reply; 26+ messages in thread
From: Angelo Dureghello @ 2023-10-13 20:53 UTC (permalink / raw)
To: Tom Rini, u-boot
Hi Tom,
On 13/10/23 1:03 AM, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> ---
> Cc: Angelo Dureghello <angelo@kernel-space.org>
> ---
> arch/m68k/cpu/mcf523x/cpu.c | 1 -
> arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf523x/interrupts.c | 1 -
> arch/m68k/cpu/mcf523x/speed.c | 1 -
> arch/m68k/cpu/mcf52x2/cpu.c | 1 -
> arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
> arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
> arch/m68k/cpu/mcf52x2/speed.c | 1 -
> arch/m68k/cpu/mcf530x/cpu.c | 1 -
> arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf530x/interrupts.c | 1 -
> arch/m68k/cpu/mcf530x/speed.c | 1 -
> arch/m68k/cpu/mcf532x/cpu.c | 1 -
> arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf532x/interrupts.c | 1 -
> arch/m68k/cpu/mcf532x/speed.c | 1 -
> arch/m68k/cpu/mcf5445x/cpu.c | 1 -
> arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
> arch/m68k/cpu/mcf5445x/dspi.c | 1 -
> arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
> arch/m68k/cpu/mcf5445x/speed.c | 1 -
> arch/m68k/cpu/mcf5445x/start.S | 1 -
> arch/m68k/include/asm/immap.h | 1 +
> arch/m68k/include/asm/immap_520x.h | 1 +
> arch/m68k/include/asm/immap_5235.h | 1 +
> arch/m68k/include/asm/immap_5272.h | 1 +
> arch/m68k/include/asm/immap_5275.h | 1 +
> arch/m68k/include/asm/immap_5282.h | 1 +
> arch/m68k/include/asm/immap_5301x.h | 1 +
> arch/m68k/include/asm/immap_5307.h | 2 ++
> arch/m68k/include/asm/immap_5329.h | 1 +
> arch/m68k/include/asm/immap_5441x.h | 1 +
> arch/m68k/lib/bdinfo.c | 3 ++-
> arch/m68k/lib/bootm.c | 1 -
> arch/m68k/lib/cache.c | 2 +-
> arch/m68k/lib/fec.c | 2 +-
> arch/m68k/lib/interrupts.c | 2 +-
> arch/m68k/lib/time.c | 1 -
> arch/m68k/lib/traps.c | 1 -
> 39 files changed, 17 insertions(+), 30 deletions(-)
>
building for mcf5307 i get this error
In file included from arch/m68k/lib/bootm.c:7:
include/bootstage.h:225:1: error: unknown type name 'ulong'; did you
mean 'long'?
225 | ulong timer_get_boot_us(void);
| ^~~~~
regards,
--
Angelo Dureghello
w: www.kernel-space.org
e: angelo@kernel-space.org
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-13 20:53 ` Angelo Dureghello
@ 2023-10-13 20:55 ` Tom Rini
2023-10-13 21:40 ` Angelo Dureghello
0 siblings, 1 reply; 26+ messages in thread
From: Tom Rini @ 2023-10-13 20:55 UTC (permalink / raw)
To: Angelo Dureghello; +Cc: u-boot
[-- Attachment #1: Type: text/plain, Size: 2703 bytes --]
On Fri, Oct 13, 2023 at 10:53:04PM +0200, Angelo Dureghello wrote:
> Hi Tom,
>
>
> On 13/10/23 1:03 AM, Tom Rini wrote:
> > We can remove common.h from most cases of the code here, and only a few
> > places need an additional header instead.
> >
> > Signed-off-by: Tom Rini <trini@konsulko.com>
> > ---
> > Cc: Angelo Dureghello <angelo@kernel-space.org>
> > ---
> > arch/m68k/cpu/mcf523x/cpu.c | 1 -
> > arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf523x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf523x/speed.c | 1 -
> > arch/m68k/cpu/mcf52x2/cpu.c | 1 -
> > arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
> > arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
> > arch/m68k/cpu/mcf52x2/speed.c | 1 -
> > arch/m68k/cpu/mcf530x/cpu.c | 1 -
> > arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf530x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf530x/speed.c | 1 -
> > arch/m68k/cpu/mcf532x/cpu.c | 1 -
> > arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf532x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf532x/speed.c | 1 -
> > arch/m68k/cpu/mcf5445x/cpu.c | 1 -
> > arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
> > arch/m68k/cpu/mcf5445x/dspi.c | 1 -
> > arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
> > arch/m68k/cpu/mcf5445x/speed.c | 1 -
> > arch/m68k/cpu/mcf5445x/start.S | 1 -
> > arch/m68k/include/asm/immap.h | 1 +
> > arch/m68k/include/asm/immap_520x.h | 1 +
> > arch/m68k/include/asm/immap_5235.h | 1 +
> > arch/m68k/include/asm/immap_5272.h | 1 +
> > arch/m68k/include/asm/immap_5275.h | 1 +
> > arch/m68k/include/asm/immap_5282.h | 1 +
> > arch/m68k/include/asm/immap_5301x.h | 1 +
> > arch/m68k/include/asm/immap_5307.h | 2 ++
> > arch/m68k/include/asm/immap_5329.h | 1 +
> > arch/m68k/include/asm/immap_5441x.h | 1 +
> > arch/m68k/lib/bdinfo.c | 3 ++-
> > arch/m68k/lib/bootm.c | 1 -
> > arch/m68k/lib/cache.c | 2 +-
> > arch/m68k/lib/fec.c | 2 +-
> > arch/m68k/lib/interrupts.c | 2 +-
> > arch/m68k/lib/time.c | 1 -
> > arch/m68k/lib/traps.c | 1 -
> > 39 files changed, 17 insertions(+), 30 deletions(-)
> >
>
> building for mcf5307 i get this error
>
> In file included from arch/m68k/lib/bootm.c:7:
> include/bootstage.h:225:1: error: unknown type name 'ulong'; did you mean
> 'long'?
> 225 | ulong timer_get_boot_us(void);
> | ^~~~~
Did you apply the whole series? The first few patches fix some global
issues.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-13 20:55 ` Tom Rini
@ 2023-10-13 21:40 ` Angelo Dureghello
0 siblings, 0 replies; 26+ messages in thread
From: Angelo Dureghello @ 2023-10-13 21:40 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot
Hi Tom,
sorry, applied all now, it works, i can boot properly.
Thanks.
Acked-by: Angelo Dureghello <angelo@kernel-space.org>
On 13/10/23 10:55 PM, Tom Rini wrote:
> On Fri, Oct 13, 2023 at 10:53:04PM +0200, Angelo Dureghello wrote:
>> Hi Tom,
>>
>>
>> On 13/10/23 1:03 AM, Tom Rini wrote:
>>> We can remove common.h from most cases of the code here, and only a few
>>> places need an additional header instead.
>>>
>>> Signed-off-by: Tom Rini <trini@konsulko.com>
>>> ---
>>> Cc: Angelo Dureghello <angelo@kernel-space.org>
>>> ---
>>> arch/m68k/cpu/mcf523x/cpu.c | 1 -
>>> arch/m68k/cpu/mcf523x/cpu_init.c | 1 -
>>> arch/m68k/cpu/mcf523x/interrupts.c | 1 -
>>> arch/m68k/cpu/mcf523x/speed.c | 1 -
>>> arch/m68k/cpu/mcf52x2/cpu.c | 1 -
>>> arch/m68k/cpu/mcf52x2/cpu_init.c | 3 +--
>>> arch/m68k/cpu/mcf52x2/interrupts.c | 1 -
>>> arch/m68k/cpu/mcf52x2/speed.c | 1 -
>>> arch/m68k/cpu/mcf530x/cpu.c | 1 -
>>> arch/m68k/cpu/mcf530x/cpu_init.c | 1 -
>>> arch/m68k/cpu/mcf530x/interrupts.c | 1 -
>>> arch/m68k/cpu/mcf530x/speed.c | 1 -
>>> arch/m68k/cpu/mcf532x/cpu.c | 1 -
>>> arch/m68k/cpu/mcf532x/cpu_init.c | 1 -
>>> arch/m68k/cpu/mcf532x/interrupts.c | 1 -
>>> arch/m68k/cpu/mcf532x/speed.c | 1 -
>>> arch/m68k/cpu/mcf5445x/cpu.c | 1 -
>>> arch/m68k/cpu/mcf5445x/cpu_init.c | 1 -
>>> arch/m68k/cpu/mcf5445x/dspi.c | 1 -
>>> arch/m68k/cpu/mcf5445x/interrupts.c | 1 -
>>> arch/m68k/cpu/mcf5445x/speed.c | 1 -
>>> arch/m68k/cpu/mcf5445x/start.S | 1 -
>>> arch/m68k/include/asm/immap.h | 1 +
>>> arch/m68k/include/asm/immap_520x.h | 1 +
>>> arch/m68k/include/asm/immap_5235.h | 1 +
>>> arch/m68k/include/asm/immap_5272.h | 1 +
>>> arch/m68k/include/asm/immap_5275.h | 1 +
>>> arch/m68k/include/asm/immap_5282.h | 1 +
>>> arch/m68k/include/asm/immap_5301x.h | 1 +
>>> arch/m68k/include/asm/immap_5307.h | 2 ++
>>> arch/m68k/include/asm/immap_5329.h | 1 +
>>> arch/m68k/include/asm/immap_5441x.h | 1 +
>>> arch/m68k/lib/bdinfo.c | 3 ++-
>>> arch/m68k/lib/bootm.c | 1 -
>>> arch/m68k/lib/cache.c | 2 +-
>>> arch/m68k/lib/fec.c | 2 +-
>>> arch/m68k/lib/interrupts.c | 2 +-
>>> arch/m68k/lib/time.c | 1 -
>>> arch/m68k/lib/traps.c | 1 -
>>> 39 files changed, 17 insertions(+), 30 deletions(-)
>>>
>>
>> building for mcf5307 i get this error
>>
>> In file included from arch/m68k/lib/bootm.c:7:
>> include/bootstage.h:225:1: error: unknown type name 'ulong'; did you mean
>> 'long'?
>> 225 | ulong timer_get_boot_us(void);
>> | ^~~~~
>
> Did you apply the whole series? The first few patches fix some global
> issues.
>
--
Angelo Dureghello
w: www.kernel-space.org
e: angelo@kernel-space.org
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 2/7] include: Add <linux/types.h> in a few places
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
2023-10-13 15:14 ` Simon Glass
@ 2023-10-24 23:15 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:15 UTC (permalink / raw)
To: u-boot; +Cc: Simon Glass
[-- Attachment #1: Type: text/plain, Size: 370 bytes --]
On Thu, Oct 12, 2023 at 07:03:54PM -0400, Tom Rini wrote:
> These files references a number of types that are defined in
> <linux/types.h> (and so forth), so include it here rather than rely on
> indirect inclusion.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> Reviewed-by: Simon Glass <sjg@chromium.org>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 3/7] arc: Remove common.h usage
2023-10-12 23:03 ` [PATCH 3/7] arc: Remove common.h usage Tom Rini
2023-10-13 9:21 ` Alexey Brodkin
@ 2023-10-24 23:15 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:15 UTC (permalink / raw)
To: u-boot; +Cc: Alexey Brodkin, Eugeniy Paltsev, uboot-snps-arc
[-- Attachment #1: Type: text/plain, Size: 334 bytes --]
On Thu, Oct 12, 2023 at 07:03:55PM -0400, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> Acked-by: Alexey Brodkin <abrodkin@synopsys.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 4/7] m68k: Remove common.h usage
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
2023-10-13 15:14 ` Simon Glass
2023-10-13 20:53 ` Angelo Dureghello
@ 2023-10-24 23:16 ` Tom Rini
2 siblings, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:16 UTC (permalink / raw)
To: u-boot; +Cc: Angelo Dureghello
[-- Attachment #1: Type: text/plain, Size: 339 bytes --]
On Thu, Oct 12, 2023 at 07:03:56PM -0400, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> Acked-by: Angelo Dureghello <angelo@kernel-space.org>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 5/7] microblaze: Remove common.h usage
2023-10-12 23:03 ` [PATCH 5/7] microblaze: " Tom Rini
2023-10-13 7:11 ` Michal Simek
@ 2023-10-24 23:16 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:16 UTC (permalink / raw)
To: u-boot; +Cc: Michal Simek
[-- Attachment #1: Type: text/plain, Size: 331 bytes --]
On Thu, Oct 12, 2023 at 07:03:57PM -0400, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> Acked-by: Michal Simek <michal.simek@amd.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 6/7] mips: Remove common.h usage
2023-10-12 23:03 ` [PATCH 6/7] mips: " Tom Rini
@ 2023-10-24 23:16 ` Tom Rini
0 siblings, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:16 UTC (permalink / raw)
To: u-boot; +Cc: Daniel Schwierzeck
[-- Attachment #1: Type: text/plain, Size: 282 bytes --]
On Thu, Oct 12, 2023 at 07:03:58PM -0400, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 7/7] riscv: Remove common.h usage
2023-10-12 23:03 ` [PATCH 7/7] riscv: " Tom Rini
[not found] ` <SEZPR03MB8064C345D63766D2E86B2184C1D2A@SEZPR03MB8064.apcprd03.prod.outlook.com>
@ 2023-10-24 23:16 ` Tom Rini
1 sibling, 0 replies; 26+ messages in thread
From: Tom Rini @ 2023-10-24 23:16 UTC (permalink / raw)
To: u-boot; +Cc: Rick Chen, Leo
[-- Attachment #1: Type: text/plain, Size: 329 bytes --]
On Thu, Oct 12, 2023 at 07:03:59PM -0400, Tom Rini wrote:
> We can remove common.h from most cases of the code here, and only a few
> places need an additional header instead.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
> Reviewed-by: Rick Chen <rick@andestech.com>
Applied to u-boot/master, thanks!
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 659 bytes --]
^ permalink raw reply [flat|nested] 26+ messages in thread
end of thread, other threads:[~2023-10-24 23:19 UTC | newest]
Thread overview: 26+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-12 23:03 [PATCH 1/7] checkpatch.pl: Make common.h check boarder Tom Rini
2023-10-12 23:03 ` [PATCH 2/7] include: Add <linux/types.h> in a few places Tom Rini
2023-10-13 15:14 ` Simon Glass
2023-10-24 23:15 ` Tom Rini
2023-10-12 23:03 ` [PATCH 3/7] arc: Remove common.h usage Tom Rini
2023-10-13 9:21 ` Alexey Brodkin
2023-10-24 23:15 ` Tom Rini
2023-10-12 23:03 ` [PATCH 4/7] m68k: " Tom Rini
2023-10-13 15:14 ` Simon Glass
2023-10-13 15:17 ` Tom Rini
2023-10-13 16:57 ` Simon Glass
2023-10-13 20:53 ` Angelo Dureghello
2023-10-13 20:55 ` Tom Rini
2023-10-13 21:40 ` Angelo Dureghello
2023-10-24 23:16 ` Tom Rini
2023-10-12 23:03 ` [PATCH 5/7] microblaze: " Tom Rini
2023-10-13 7:11 ` Michal Simek
2023-10-24 23:16 ` Tom Rini
2023-10-12 23:03 ` [PATCH 6/7] mips: " Tom Rini
2023-10-24 23:16 ` Tom Rini
2023-10-12 23:03 ` [PATCH 7/7] riscv: " Tom Rini
[not found] ` <SEZPR03MB8064C345D63766D2E86B2184C1D2A@SEZPR03MB8064.apcprd03.prod.outlook.com>
2023-10-13 8:52 ` Rick Chen
2023-10-24 23:16 ` Tom Rini
2023-10-13 15:15 ` [PATCH 1/7] checkpatch.pl: Make common.h check boarder Simon Glass
2023-10-13 15:16 ` Tom Rini
2023-10-13 15:49 ` Simon Glass
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox