diff options
author | Tom Rini <trini@konsulko.com> | 2025-05-14 16:46:00 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2025-05-29 08:29:16 -0600 |
commit | 64307118499db0be83db29cfcbd8860db1e44e37 (patch) | |
tree | 0a7e246db9ae4c3bdc3ac057e43a4915c300c7df | |
parent | 0352eab7d373664c1c01b23154025b83ec0eadca (diff) |
global: Add <linux/string.h> instead of long indirect include path
In a number of cases we have C files which rely on a chain of indirect
include paths to get <linux/string.h> to be included via <command.h>. To
facilitate cleaning up <command.h> make this code directly include
<linux/string.h>.
Signed-off-by: Tom Rini <trini@konsulko.com>
41 files changed, 41 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/mx5/clock.c b/arch/arm/mach-imx/mx5/clock.c index 41116e2c6a2..9901f8a7b56 100644 --- a/arch/arm/mach-imx/mx5/clock.c +++ b/arch/arm/mach-imx/mx5/clock.c @@ -10,6 +10,7 @@ #include <log.h> #include <asm/io.h> #include <linux/errno.h> +#include <linux/string.h> #include <asm/arch/imx-regs.h> #include <asm/arch/crm_regs.h> #include <asm/arch/clock.h> diff --git a/arch/arm/mach-keystone/cmd_clock.c b/arch/arm/mach-keystone/cmd_clock.c index e9ecc05953a..7b94a80b725 100644 --- a/arch/arm/mach-keystone/cmd_clock.c +++ b/arch/arm/mach-keystone/cmd_clock.c @@ -8,6 +8,7 @@ #include <vsprintf.h> #include <command.h> +#include <linux/string.h> #include <asm/arch/hardware.h> #include <asm/arch/clock.h> #include <asm/arch/psc_defs.h> diff --git a/arch/arm/mach-tegra/tegra124/bct.c b/arch/arm/mach-tegra/tegra124/bct.c index a71aa87fce1..4dc4b7138ab 100644 --- a/arch/arm/mach-tegra/tegra124/bct.c +++ b/arch/arm/mach-tegra/tegra124/bct.c @@ -7,6 +7,7 @@ #include <command.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #include <asm/arch-tegra/crypto.h> #include "bct.h" #include "uboot_aes.h" diff --git a/arch/arm/mach-tegra/tegra20/bct.c b/arch/arm/mach-tegra/tegra20/bct.c index b647b6b26d2..253cb243676 100644 --- a/arch/arm/mach-tegra/tegra20/bct.c +++ b/arch/arm/mach-tegra/tegra20/bct.c @@ -7,6 +7,7 @@ #include <command.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #include <asm/arch-tegra/crypto.h> #include "bct.h" #include "uboot_aes.h" diff --git a/arch/arm/mach-tegra/tegra30/bct.c b/arch/arm/mach-tegra/tegra30/bct.c index 250009ea8d8..398ba1de386 100644 --- a/arch/arm/mach-tegra/tegra30/bct.c +++ b/arch/arm/mach-tegra/tegra30/bct.c @@ -7,6 +7,7 @@ #include <command.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #include <asm/arch-tegra/crypto.h> #include "bct.h" #include "uboot_aes.h" diff --git a/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c b/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c index 629f8b90c9d..be4ce3265bb 100644 --- a/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c +++ b/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c @@ -9,6 +9,7 @@ #include <linux/io.h> #include <linux/printk.h> #include <linux/sizes.h> +#include <linux/string.h> #include "../soc-info.h" #include "ddrmphy-regs.h" diff --git a/arch/arm/mach-uniphier/dram/cmd_ddrphy.c b/arch/arm/mach-uniphier/dram/cmd_ddrphy.c index ca519d1c7e0..3ccafe20638 100644 --- a/arch/arm/mach-uniphier/dram/cmd_ddrphy.c +++ b/arch/arm/mach-uniphier/dram/cmd_ddrphy.c @@ -10,6 +10,7 @@ #include <linux/io.h> #include <linux/printk.h> #include <linux/sizes.h> +#include <linux/string.h> #include "../soc-info.h" #include "ddrphy-regs.h" diff --git a/board/freescale/common/qixis.c b/board/freescale/common/qixis.c index 7815ba2dbce..04cad48f033 100644 --- a/board/freescale/common/qixis.c +++ b/board/freescale/common/qixis.c @@ -12,6 +12,7 @@ #include <asm/io.h> #include <linux/compiler.h> #include <linux/time.h> +#include <linux/string.h> #include <i2c.h> #include "qixis.h" diff --git a/board/freescale/ls1043ardb/cpld.c b/board/freescale/ls1043ardb/cpld.c index bda2f3ac3a6..39b6c6449cf 100644 --- a/board/freescale/ls1043ardb/cpld.c +++ b/board/freescale/ls1043ardb/cpld.c @@ -7,6 +7,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/ls1046ardb/cpld.c b/board/freescale/ls1046ardb/cpld.c index 7f8ca2e857f..26a5962bd6e 100644 --- a/board/freescale/ls1046ardb/cpld.c +++ b/board/freescale/ls1046ardb/cpld.c @@ -7,6 +7,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/p2041rdb/cpld.c b/board/freescale/p2041rdb/cpld.c index 915a8b994d5..2bba377d4d4 100644 --- a/board/freescale/p2041rdb/cpld.c +++ b/board/freescale/p2041rdb/cpld.c @@ -12,6 +12,7 @@ */ #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/t102xrdb/cpld.c b/board/freescale/t102xrdb/cpld.c index cc933ccd544..00ea9d8f503 100644 --- a/board/freescale/t102xrdb/cpld.c +++ b/board/freescale/t102xrdb/cpld.c @@ -9,6 +9,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/t104xrdb/cpld.c b/board/freescale/t104xrdb/cpld.c index c2d526ae15a..038e40e2fae 100644 --- a/board/freescale/t104xrdb/cpld.c +++ b/board/freescale/t104xrdb/cpld.c @@ -12,6 +12,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/t208xrdb/cpld.c b/board/freescale/t208xrdb/cpld.c index d2226af6278..838d88d977e 100644 --- a/board/freescale/t208xrdb/cpld.c +++ b/board/freescale/t208xrdb/cpld.c @@ -7,6 +7,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/freescale/t4rdb/cpld.c b/board/freescale/t4rdb/cpld.c index f076350c1c5..258581eee96 100644 --- a/board/freescale/t4rdb/cpld.c +++ b/board/freescale/t4rdb/cpld.c @@ -16,6 +16,7 @@ #include <config.h> #include <command.h> +#include <linux/string.h> #include <asm/io.h> #include "cpld.h" diff --git a/board/toradex/apalis_imx6/do_fuse.c b/board/toradex/apalis_imx6/do_fuse.c index 698b05bc5ad..8721276bed8 100644 --- a/board/toradex/apalis_imx6/do_fuse.c +++ b/board/toradex/apalis_imx6/do_fuse.c @@ -11,6 +11,7 @@ #include <command.h> #include <console.h> #include <fuse.h> +#include <linux/string.h> static int mfgr_fuse(void) { diff --git a/board/toradex/colibri_imx6/do_fuse.c b/board/toradex/colibri_imx6/do_fuse.c index 698b05bc5ad..8721276bed8 100644 --- a/board/toradex/colibri_imx6/do_fuse.c +++ b/board/toradex/colibri_imx6/do_fuse.c @@ -11,6 +11,7 @@ #include <command.h> #include <console.h> #include <fuse.h> +#include <linux/string.h> static int mfgr_fuse(void) { diff --git a/boot/image-pre-load.c b/boot/image-pre-load.c index adf3b341a20..2f851ebb28c 100644 --- a/boot/image-pre-load.c +++ b/boot/image-pre-load.c @@ -7,6 +7,7 @@ #include "mkimage.h" #else #include <asm/global_data.h> +#include <env.h> #include <mapmem.h> DECLARE_GLOBAL_DATA_PTR; #endif /* !USE_HOSTCC*/ diff --git a/cmd/2048.c b/cmd/2048.c index 42cd171b0e4..aa0f82721dc 100644 --- a/cmd/2048.c +++ b/cmd/2048.c @@ -8,6 +8,7 @@ #include <rand.h> #include <vsprintf.h> #include <linux/delay.h> +#include <linux/string.h> #define SIZE 4 static uint score; diff --git a/cmd/armflash.c b/cmd/armflash.c index e292cf85c45..83f616db4ef 100644 --- a/cmd/armflash.c +++ b/cmd/armflash.c @@ -9,6 +9,7 @@ #include <console.h> #include <flash.h> #include <vsprintf.h> +#include <linux/string.h> #include <asm/io.h> #define MAX_REGIONS 4 diff --git a/cmd/bootstage.c b/cmd/bootstage.c index 8248c41ca82..5c6d5a3ab45 100644 --- a/cmd/bootstage.c +++ b/cmd/bootstage.c @@ -6,6 +6,7 @@ #include <bootstage.h> #include <command.h> #include <vsprintf.h> +#include <linux/string.h> static int do_bootstage_report(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/cache.c b/cmd/cache.c index 3049f5c305f..b7007877ab0 100644 --- a/cmd/cache.c +++ b/cmd/cache.c @@ -10,6 +10,7 @@ #include <command.h> #include <cpu_func.h> #include <linux/compiler.h> +#include <linux/string.h> static int parse_argv(const char *); diff --git a/cmd/diag.c b/cmd/diag.c index c6da5aae3fc..4a88ab00a07 100644 --- a/cmd/diag.c +++ b/cmd/diag.c @@ -9,6 +9,7 @@ */ #include <command.h> #include <post.h> +#include <linux/string.h> int do_diag(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { @@ -9,6 +9,7 @@ #include <command.h> #include <dm/root.h> #include <dm/util.h> +#include <linux/string.h> static int do_dm_dump_driver_compat(struct cmd_tbl *cmdtp, int flag, int argc, char * const argv[]) diff --git a/cmd/echo.c b/cmd/echo.c index 973213a03a6..d1346504cfb 100644 --- a/cmd/echo.c +++ b/cmd/echo.c @@ -5,6 +5,7 @@ */ #include <command.h> +#include <linux/string.h> static int do_echo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/flash.c b/cmd/flash.c index fd660ec477c..76aa387ba59 100644 --- a/cmd/flash.c +++ b/cmd/flash.c @@ -10,6 +10,7 @@ #include <command.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #include <u-boot/uuid.h> #if defined(CONFIG_CMD_MTDPARTS) diff --git a/cmd/fuse.c b/cmd/fuse.c index 6c42c096809..e2206cdf0d5 100644 --- a/cmd/fuse.c +++ b/cmd/fuse.c @@ -14,6 +14,7 @@ #include <mapmem.h> #include <vsprintf.h> #include <linux/errno.h> +#include <linux/string.h> static int confirm_prog(void) { diff --git a/cmd/irq.c b/cmd/irq.c index da223b4b2cc..58483d04de8 100644 --- a/cmd/irq.c +++ b/cmd/irq.c @@ -6,6 +6,7 @@ #include <config.h> #include <command.h> #include <irq_func.h> +#include <linux/string.h> static int do_interrupts(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/legacy_led.c b/cmd/legacy_led.c index 50de7e89d8f..db312ae6e2d 100644 --- a/cmd/legacy_led.c +++ b/cmd/legacy_led.c @@ -12,6 +12,7 @@ #include <command.h> #include <status_led.h> #include <vsprintf.h> +#include <linux/string.h> struct led_tbl_s { char *string; /* String for use in the command */ @@ -6,6 +6,7 @@ #include <command.h> #include <cpu_func.h> #include <vsprintf.h> +#include <linux/string.h> static int cpu_status_all(void) { diff --git a/cmd/optee.c b/cmd/optee.c index e3aae5e9f9b..155c9f1bb73 100644 --- a/cmd/optee.c +++ b/cmd/optee.c @@ -6,6 +6,7 @@ #include <errno.h> #include <tee.h> #include <vsprintf.h> +#include <linux/string.h> #define TA_HELLO_WORLD_CMD_INC_VALUE 0 /* This needs to match the UUID of the Hello World TA. */ diff --git a/cmd/sha1sum.c b/cmd/sha1sum.c index 52aa26c78d2..f2757146bba 100644 --- a/cmd/sha1sum.c +++ b/cmd/sha1sum.c @@ -9,6 +9,7 @@ #include <command.h> #include <hash.h> +#include <linux/string.h> #include <u-boot/sha1.h> int do_sha1sum(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/sleep.c b/cmd/sleep.c index 7616fed7556..a8c896e0c5e 100644 --- a/cmd/sleep.c +++ b/cmd/sleep.c @@ -9,6 +9,7 @@ #include <time.h> #include <vsprintf.h> #include <linux/delay.h> +#include <linux/string.h> static int do_sleep(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/smccc.c b/cmd/smccc.c index 3a4d885e37e..fa04bb05ca4 100644 --- a/cmd/smccc.c +++ b/cmd/smccc.c @@ -9,6 +9,7 @@ #include <linux/arm-smccc.h> #include <linux/compiler.h> #include <linux/psci.h> +#include <linux/string.h> static int do_call(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/stackprot_test.c b/cmd/stackprot_test.c index e7ff4a06158..78e9beba5bf 100644 --- a/cmd/stackprot_test.c +++ b/cmd/stackprot_test.c @@ -4,6 +4,7 @@ */ #include <command.h> +#include <linux/string.h> static int do_test_stackprot_fail(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/strings.c b/cmd/strings.c index 5bcb0f2b567..beac2a6e6b3 100644 --- a/cmd/strings.c +++ b/cmd/strings.c @@ -9,6 +9,7 @@ #include <config.h> #include <command.h> #include <vsprintf.h> +#include <linux/string.h> static char *start_addr, *last_addr; diff --git a/cmd/test.c b/cmd/test.c index b4c3eabf9f6..4774d296487 100644 --- a/cmd/test.c +++ b/cmd/test.c @@ -8,6 +8,7 @@ #include <fs.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #define OP_INVALID 0 #define OP_NOT 1 diff --git a/cmd/timer.c b/cmd/timer.c index 04fcd84ac6a..427309e108d 100644 --- a/cmd/timer.c +++ b/cmd/timer.c @@ -6,6 +6,7 @@ #include <command.h> #include <time.h> +#include <linux/string.h> static int do_timer(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) diff --git a/cmd/ufs.c b/cmd/ufs.c index 6e21fbb1685..790dab50f18 100644 --- a/cmd/ufs.c +++ b/cmd/ufs.c @@ -8,6 +8,7 @@ #include <command.h> #include <ufs.h> #include <vsprintf.h> +#include <linux/string.h> static int do_ufs(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { diff --git a/cmd/x86/mtrr.c b/cmd/x86/mtrr.c index 289865515ef..91130453039 100644 --- a/cmd/x86/mtrr.c +++ b/cmd/x86/mtrr.c @@ -6,6 +6,7 @@ #include <command.h> #include <log.h> #include <vsprintf.h> +#include <linux/string.h> #include <asm/msr.h> #include <asm/mp.h> #include <asm/mtrr.h> diff --git a/drivers/tpm/sandbox_common.c b/drivers/tpm/sandbox_common.c index 596e0156389..9d386fc32e5 100644 --- a/drivers/tpm/sandbox_common.c +++ b/drivers/tpm/sandbox_common.c @@ -9,6 +9,7 @@ #include <tpm-v1.h> #include <tpm-v2.h> +#include <linux/string.h> #include <asm/unaligned.h> #include "sandbox_common.h" |