From: Simon Glass Date: Sun, 10 May 2020 17:40:03 +0000 (-0600) Subject: command: Remove the cmd_tbl_t typedef X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=091401131085;p=u-boot.git command: Remove the cmd_tbl_t typedef We should not use typedefs in U-Boot. They cannot be used as forward declarations which means that header files must include the full header to access them. Drop the typedef and rename the struct to remove the _s suffix which is now not useful. This requires quite a few header-file additions. Signed-off-by: Simon Glass --- diff --git a/arch/arc/lib/bootm.c b/arch/arc/lib/bootm.c index 9fa6aaf3b2..8f611efb56 100644 --- a/arch/arc/lib/bootm.c +++ b/arch/arc/lib/bootm.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include diff --git a/arch/arc/lib/reset.c b/arch/arc/lib/reset.c index 30dd4b5238..fbb56ec83a 100644 --- a/arch/arc/lib/reset.c +++ b/arch/arc/lib/reset.c @@ -13,7 +13,7 @@ __weak void reset_cpu(ulong addr) __builtin_arc_brk(); } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { printf("Resetting the board...\n"); diff --git a/arch/arm/cpu/arm1136/mx35/generic.c b/arch/arm/cpu/arm1136/mx35/generic.c index 4c45810fbe..e6fff5b220 100644 --- a/arch/arm/cpu/arm1136/mx35/generic.c +++ b/arch/arm/cpu/arm1136/mx35/generic.c @@ -8,6 +8,7 @@ #include #include +#include #include #include #include @@ -379,8 +380,8 @@ u32 imx_get_fecclk(void) } #endif -int do_mx35_showclocks(cmd_tbl_t *cmdtp, - int flag, int argc, char * const argv[]) +int do_mx35_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 cpufreq = get_mcu_main_clk(); printf("mx35 cpu clock: %dMHz\n", cpufreq / 1000000); diff --git a/arch/arm/cpu/arm926ejs/mxs/mxs.c b/arch/arm/cpu/arm926ejs/mxs/mxs.c index 72988417ac..d742c0f151 100644 --- a/arch/arm/cpu/arm926ejs/mxs/mxs.c +++ b/arch/arm/cpu/arm926ejs/mxs/mxs.c @@ -10,6 +10,7 @@ */ #include +#include #include #include #include @@ -187,7 +188,8 @@ int print_cpuinfo(void) } #endif -int do_mx28_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +int do_mx28_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { printf("CPU: %3d MHz\n", mxc_get_clock(MXC_ARM_CLK) / 1000000); printf("BUS: %3d MHz\n", mxc_get_clock(MXC_AHB_CLK) / 1000000); diff --git a/arch/arm/cpu/arm926ejs/spear/cpu.c b/arch/arm/cpu/arm926ejs/spear/cpu.c index f5192240e4..2106541074 100644 --- a/arch/arm/cpu/arm926ejs/spear/cpu.c +++ b/arch/arm/cpu/arm926ejs/spear/cpu.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -81,7 +82,7 @@ int print_cpuinfo(void) #endif #if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_NAND_ECC_BCH) && defined(CONFIG_NAND_FSMC) -static int do_switch_ecc(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_switch_ecc(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc != 2) diff --git a/arch/arm/cpu/arm926ejs/spear/spr_misc.c b/arch/arm/cpu/arm926ejs/spear/spr_misc.c index d5be646555..998423b652 100644 --- a/arch/arm/cpu/arm926ejs/spear/spr_misc.c +++ b/arch/arm/cpu/arm926ejs/spear/spr_misc.c @@ -182,7 +182,8 @@ static int write_mac(uchar *mac) } #endif -int do_chip_config(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_chip_config(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { void (*sram_setfreq) (unsigned int, unsigned int); unsigned int frequency; diff --git a/arch/arm/cpu/armv7/vf610/generic.c b/arch/arm/cpu/armv7/vf610/generic.c index da43e34394..fd2ab37a8f 100644 --- a/arch/arm/cpu/armv7/vf610/generic.c +++ b/arch/arm/cpu/armv7/vf610/generic.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include @@ -240,8 +241,8 @@ unsigned int mxc_get_clock(enum mxc_clock clk) } /* Dump some core clocks */ -int do_vf610_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_vf610_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { printf("\n"); printf("cpu clock : %8d MHz\n", mxc_get_clock(MXC_ARM_CLK) / 1000000); diff --git a/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_serdes.c b/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_serdes.c index d143864af1..07a47d51e4 100644 --- a/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_serdes.c +++ b/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_serdes.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/arch/arm/cpu/armv8/fsl-layerscape/mp.c b/arch/arm/cpu/armv8/fsl-layerscape/mp.c index 4ef2a30278..31536b8181 100644 --- a/arch/arm/cpu/armv8/fsl-layerscape/mp.c +++ b/arch/arm/cpu/armv8/fsl-layerscape/mp.c @@ -260,7 +260,7 @@ int cpu_status(u32 nr) return 0; } -int cpu_release(u32 nr, int argc, char * const argv[]) +int cpu_release(u32 nr, int argc, char *const argv[]) { u64 boot_addr; u64 *table = (u64 *)get_spin_tbl_addr(); diff --git a/arch/arm/include/asm/arch-mx6/clock.h b/arch/arm/include/asm/arch-mx6/clock.h index 769917679e..8ae4971578 100644 --- a/arch/arm/include/asm/arch-mx6/clock.h +++ b/arch/arm/include/asm/arch-mx6/clock.h @@ -21,7 +21,7 @@ #define MXC_CLK32 32768 #endif -struct cmd_tbl_s; +struct cmd_tbl; enum mxc_clock { MXC_ARM_CLK = 0, @@ -82,6 +82,6 @@ void enable_thermal_clk(void); void mxs_set_lcdclk(u32 base_addr, u32 freq); void select_ldb_di_clock_source(enum ldb_di_clock clk); void enable_eim_clk(unsigned char enable); -int do_mx6_showclocks(struct cmd_tbl_s *cmdtp, int flag, int argc, +int do_mx6_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]); #endif /* __ASM_ARCH_CLOCK_H */ diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c index 68beea2c9d..0facd0c989 100644 --- a/arch/arm/lib/bootm.c +++ b/arch/arm/lib/bootm.c @@ -422,7 +422,7 @@ static void boot_jump_linux(bootm_headers_t *images, int flag) * DIFFERENCE: Instead of calling prep and go at the end * they are called if subcommand is equal 0. */ -int do_bootm_linux(int flag, int argc, char * const argv[], +int do_bootm_linux(int flag, int argc, char *const argv[], bootm_headers_t *images) { /* No need for those on ARM */ diff --git a/arch/arm/lib/cmd_boot.c b/arch/arm/lib/cmd_boot.c index 03dde84252..c905ecc4bd 100644 --- a/arch/arm/lib/cmd_boot.c +++ b/arch/arm/lib/cmd_boot.c @@ -32,7 +32,7 @@ * instructions, otherwise a fault occurs." */ unsigned long do_go_exec(ulong (*entry)(int, char * const []), - int argc, char * const argv[]) + int argc, char *const argv[]) { ulong addr = (ulong)entry | 1; entry = (void *)addr; diff --git a/arch/arm/lib/reset.c b/arch/arm/lib/reset.c index 835a40e59d..65b4be20b8 100644 --- a/arch/arm/lib/reset.c +++ b/arch/arm/lib/reset.c @@ -21,6 +21,7 @@ */ #include +#include #include #include @@ -28,11 +29,11 @@ __weak void reset_misc(void) { } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { puts ("resetting ...\n"); - udelay (50000); /* wait 50 ms */ + mdelay(50); /* wait 50 ms */ disable_interrupts(); diff --git a/arch/arm/lib/semihosting.c b/arch/arm/lib/semihosting.c index 2658026cf4..1b365a970f 100644 --- a/arch/arm/lib/semihosting.c +++ b/arch/arm/lib/semihosting.c @@ -13,6 +13,7 @@ */ #include #include +#include #define SYSOPEN 0x01 #define SYSCLOSE 0x02 @@ -180,7 +181,8 @@ static int smh_load_file(const char * const name, ulong load_addr, return 0; } -static int do_smhload(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_smhload(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc == 3 || argc == 4) { ulong load_addr; diff --git a/arch/arm/mach-imx/cmd_bmode.c b/arch/arm/mach-imx/cmd_bmode.c index 2d4d6efe5a..19bfd9f9a0 100644 --- a/arch/arm/mach-imx/cmd_bmode.c +++ b/arch/arm/mach-imx/cmd_bmode.c @@ -54,8 +54,8 @@ static int create_usage(char *dest) return size; } -static int do_boot_mode(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_boot_mode(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const struct boot_mode *p; int reset_requested = 1; @@ -87,7 +87,7 @@ void add_board_boot_modes(const struct boot_mode *p) int size; char *dest; - cmd_tbl_t *entry = ll_entry_get(cmd_tbl_t, bmode, cmd); + struct cmd_tbl *entry = ll_entry_get(struct cmd_tbl, bmode, cmd); if (entry->usage) { free(entry->usage); diff --git a/arch/arm/mach-imx/cmd_dek.c b/arch/arm/mach-imx/cmd_dek.c index 1b111ba26b..5f21d2b1c5 100644 --- a/arch/arm/mach-imx/cmd_dek.c +++ b/arch/arm/mach-imx/cmd_dek.c @@ -54,7 +54,8 @@ static int blob_encap_dek(const u8 *src, u8 *dst, u32 len) * Returns zero on success, CMD_RET_USAGE in case of misuse and negative * on error. */ -static int do_dek_blob(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_dek_blob(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { uint32_t src_addr, dst_addr, len; uint8_t *src_ptr, *dst_ptr; diff --git a/arch/arm/mach-imx/cmd_hdmidet.c b/arch/arm/mach-imx/cmd_hdmidet.c index 6aa7d82577..e2571adfb0 100644 --- a/arch/arm/mach-imx/cmd_hdmidet.c +++ b/arch/arm/mach-imx/cmd_hdmidet.c @@ -3,11 +3,13 @@ * Copyright (C) 2012 Boundary Devices Inc. */ #include +#include #include #include #include -static int do_hdmidet(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_hdmidet(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct hdmi_regs *hdmi = (struct hdmi_regs *)HDMI_ARB_BASE_ADDR; return (readb(&hdmi->phy_stat0) & HDMI_DVI_STAT) ? 0 : 1; diff --git a/arch/arm/mach-imx/cmd_nandbcb.c b/arch/arm/mach-imx/cmd_nandbcb.c index 94cae146ce..cc4c8900f3 100644 --- a/arch/arm/mach-imx/cmd_nandbcb.c +++ b/arch/arm/mach-imx/cmd_nandbcb.c @@ -12,6 +12,7 @@ */ #include +#include #include #include #include @@ -1048,7 +1049,7 @@ err: return ret; } -static int do_nandbcb_bcbonly(int argc, char * const argv[]) +static int do_nandbcb_bcbonly(int argc, char *const argv[]) { struct fcb_block *fcb; struct dbbt_block *dbbt; @@ -1458,8 +1459,8 @@ static int do_nandbcb_init(int argc, char * const argv[]) return ret == 0 ? CMD_RET_SUCCESS : CMD_RET_FAILURE; } -static int do_nandbcb(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_nandbcb(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *cmd; int ret = 0; diff --git a/arch/arm/mach-imx/hab.c b/arch/arm/mach-imx/hab.c index 30db820b56..d0757d8b66 100644 --- a/arch/arm/mach-imx/hab.c +++ b/arch/arm/mach-imx/hab.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -291,8 +292,8 @@ static int get_hab_status(void) return 0; } -static int do_hab_status(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_hab_status(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if ((argc != 1)) { cmd_usage(cmdtp); @@ -324,8 +325,8 @@ static ulong get_image_ivt_offset(ulong img_addr) } } -static int do_authenticate_image(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_authenticate_image(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr, length, ivt_offset; int rcode = 0; @@ -349,8 +350,8 @@ static int do_authenticate_image(cmd_tbl_t *cmdtp, int flag, int argc, return rcode; } -static int do_hab_failsafe(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_hab_failsafe(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { hab_rvt_failsafe_t *hab_rvt_failsafe; @@ -365,8 +366,8 @@ static int do_hab_failsafe(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_hab_version(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_hab_version(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct hab_hdr *hdr = (struct hab_hdr *)HAB_RVT_BASE; @@ -380,8 +381,8 @@ static int do_hab_version(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_authenticate_image_or_failover(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_authenticate_image_or_failover(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { int ret = CMD_RET_FAILURE; diff --git a/arch/arm/mach-imx/imx8/ahab.c b/arch/arm/mach-imx/imx8/ahab.c index 6d25abe5ce..64394473da 100644 --- a/arch/arm/mach-imx/imx8/ahab.c +++ b/arch/arm/mach-imx/imx8/ahab.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -149,8 +150,8 @@ exit: return ret; } -static int do_authenticate(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_authenticate(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr; @@ -250,8 +251,8 @@ static void display_ahab_auth_event(u32 event) } } -static int do_ahab_status(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_ahab_status(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int err; u8 idx = 0U; @@ -297,8 +298,8 @@ static int confirm_close(void) return 0; } -static int do_ahab_close(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_ahab_close(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int err; u16 lc; diff --git a/arch/arm/mach-imx/imx8/snvs_security_sc.c b/arch/arm/mach-imx/imx8/snvs_security_sc.c index 73f5651161..564d1bfdfb 100644 --- a/arch/arm/mach-imx/imx8/snvs_security_sc.c +++ b/arch/arm/mach-imx/imx8/snvs_security_sc.c @@ -626,7 +626,8 @@ static char snvs_cfg_help_text[] = "ALL values should be in hexadecimal format"; #define NB_REGISTERS 18 -static int do_snvs_cfg(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_snvs_cfg(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int err = 0; u32 idx = 0; @@ -677,7 +678,7 @@ static char snvs_dgo_cfg_help_text[] = "\n" "ALL values should be in hexadecimal format"; -static int do_snvs_dgo_cfg(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_snvs_dgo_cfg(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int err = 0; @@ -713,7 +714,7 @@ static char tamper_pin_cfg_help_text[] = "\n" "ALL values should be in hexadecimal format"; -static int do_tamper_pin_cfg(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_tamper_pin_cfg(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int err = 0; @@ -748,8 +749,8 @@ static char snvs_clear_status_help_text[] = "Write the status registers with the value provided," " clearing the status"; -static int do_snvs_clear_status(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_snvs_clear_status(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int scierr = 0; u32 idx = 0; @@ -788,7 +789,7 @@ static char snvs_sec_status_help_text[] = "snvs_sec_status\n" "Display information about the security related to tamper and secvio"; -static int do_snvs_sec_status(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_snvs_sec_status(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int scierr; diff --git a/arch/arm/mach-imx/imx8m/clock_imx8mq.c b/arch/arm/mach-imx/imx8m/clock_imx8mq.c index ee18cdee50..52205b044a 100644 --- a/arch/arm/mach-imx/imx8m/clock_imx8mq.c +++ b/arch/arm/mach-imx/imx8m/clock_imx8mq.c @@ -6,6 +6,7 @@ */ #include +#include #include #include #include @@ -755,8 +756,8 @@ int clock_init(void) * Dump some clockes. */ #ifndef CONFIG_SPL_BUILD -static int do_imx8m_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_imx8m_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 freq; diff --git a/arch/arm/mach-imx/imx_bootaux.c b/arch/arm/mach-imx/imx_bootaux.c index ec0da1164f..ca823e6861 100644 --- a/arch/arm/mach-imx/imx_bootaux.c +++ b/arch/arm/mach-imx/imx_bootaux.c @@ -92,7 +92,8 @@ int arch_auxiliary_core_check_up(u32 core_id) * The TCMUL is mapped to (M4_BOOTROM_BASE_ADDR) at A core side for * accessing the M4 TCMUL. */ -static int do_bootaux(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_bootaux(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr; int ret, up; diff --git a/arch/arm/mach-imx/mx5/clock.c b/arch/arm/mach-imx/mx5/clock.c index 2fabdd2eae..09c4c89664 100644 --- a/arch/arm/mach-imx/mx5/clock.c +++ b/arch/arm/mach-imx/mx5/clock.c @@ -7,6 +7,7 @@ */ #include +#include #include #include #include @@ -943,7 +944,8 @@ void mxc_set_sata_internal_clock(void) /* * Dump some core clockes. */ -static int do_mx5_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_mx5_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 freq; diff --git a/arch/arm/mach-imx/mx6/clock.c b/arch/arm/mach-imx/mx6/clock.c index 6a9e673ca2..9f3d62fa41 100644 --- a/arch/arm/mach-imx/mx6/clock.c +++ b/arch/arm/mach-imx/mx6/clock.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -1305,7 +1306,8 @@ void disable_ipu_clock(void) /* * Dump some core clockes. */ -int do_mx6_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_mx6_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 freq; freq = decode_pll(PLL_SYS, MXC_HCLK); diff --git a/arch/arm/mach-imx/mx7/clock.c b/arch/arm/mach-imx/mx7/clock.c index 75be4f8ad7..f5520374f1 100644 --- a/arch/arm/mach-imx/mx7/clock.c +++ b/arch/arm/mach-imx/mx7/clock.c @@ -8,6 +8,7 @@ #include #include +#include #include #include #include @@ -1100,7 +1101,8 @@ void epdc_clock_disable(void) /* * Dump some core clockes. */ -int do_mx7_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_mx7_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 freq; freq = decode_pll(PLL_CORE, MXC_HCLK); diff --git a/arch/arm/mach-imx/mx7ulp/clock.c b/arch/arm/mach-imx/mx7ulp/clock.c index 3c0bcccd0d..a987ff22df 100644 --- a/arch/arm/mach-imx/mx7ulp/clock.c +++ b/arch/arm/mach-imx/mx7ulp/clock.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include @@ -329,7 +330,8 @@ void hab_caam_clock_enable(unsigned char enable) /* * Dump some core clockes. */ -int do_mx7_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_mx7_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 addr = 0; u32 freq; diff --git a/arch/arm/mach-keystone/cmd_clock.c b/arch/arm/mach-keystone/cmd_clock.c index 667826b9f6..7165d666e5 100644 --- a/arch/arm/mach-keystone/cmd_clock.c +++ b/arch/arm/mach-keystone/cmd_clock.c @@ -19,7 +19,7 @@ struct pll_init_data cmd_pll_data = { .pll_od = 2, }; -int do_pll_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_pll_cmd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc != 5) goto pll_cmd_usage; @@ -63,7 +63,8 @@ U_BOOT_CMD( PLLSET_CMD_LIST "
\n" ); -int do_getclk_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_getclk_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned int clk; unsigned long freq; @@ -92,7 +93,7 @@ U_BOOT_CMD( CLOCK_INDEXES_LIST ); -int do_psc_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_psc_cmd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int psc_module; int res; diff --git a/arch/arm/mach-keystone/cmd_mon.c b/arch/arm/mach-keystone/cmd_mon.c index 8142039040..049d573473 100644 --- a/arch/arm/mach-keystone/cmd_mon.c +++ b/arch/arm/mach-keystone/cmd_mon.c @@ -12,8 +12,8 @@ #include asm(".arch_extension sec\n\t"); -static int do_mon_install(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_mon_install(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 addr, dpsc_base = 0x1E80000, freq, load_addr, size; int rcode = 0; @@ -65,8 +65,8 @@ static void core_spin(void) } } -int do_mon_power(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_mon_power(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int rcode = 0, core_id, on; void (*fn)(void); diff --git a/arch/arm/mach-keystone/cmd_poweroff.c b/arch/arm/mach-keystone/cmd_poweroff.c index 89b18516cd..f0ad9173b9 100644 --- a/arch/arm/mach-keystone/cmd_poweroff.c +++ b/arch/arm/mach-keystone/cmd_poweroff.c @@ -12,7 +12,7 @@ #include #include -int do_poweroff(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_poweroff(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { mon_power_off(0); diff --git a/arch/arm/mach-keystone/ddr3.c b/arch/arm/mach-keystone/ddr3.c index 23ff06466d..9ab6b53adb 100644 --- a/arch/arm/mach-keystone/ddr3.c +++ b/arch/arm/mach-keystone/ddr3.c @@ -7,6 +7,7 @@ */ #include +#include #include #include #include diff --git a/arch/arm/mach-keystone/keystone.c b/arch/arm/mach-keystone/keystone.c index 1d79927ac7..efaabca5a7 100644 --- a/arch/arm/mach-keystone/keystone.c +++ b/arch/arm/mach-keystone/keystone.c @@ -7,6 +7,7 @@ */ #include +#include #include #include #include diff --git a/arch/arm/mach-meson/sm.c b/arch/arm/mach-meson/sm.c index dacc897533..725897a0ec 100644 --- a/arch/arm/mach-meson/sm.c +++ b/arch/arm/mach-meson/sm.c @@ -6,6 +6,8 @@ */ #include +#include +#include #include #include #include @@ -117,7 +119,7 @@ int meson_sm_get_reboot_reason(void) return FIELD_GET(REBOOT_REASON_MASK, reason); } -static int do_sm_serial(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_sm_serial(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ulong address; @@ -153,8 +155,8 @@ static const char *reboot_reasons[MAX_REBOOT_REASONS] = { [REBOOT_REASON_WATCHDOG_REBOOT] = "watchdog_reboot", }; -static int do_sm_reboot_reason(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_sm_reboot_reason(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *reason_str; char *destarg = NULL; @@ -181,15 +183,15 @@ static int do_sm_reboot_reason(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static cmd_tbl_t cmd_sm_sub[] = { +static struct cmd_tbl cmd_sm_sub[] = { U_BOOT_CMD_MKENT(serial, 2, 1, do_sm_serial, "", ""), U_BOOT_CMD_MKENT(reboot_reason, 1, 1, do_sm_reboot_reason, "", ""), }; -static int do_sm(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_sm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/arch/arm/mach-omap2/omap3/board.c b/arch/arm/mach-omap2/omap3/board.c index b893fb732e..f08c8ab43a 100644 --- a/arch/arm/mach-omap2/omap3/board.c +++ b/arch/arm/mach-omap2/omap3/board.c @@ -16,6 +16,7 @@ * */ #include +#include #include #include #include @@ -280,7 +281,8 @@ void abort(void) /****************************************************************************** * OMAP3 specific command to switch between NAND HW and SW ecc *****************************************************************************/ -static int do_switch_ecc(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +static int do_switch_ecc(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int hw, strength = 1; diff --git a/arch/arm/mach-omap2/sec-common.c b/arch/arm/mach-omap2/sec-common.c index 28b929f84f..edfb40f00b 100644 --- a/arch/arm/mach-omap2/sec-common.c +++ b/arch/arm/mach-omap2/sec-common.c @@ -13,6 +13,7 @@ */ #include +#include #include #include #include diff --git a/arch/arm/mach-rockchip/boot_mode.c b/arch/arm/mach-rockchip/boot_mode.c index 7598fe4c43..349c0648a6 100644 --- a/arch/arm/mach-rockchip/boot_mode.c +++ b/arch/arm/mach-rockchip/boot_mode.c @@ -5,6 +5,8 @@ #include #include +#include +#include #include #include #include diff --git a/arch/arm/mach-rockchip/cpu-info.c b/arch/arm/mach-rockchip/cpu-info.c index 08b7d3519d..21ca9dedce 100644 --- a/arch/arm/mach-rockchip/cpu-info.c +++ b/arch/arm/mach-rockchip/cpu-info.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/arch/arm/mach-rockchip/rk3288/rk3288.c b/arch/arm/mach-rockchip/rk3288/rk3288.c index 812f3bd5f3..804abe8a1b 100644 --- a/arch/arm/mach-rockchip/rk3288/rk3288.c +++ b/arch/arm/mach-rockchip/rk3288/rk3288.c @@ -3,6 +3,7 @@ * Copyright (c) 2016 Rockchip Electronics Co., Ltd */ #include +#include #include #include #include @@ -114,8 +115,8 @@ int rk_board_late_init(void) return rk3288_board_late_init(); } -static int do_clock(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_clock(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { static const struct { char *name; diff --git a/arch/arm/mach-socfpga/clock_manager.c b/arch/arm/mach-socfpga/clock_manager.c index 0a6025fffa..a4a97b6a0f 100644 --- a/arch/arm/mach-socfpga/clock_manager.c +++ b/arch/arm/mach-socfpga/clock_manager.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -62,7 +63,8 @@ int set_cpu_clk_info(void) } #ifndef CONFIG_SPL_BUILD -static int do_showclocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_showclocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { cm_print_clock_quick_summary(); return 0; diff --git a/arch/arm/mach-socfpga/misc.c b/arch/arm/mach-socfpga/misc.c index 557305c703..ac2b891fad 100644 --- a/arch/arm/mach-socfpga/misc.c +++ b/arch/arm/mach-socfpga/misc.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -178,7 +179,8 @@ int arch_cpu_init(void) } #ifndef CONFIG_SPL_BUILD -static int do_bridge(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_bridge(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned int mask = ~0; diff --git a/arch/arm/mach-stm32mp/cmd_stm32key.c b/arch/arm/mach-stm32mp/cmd_stm32key.c index f1f26e7c94..f191085a12 100644 --- a/arch/arm/mach-stm32mp/cmd_stm32key.c +++ b/arch/arm/mach-stm32mp/cmd_stm32key.c @@ -66,8 +66,8 @@ static int confirm_prog(void) return 0; } -static int do_stm32key(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_stm32key(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 addr; const char *op = argc >= 2 ? argv[1] : NULL; diff --git a/arch/arm/mach-stm32mp/cmd_stm32prog/cmd_stm32prog.c b/arch/arm/mach-stm32mp/cmd_stm32prog/cmd_stm32prog.c index 6bebea7ad5..0722e4a891 100644 --- a/arch/arm/mach-stm32mp/cmd_stm32prog/cmd_stm32prog.c +++ b/arch/arm/mach-stm32mp/cmd_stm32prog/cmd_stm32prog.c @@ -38,7 +38,7 @@ static void enable_vidconsole(void) #endif } -static int do_stm32prog(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_stm32prog(struct cmd_tbl *cmdtp, int flag, int argc, char * const argv[]) { ulong addr, size; diff --git a/arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c b/arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c index 65cb12dbcf..c5b8841b23 100644 --- a/arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c +++ b/arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c @@ -3,7 +3,7 @@ * Copyright (C) 2020, STMicroelectronics - All Rights Reserved */ -#include +#include #include #include #include diff --git a/arch/arm/mach-tegra/cmd_enterrcm.c b/arch/arm/mach-tegra/cmd_enterrcm.c index b2252f3621..110d441d9b 100644 --- a/arch/arm/mach-tegra/cmd_enterrcm.c +++ b/arch/arm/mach-tegra/cmd_enterrcm.c @@ -25,13 +25,14 @@ */ #include +#include #include #include #include #include -static int do_enterrcm(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_enterrcm(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { puts("Entering RCM...\n"); udelay(50000); diff --git a/arch/arm/mach-uniphier/boot-device/boot-device.c b/arch/arm/mach-uniphier/boot-device/boot-device.c index 83f8c6a428..777946970b 100644 --- a/arch/arm/mach-uniphier/boot-device/boot-device.c +++ b/arch/arm/mach-uniphier/boot-device/boot-device.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -205,7 +206,8 @@ int uniphier_boot_from_backend(void) #ifndef CONFIG_SPL_BUILD -static int do_pinmon(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_pinmon(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const struct uniphier_boot_device_info *info; u32 pinmon; diff --git a/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c b/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c index 9a25bba599..a6c0735198 100644 --- a/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c +++ b/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -291,7 +292,8 @@ static void reg_dump(const struct uniphier_ddrmphy_param *param) } } -static int do_ddrm(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_ddrm(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const struct uniphier_ddrmphy_param *param; char *cmd; diff --git a/arch/arm/mach-uniphier/dram/cmd_ddrphy.c b/arch/arm/mach-uniphier/dram/cmd_ddrphy.c index a616a2aafb..476c5b3582 100644 --- a/arch/arm/mach-uniphier/dram/cmd_ddrphy.c +++ b/arch/arm/mach-uniphier/dram/cmd_ddrphy.c @@ -6,6 +6,7 @@ */ #include +#include #include #include #include @@ -261,7 +262,8 @@ static void reg_dump(const struct uniphier_ddrphy_param *param) } } -static int do_ddr(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_ddr(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const struct uniphier_ddrphy_param *param; char *cmd; diff --git a/arch/arm/mach-uniphier/mmc-first-dev.c b/arch/arm/mach-uniphier/mmc-first-dev.c index e2f4f4eb5c..7f29b6bccd 100644 --- a/arch/arm/mach-uniphier/mmc-first-dev.c +++ b/arch/arm/mach-uniphier/mmc-first-dev.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -28,7 +29,8 @@ int mmc_get_env_dev(void) return find_first_mmc_device(false); } -static int do_mmcsetn(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_mmcsetn(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int dev; @@ -46,7 +48,8 @@ U_BOOT_CMD( "" ); -static int do_sdsetn(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_sdsetn(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int dev; diff --git a/arch/arm/mach-zynqmp/mp.c b/arch/arm/mach-zynqmp/mp.c index fbb551151a..cc07db4831 100644 --- a/arch/arm/mach-zynqmp/mp.c +++ b/arch/arm/mach-zynqmp/mp.c @@ -221,7 +221,7 @@ void initialize_tcm(bool mode) } } -int cpu_release(u32 nr, int argc, char * const argv[]) +int cpu_release(u32 nr, int argc, char *const argv[]) { if (nr >= ZYNQMP_CORE_APU0 && nr <= ZYNQMP_CORE_APU3) { u64 boot_addr = simple_strtoull(argv[0], NULL, 16); diff --git a/arch/m68k/cpu/mcf5227x/cpu.c b/arch/m68k/cpu/mcf5227x/cpu.c index 1590d4a954..200c53eaf3 100644 --- a/arch/m68k/cpu/mcf5227x/cpu.c +++ b/arch/m68k/cpu/mcf5227x/cpu.c @@ -19,7 +19,7 @@ DECLARE_GLOBAL_DATA_PTR; -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { rcm_t *rcm = (rcm_t *) (MMAP_RCM); udelay(1000); diff --git a/arch/m68k/cpu/mcf523x/cpu.c b/arch/m68k/cpu/mcf523x/cpu.c index 225bdc2d25..d521a8a2e4 100644 --- a/arch/m68k/cpu/mcf523x/cpu.c +++ b/arch/m68k/cpu/mcf523x/cpu.c @@ -21,7 +21,7 @@ DECLARE_GLOBAL_DATA_PTR; -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ccm_t *ccm = (ccm_t *) MMAP_CCM; diff --git a/arch/m68k/cpu/mcf52x2/cpu.c b/arch/m68k/cpu/mcf52x2/cpu.c index 1f70d90f0b..8c91e0e193 100644 --- a/arch/m68k/cpu/mcf52x2/cpu.c +++ b/arch/m68k/cpu/mcf52x2/cpu.c @@ -27,7 +27,7 @@ DECLARE_GLOBAL_DATA_PTR; #ifdef CONFIG_M5208 -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { rcm_t *rcm = (rcm_t *)(MMAP_RCM); @@ -140,7 +140,7 @@ int print_cpuinfo(void) } #endif /* CONFIG_DISPLAY_CPUINFO */ -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* Call the board specific reset actions first. */ if(board_reset) { @@ -175,7 +175,7 @@ int watchdog_init(void) #endif #ifdef CONFIG_M5272 -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { wdog_t *wdp = (wdog_t *) (MMAP_WDOG); @@ -264,7 +264,7 @@ int watchdog_init(void) #endif /* #ifdef CONFIG_M5272 */ #ifdef CONFIG_M5275 -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { rcm_t *rcm = (rcm_t *)(MMAP_RCM); @@ -354,7 +354,7 @@ int print_cpuinfo(void) } #endif /* CONFIG_DISPLAY_CPUINFO */ -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { MCFRESET_RCR = MCFRESET_RCR_SOFTRST; return 0; @@ -373,7 +373,7 @@ int print_cpuinfo(void) } #endif /* CONFIG_DISPLAY_CPUINFO */ -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* enable watchdog, set timeout to 0 and wait */ mbar_writeByte(MCFSIM_SYPCR, 0xc0); @@ -405,7 +405,7 @@ int print_cpuinfo(void) } #endif /* CONFIG_DISPLAY_CPUINFO */ -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* enable watchdog, set timeout to 0 and wait */ mbar_writeByte(SIM_SYPCR, 0xc0); diff --git a/arch/m68k/cpu/mcf530x/cpu.c b/arch/m68k/cpu/mcf530x/cpu.c index bef9047b35..0659bf6558 100644 --- a/arch/m68k/cpu/mcf530x/cpu.c +++ b/arch/m68k/cpu/mcf530x/cpu.c @@ -5,13 +5,14 @@ */ #include +#include #include #include #include #include #ifdef CONFIG_M5307 -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { sim_t *sim = (sim_t *)(MMAP_SIM); diff --git a/arch/m68k/cpu/mcf532x/cpu.c b/arch/m68k/cpu/mcf532x/cpu.c index 52b64a94a7..87b77f42de 100644 --- a/arch/m68k/cpu/mcf532x/cpu.c +++ b/arch/m68k/cpu/mcf532x/cpu.c @@ -21,7 +21,7 @@ DECLARE_GLOBAL_DATA_PTR; -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { rcm_t *rcm = (rcm_t *) (MMAP_RCM); diff --git a/arch/m68k/cpu/mcf5445x/cpu.c b/arch/m68k/cpu/mcf5445x/cpu.c index cb1514c600..2608fdd76f 100644 --- a/arch/m68k/cpu/mcf5445x/cpu.c +++ b/arch/m68k/cpu/mcf5445x/cpu.c @@ -21,7 +21,7 @@ DECLARE_GLOBAL_DATA_PTR; -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { rcm_t *rcm = (rcm_t *) (MMAP_RCM); udelay(1000); diff --git a/arch/m68k/cpu/mcf547x_8x/cpu.c b/arch/m68k/cpu/mcf547x_8x/cpu.c index 2a64c7b6f6..59cdfe70e4 100644 --- a/arch/m68k/cpu/mcf547x_8x/cpu.c +++ b/arch/m68k/cpu/mcf547x_8x/cpu.c @@ -21,7 +21,7 @@ DECLARE_GLOBAL_DATA_PTR; -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { gptmr_t *gptmr = (gptmr_t *) (MMAP_GPTMR); diff --git a/arch/m68k/lib/bootm.c b/arch/m68k/lib/bootm.c index c36ee79c92..b912d130d6 100644 --- a/arch/m68k/lib/bootm.c +++ b/arch/m68k/lib/bootm.c @@ -49,7 +49,8 @@ void arch_lmb_reserve(struct lmb *lmb) lmb_reserve(lmb, sp, (CONFIG_SYS_SDRAM_BASE + gd->ram_size - sp)); } -int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *images) +int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { int ret; bd_t *kbd; diff --git a/arch/microblaze/cpu/interrupts.c b/arch/microblaze/cpu/interrupts.c index 910c596884..a6a52f8527 100644 --- a/arch/microblaze/cpu/interrupts.c +++ b/arch/microblaze/cpu/interrupts.c @@ -187,7 +187,7 @@ void interrupt_handler(void) } #if defined(CONFIG_CMD_IRQ) -int do_irqinfo(cmd_tbl_t *cmdtp, int flag, int argc, const char *argv[]) +int do_irqinfo(struct cmd_tbl *cmdtp, int flag, int argc, const char *argv[]) { int i; struct irq_action *act = vecs; diff --git a/arch/microblaze/cpu/spl.c b/arch/microblaze/cpu/spl.c index 070c12cce9..c633e83853 100644 --- a/arch/microblaze/cpu/spl.c +++ b/arch/microblaze/cpu/spl.c @@ -6,6 +6,7 @@ */ #include +#include #include #include #include @@ -48,7 +49,7 @@ int spl_start_uboot(void) return 1; } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { __asm__ __volatile__ ("mts rmsr, r0;" \ "bra r0"); diff --git a/arch/microblaze/lib/bootm.c b/arch/microblaze/lib/bootm.c index 592ac97f82..93f95b1e26 100644 --- a/arch/microblaze/lib/bootm.c +++ b/arch/microblaze/lib/bootm.c @@ -108,7 +108,7 @@ static void boot_prep_linux(bootm_headers_t *images) } } -int do_bootm_linux(int flag, int argc, char * const argv[], +int do_bootm_linux(int flag, int argc, char *const argv[], bootm_headers_t *images) { images->cmdline_start = (ulong)env_get("bootargs"); diff --git a/arch/mips/cpu/cpu.c b/arch/mips/cpu/cpu.c index 682bee6be2..7d5c9fd83a 100644 --- a/arch/mips/cpu/cpu.c +++ b/arch/mips/cpu/cpu.c @@ -21,7 +21,7 @@ void __weak _machine_restart(void) /* NOP */; } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { _machine_restart(); diff --git a/arch/mips/lib/bootm.c b/arch/mips/lib/bootm.c index ce2b076b7d..cbc4413d5d 100644 --- a/arch/mips/lib/bootm.c +++ b/arch/mips/lib/bootm.c @@ -306,8 +306,8 @@ static void boot_jump_linux(bootm_headers_t *images) linux_extra); } -int do_bootm_linux(int flag, int argc, char * const argv[], - bootm_headers_t *images) +int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { /* No need for those on MIPS */ if (flag & BOOTM_STATE_OS_BD_T) diff --git a/arch/mips/mach-ath79/ar934x/clk.c b/arch/mips/mach-ath79/ar934x/clk.c index 09bdc253ae..5d0d4550db 100644 --- a/arch/mips/mach-ath79/ar934x/clk.c +++ b/arch/mips/mach-ath79/ar934x/clk.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include @@ -319,7 +320,8 @@ ulong get_ddr_freq(ulong dummy) return gd->mem_clk; } -int do_ar934x_showclk(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_ar934x_showclk(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ar934x_update_clock(); printf("CPU: %8ld MHz\n", gd->cpu_clk / 1000000); diff --git a/arch/nds32/cpu/n1213/ae3xx/cpu.c b/arch/nds32/cpu/n1213/ae3xx/cpu.c index 0660fffa45..c3efa31f59 100644 --- a/arch/nds32/cpu/n1213/ae3xx/cpu.c +++ b/arch/nds32/cpu/n1213/ae3xx/cpu.c @@ -39,7 +39,7 @@ int cleanup_before_linux(void) return 0; } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { disable_interrupts(); panic("AE3XX wdt not support yet.\n"); diff --git a/arch/nds32/cpu/n1213/ag101/cpu.c b/arch/nds32/cpu/n1213/ag101/cpu.c index 3ae87a21bb..9d99c83bf3 100644 --- a/arch/nds32/cpu/n1213/ag101/cpu.c +++ b/arch/nds32/cpu/n1213/ag101/cpu.c @@ -39,7 +39,7 @@ int cleanup_before_linux(void) return 0; } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { disable_interrupts(); diff --git a/arch/nds32/lib/boot.c b/arch/nds32/lib/boot.c index c50e8e5168..da2fd36a16 100644 --- a/arch/nds32/lib/boot.c +++ b/arch/nds32/lib/boot.c @@ -9,7 +9,7 @@ #include unsigned long do_go_exec(ulong (*entry)(int, char * const []), - int argc, char * const argv[]) + int argc, char *const argv[]) { cleanup_before_linux(); diff --git a/arch/nios2/cpu/cpu.c b/arch/nios2/cpu/cpu.c index 9008db6aa5..756535a0b4 100644 --- a/arch/nios2/cpu/cpu.c +++ b/arch/nios2/cpu/cpu.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -31,7 +32,7 @@ int checkboard(void) } #endif -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { disable_interrupts(); /* indirect call to go beyond 256MB limitation of toolchain */ diff --git a/arch/nios2/cpu/interrupts.c b/arch/nios2/cpu/interrupts.c index e9d1ff911b..90cabb6757 100644 --- a/arch/nios2/cpu/interrupts.c +++ b/arch/nios2/cpu/interrupts.c @@ -118,7 +118,7 @@ int interrupt_init(void) /*************************************************************************/ #if defined(CONFIG_CMD_IRQ) -int do_irqinfo (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_irqinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int i; struct irq_action *act = vecs; diff --git a/arch/nios2/lib/bootm.c b/arch/nios2/lib/bootm.c index bec18fe28f..fed412907f 100644 --- a/arch/nios2/lib/bootm.c +++ b/arch/nios2/lib/bootm.c @@ -6,12 +6,14 @@ #include #include +#include #include #include #define NIOS_MAGIC 0x534f494e /* enable command line and initrd passing */ -int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *images) +int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { void (*kernel)(int, int, int, char *) = (void *)images->ep; char *commandline = env_get("bootargs"); diff --git a/arch/powerpc/cpu/mpc83xx/cpu.c b/arch/powerpc/cpu/mpc83xx/cpu.c index f0e3ada195..0307039f37 100644 --- a/arch/powerpc/cpu/mpc83xx/cpu.c +++ b/arch/powerpc/cpu/mpc83xx/cpu.c @@ -123,8 +123,7 @@ int checkcpu(void) #endif #ifndef CONFIG_SYSRESET -int -do_reset (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ulong msr; #ifndef MPC83xx_RESET diff --git a/arch/powerpc/cpu/mpc83xx/ecc.c b/arch/powerpc/cpu/mpc83xx/ecc.c index a6eb7cb97c..1343dd3d3a 100644 --- a/arch/powerpc/cpu/mpc83xx/ecc.c +++ b/arch/powerpc/cpu/mpc83xx/ecc.c @@ -96,7 +96,7 @@ void ecc_print_status(void) ddr->capture_attributes & ECC_CAPT_ATTR_VLD); } -int do_ecc(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_ecc(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { immap_t *immap = (immap_t *) CONFIG_SYS_IMMR; #ifdef CONFIG_SYS_FSL_DDR2 diff --git a/arch/powerpc/cpu/mpc83xx/interrupts.c b/arch/powerpc/cpu/mpc83xx/interrupts.c index e83895deab..8d525dc837 100644 --- a/arch/powerpc/cpu/mpc83xx/interrupts.c +++ b/arch/powerpc/cpu/mpc83xx/interrupts.c @@ -71,8 +71,8 @@ void timer_interrupt_cpu (struct pt_regs *regs) * irqinfo - print information about PCI devices */ -void -do_irqinfo(cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char * const argv[]) +void do_irqinfo(struct cmd_tbl *cmdtp, bd_t *bd, int flag, int argc, + char *const argv[]) { } diff --git a/arch/powerpc/cpu/mpc83xx/speed.c b/arch/powerpc/cpu/mpc83xx/speed.c index e2fc0b1e8a..5c14aa1f32 100644 --- a/arch/powerpc/cpu/mpc83xx/speed.c +++ b/arch/powerpc/cpu/mpc83xx/speed.c @@ -523,7 +523,8 @@ int get_serial_clock(void) return get_bus_freq(0); } -static int do_clocks(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_clocks(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char buf[32]; diff --git a/arch/powerpc/cpu/mpc85xx/cmd_errata.c b/arch/powerpc/cpu/mpc85xx/cmd_errata.c index d3167f6cb9..ff73596ba9 100644 --- a/arch/powerpc/cpu/mpc85xx/cmd_errata.c +++ b/arch/powerpc/cpu/mpc85xx/cmd_errata.c @@ -129,7 +129,8 @@ static void check_erratum_a007212(void) } #endif -static int do_errata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_errata(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { #ifdef CONFIG_SYS_FSL_ERRATUM_NMG_CPU_A011 extern int enable_cpu_a011_workaround; diff --git a/arch/powerpc/cpu/mpc85xx/cpu.c b/arch/powerpc/cpu/mpc85xx/cpu.c index eff0d5d7e2..10c4bb91d7 100644 --- a/arch/powerpc/cpu/mpc85xx/cpu.c +++ b/arch/powerpc/cpu/mpc85xx/cpu.c @@ -295,7 +295,7 @@ int checkcpu (void) /* ------------------------------------------------------------------------- */ -int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* Everything after the first generation of PQ3 parts has RSTCR */ #if defined(CONFIG_ARCH_MPC8540) || defined(CONFIG_ARCH_MPC8541) || \ diff --git a/arch/powerpc/cpu/mpc85xx/interrupts.c b/arch/powerpc/cpu/mpc85xx/interrupts.c index 6f539d2677..43f7919b04 100644 --- a/arch/powerpc/cpu/mpc85xx/interrupts.c +++ b/arch/powerpc/cpu/mpc85xx/interrupts.c @@ -102,7 +102,7 @@ void timer_interrupt_cpu(struct pt_regs *regs) #if defined(CONFIG_CMD_IRQ) /* irqinfo - print information about PCI devices,not implemented. */ -int do_irqinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_irqinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { return 0; } diff --git a/arch/powerpc/cpu/mpc85xx/mp.c b/arch/powerpc/cpu/mpc85xx/mp.c index 9757bffe02..0f8c8cd667 100644 --- a/arch/powerpc/cpu/mpc85xx/mp.c +++ b/arch/powerpc/cpu/mpc85xx/mp.c @@ -140,7 +140,7 @@ static u8 boot_entry_map[4] = { BOOT_ENTRY_R3_LOWER, }; -int cpu_release(u32 nr, int argc, char * const argv[]) +int cpu_release(u32 nr, int argc, char *const argv[]) { u32 i, val, *table = (u32 *)&__spin_table + nr * NUM_BOOT_ENTRY; u64 boot_addr; diff --git a/arch/powerpc/cpu/mpc86xx/cpu.c b/arch/powerpc/cpu/mpc86xx/cpu.c index 97b93f0213..fe35744b70 100644 --- a/arch/powerpc/cpu/mpc86xx/cpu.c +++ b/arch/powerpc/cpu/mpc86xx/cpu.c @@ -107,7 +107,7 @@ checkcpu(void) } -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { volatile immap_t *immap = (immap_t *)CONFIG_SYS_IMMR; volatile ccsr_gur_t *gur = &immap->im_gur; diff --git a/arch/powerpc/cpu/mpc86xx/interrupts.c b/arch/powerpc/cpu/mpc86xx/interrupts.c index eb8e73e41c..8e4a66d23e 100644 --- a/arch/powerpc/cpu/mpc86xx/interrupts.c +++ b/arch/powerpc/cpu/mpc86xx/interrupts.c @@ -100,7 +100,7 @@ void irq_free_handler(int vec) /* * irqinfo - print information about PCI devices,not implemented. */ -int do_irqinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_irqinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { return 0; } diff --git a/arch/powerpc/cpu/mpc86xx/mp.c b/arch/powerpc/cpu/mpc86xx/mp.c index 07c4c079df..08d11ad4f2 100644 --- a/arch/powerpc/cpu/mpc86xx/mp.c +++ b/arch/powerpc/cpu/mpc86xx/mp.c @@ -67,7 +67,7 @@ int is_core_disabled(int nr) { return 0; } -int cpu_release(u32 nr, int argc, char * const argv[]) +int cpu_release(u32 nr, int argc, char *const argv[]) { /* dummy function so common/cmd_mp.c will build * should be implemented in the future */ diff --git a/arch/powerpc/cpu/mpc8xx/cpu.c b/arch/powerpc/cpu/mpc8xx/cpu.c index 9d6c08f17a..1b7c7fa01b 100644 --- a/arch/powerpc/cpu/mpc8xx/cpu.c +++ b/arch/powerpc/cpu/mpc8xx/cpu.c @@ -195,7 +195,7 @@ void upmconfig(uint upm, uint *table, uint size) /* ------------------------------------------------------------------------- */ -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ulong msr, addr; diff --git a/arch/powerpc/cpu/mpc8xx/immap.c b/arch/powerpc/cpu/mpc8xx/immap.c index 442c01ac6f..e5b62e9f4a 100644 --- a/arch/powerpc/cpu/mpc8xx/immap.c +++ b/arch/powerpc/cpu/mpc8xx/immap.c @@ -18,7 +18,8 @@ DECLARE_GLOBAL_DATA_PTR; -static int do_siuinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_siuinfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR; sysconf8xx_t __iomem *sc = &immap->im_siu_conf; @@ -35,8 +36,8 @@ static int do_siuinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return 0; } -static int do_memcinfo(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_memcinfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR; memctl8xx_t __iomem *memctl = &immap->im_memctl; @@ -58,7 +59,8 @@ static int do_memcinfo(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_carinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_carinfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR; car8xx_t __iomem *car = &immap->im_clkrst; @@ -119,7 +121,8 @@ static void binary(char *label, uint value, int nbits) #define PC_NBITS 12 #define PD_NBITS 13 -static int do_iopinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_iopinfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR; iop8xx_t __iomem *iop = &immap->im_ioport; @@ -172,7 +175,8 @@ static int do_iopinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * this needs a clean up for smaller tighter code * use *uint and set the address based on cmd + port */ -static int do_iopset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_iopset(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { uint rcode = 0; iopin_t iopin; @@ -328,7 +332,8 @@ static void prbrg(int n, uint val) putc('\n'); } -static int do_brginfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_brginfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { immap_t __iomem *immap = (immap_t __iomem *)CONFIG_SYS_IMMR; cpm8xx_t __iomem *cp = &immap->im_cpm; diff --git a/arch/powerpc/lib/bootm.c b/arch/powerpc/lib/bootm.c index 8aec8c9fd3..59062ca654 100644 --- a/arch/powerpc/lib/bootm.c +++ b/arch/powerpc/lib/bootm.c @@ -232,8 +232,8 @@ static int boot_body_linux(bootm_headers_t *images) return 0; } -noinline -int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *images) +noinline int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { int ret; diff --git a/arch/powerpc/lib/kgdb.c b/arch/powerpc/lib/kgdb.c index f580c023e5..4a3e26cffc 100644 --- a/arch/powerpc/lib/kgdb.c +++ b/arch/powerpc/lib/kgdb.c @@ -252,7 +252,7 @@ kgdb_putregs(struct pt_regs *regs, char *buf, int length) the debugger. */ void -kgdb_breakpoint(int argc, char * const argv[]) +kgdb_breakpoint(int argc, char *const argv[]) { asm(" .globl breakinst\n\ breakinst: .long 0x7d821008\n\ diff --git a/arch/riscv/lib/boot.c b/arch/riscv/lib/boot.c index 42b15a13a2..778d011f7c 100644 --- a/arch/riscv/lib/boot.c +++ b/arch/riscv/lib/boot.c @@ -8,7 +8,7 @@ #include unsigned long do_go_exec(ulong (*entry)(int, char * const []), - int argc, char * const argv[]) + int argc, char *const argv[]) { cleanup_before_linux(); diff --git a/arch/riscv/lib/bootm.c b/arch/riscv/lib/bootm.c index c24aba1dc9..98f2c76860 100644 --- a/arch/riscv/lib/bootm.c +++ b/arch/riscv/lib/bootm.c @@ -106,7 +106,7 @@ static void boot_jump_linux(bootm_headers_t *images, int flag) } } -int do_bootm_linux(int flag, int argc, char * const argv[], +int do_bootm_linux(int flag, int argc, char *const argv[], bootm_headers_t *images) { /* No need for those on RISC-V */ @@ -128,7 +128,7 @@ int do_bootm_linux(int flag, int argc, char * const argv[], return 0; } -int do_bootm_vxworks(int flag, int argc, char * const argv[], +int do_bootm_vxworks(int flag, int argc, char *const argv[], bootm_headers_t *images) { return do_bootm_linux(flag, argc, argv, images); diff --git a/arch/riscv/lib/reset.c b/arch/riscv/lib/reset.c index ce3c1cf872..8779c619cc 100644 --- a/arch/riscv/lib/reset.c +++ b/arch/riscv/lib/reset.c @@ -7,7 +7,7 @@ #include #include -int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { printf("resetting ...\n"); diff --git a/arch/sh/cpu/sh4/cpu.c b/arch/sh/cpu/sh4/cpu.c index e94e980c0e..f032d88159 100644 --- a/arch/sh/cpu/sh4/cpu.c +++ b/arch/sh/cpu/sh4/cpu.c @@ -29,7 +29,7 @@ int cleanup_before_linux (void) return 0; } -int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { disable_interrupts(); reset_cpu(0); diff --git a/arch/sh/lib/bootm.c b/arch/sh/lib/bootm.c index 5f14a04ab4..dc94f83785 100644 --- a/arch/sh/lib/bootm.c +++ b/arch/sh/lib/bootm.c @@ -9,6 +9,7 @@ #include #include +#include #include #include #include @@ -50,7 +51,8 @@ static unsigned long sh_check_cmd_arg(char *cmdline, char *key, int base) return val; } -int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *images) +int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { /* Linux kernel load address */ void (*kernel) (void) = (void (*)(void))images->ep; diff --git a/arch/sh/lib/zimageboot.c b/arch/sh/lib/zimageboot.c index 602776a474..c38f0933f8 100644 --- a/arch/sh/lib/zimageboot.c +++ b/arch/sh/lib/zimageboot.c @@ -10,11 +10,14 @@ */ #include +#include +#include #include #include #include -int do_sh_zimageboot (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_sh_zimageboot(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong (*zboot_entry)(int, char * const []) = NULL; char *s0, *s1; diff --git a/arch/x86/include/asm/arch-braswell/fsp/fsp_vpd.h b/arch/x86/include/asm/arch-braswell/fsp/fsp_vpd.h index a3bde3d8e7..f2260ae90e 100644 --- a/arch/x86/include/asm/arch-braswell/fsp/fsp_vpd.h +++ b/arch/x86/include/asm/arch-braswell/fsp/fsp_vpd.h @@ -7,6 +7,8 @@ #ifndef __FSP_VPD_H__ #define __FSP_VPD_H__ +#include + struct __packed memory_upd { u64 signature; /* Offset 0x0020 */ u8 revision; /* Offset 0x0028 */ diff --git a/arch/x86/lib/bootm.c b/arch/x86/lib/bootm.c index 0837655e12..1569d30f8e 100644 --- a/arch/x86/lib/bootm.c +++ b/arch/x86/lib/bootm.c @@ -206,8 +206,8 @@ static int boot_jump_linux(bootm_headers_t *images) images->os.arch == IH_ARCH_X86_64); } -int do_bootm_linux(int flag, int argc, char * const argv[], - bootm_headers_t *images) +int do_bootm_linux(int flag, int argc, char *const argv[], + bootm_headers_t *images) { /* No need for those on x86 */ if (flag & BOOTM_STATE_OS_BD_T || flag & BOOTM_STATE_OS_CMDLINE) diff --git a/arch/x86/lib/cmd_boot.c b/arch/x86/lib/cmd_boot.c index 9fce021c79..baaf3d13ad 100644 --- a/arch/x86/lib/cmd_boot.c +++ b/arch/x86/lib/cmd_boot.c @@ -22,7 +22,7 @@ DECLARE_GLOBAL_DATA_PTR; unsigned long do_go_exec(ulong (*entry)(int, char * const []), - int argc, char * const argv[]) + int argc, char *const argv[]) { unsigned long ret = 0; char **argv_tmp; diff --git a/arch/x86/lib/interrupts.c b/arch/x86/lib/interrupts.c index b23b8fd402..40ba7fcfec 100644 --- a/arch/x86/lib/interrupts.c +++ b/arch/x86/lib/interrupts.c @@ -127,7 +127,7 @@ void do_irq(int hw_irq) #endif #if defined(CONFIG_CMD_IRQ) -int do_irqinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_irqinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { #if !CONFIG_IS_ENABLED(X86_64) int irq; diff --git a/arch/x86/lib/zimage.c b/arch/x86/lib/zimage.c index ffc09630b7..64d14e8911 100644 --- a/arch/x86/lib/zimage.c +++ b/arch/x86/lib/zimage.c @@ -13,6 +13,7 @@ */ #include +#include #include #include #include @@ -310,7 +311,7 @@ void __setup_pcat_compatibility(void) { } -int do_zboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +int do_zboot(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct boot_params *base_ptr; void *bzImage_addr = NULL; diff --git a/board/Arcturus/ucp1020/cmd_arc.c b/board/Arcturus/ucp1020/cmd_arc.c index 2b4853f8f9..3656cf4cbc 100644 --- a/board/Arcturus/ucp1020/cmd_arc.c +++ b/board/Arcturus/ucp1020/cmd_arc.c @@ -9,6 +9,7 @@ */ #include +#include #include #include #include @@ -376,7 +377,8 @@ void get_arc_info(void) do_get_arc_info(); } -static int do_arc_cmd(cmd_tbl_t * cmdtp, int flag, int argc, char *const argv[]) +static int do_arc_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *cmd; int ret = -1; diff --git a/board/BuS/eb_cpu5282/eb_cpu5282.c b/board/BuS/eb_cpu5282/eb_cpu5282.c index a667413bfc..1d05e40c20 100644 --- a/board/BuS/eb_cpu5282/eb_cpu5282.c +++ b/board/BuS/eb_cpu5282/eb_cpu5282.c @@ -226,7 +226,7 @@ int drv_video_init(void) /*---------------------------------------------------------------------------*/ #ifdef CONFIG_VIDEO -int do_brightness(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_brightness(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rcode = 0; ulong side; diff --git a/board/LaCie/net2big_v2/net2big_v2.c b/board/LaCie/net2big_v2/net2big_v2.c index 8b97e1a533..dbd8b5755d 100644 --- a/board/LaCie/net2big_v2/net2big_v2.c +++ b/board/LaCie/net2big_v2/net2big_v2.c @@ -246,7 +246,8 @@ void reset_phy(void) #if defined(CONFIG_KIRKWOOD_GPIO) /* Return GPIO push button status */ static int -do_read_push_button(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_read_push_button(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { return !kw_gpio_get_value(NET2BIG_V2_GPIO_PUSH_BUTTON); } diff --git a/board/LaCie/netspace_v2/netspace_v2.c b/board/LaCie/netspace_v2/netspace_v2.c index f9bf527739..011cc563d1 100644 --- a/board/LaCie/netspace_v2/netspace_v2.c +++ b/board/LaCie/netspace_v2/netspace_v2.c @@ -110,7 +110,7 @@ void reset_phy(void) #if defined(CONFIG_KIRKWOOD_GPIO) /* Return GPIO button status */ static int -do_read_button(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_read_button(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { return kw_gpio_get_value(NETSPACE_V2_GPIO_BUTTON); } diff --git a/board/Synology/ds414/cmd_syno.c b/board/Synology/ds414/cmd_syno.c index bd6eefd773..a120c3123f 100644 --- a/board/Synology/ds414/cmd_syno.c +++ b/board/Synology/ds414/cmd_syno.c @@ -6,6 +6,7 @@ */ #include +#include #include #include #include @@ -21,7 +22,7 @@ #define SYNO_CHKSUM_TAG "CHK=" -static int do_syno_populate(int argc, char * const argv[]) +static int do_syno_populate(int argc, char *const argv[]) { unsigned int bus = CONFIG_SF_DEFAULT_BUS; unsigned int cs = CONFIG_SF_DEFAULT_CS; @@ -152,7 +153,7 @@ static const char * const pwr_mng_bit_func[] = { NULL, }; -static int do_syno_clk_gate(int argc, char * const argv[]) +static int do_syno_clk_gate(int argc, char *const argv[]) { u32 pwr_mng_ctrl_reg = reg_read(POWER_MNG_CTRL_REG); const char *func, *state; @@ -195,8 +196,8 @@ static int do_syno_clk_gate(int argc, char * const argv[]) return 0; } -static int do_syno(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_syno(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *cmd; int ret = 0; diff --git a/board/advantech/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c b/board/advantech/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c index 772e21b9c5..6168dc9220 100644 --- a/board/advantech/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c +++ b/board/advantech/imx8qm_rom7720_a1/imx8qm_rom7720_a1.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/amlogic/sei510/sei510.c b/board/amlogic/sei510/sei510.c index 70fe3559f6..5a5148ea68 100644 --- a/board/amlogic/sei510/sei510.c +++ b/board/amlogic/sei510/sei510.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/amlogic/sei610/sei610.c b/board/amlogic/sei610/sei610.c index 3c44fba516..27dba93582 100644 --- a/board/amlogic/sei610/sei610.c +++ b/board/amlogic/sei610/sei610.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/aristainetos/aristainetos.c b/board/aristainetos/aristainetos.c index 3a59b51c1c..14931120f6 100644 --- a/board/aristainetos/aristainetos.c +++ b/board/aristainetos/aristainetos.c @@ -9,6 +9,7 @@ * Author: Fabio Estevam */ +#include #include #include #include diff --git a/board/bosch/guardian/board.c b/board/bosch/guardian/board.c index b8dbe8ac53..1d8fa78154 100644 --- a/board/bosch/guardian/board.c +++ b/board/bosch/guardian/board.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include #include diff --git a/board/boundary/nitrogen6x/nitrogen6x.c b/board/boundary/nitrogen6x/nitrogen6x.c index 8e29fd0095..92a7a2fc6e 100644 --- a/board/boundary/nitrogen6x/nitrogen6x.c +++ b/board/boundary/nitrogen6x/nitrogen6x.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -988,7 +989,7 @@ static int read_keys(char *buf) return numpressed; } -static int do_kbd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_kbd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { char envvalue[ARRAY_SIZE(buttons)+1]; int numpressed = read_keys(envvalue); diff --git a/board/buffalo/lsxl/lsxl.c b/board/buffalo/lsxl/lsxl.c index 6afb6bbdb5..712ef11666 100644 --- a/board/buffalo/lsxl/lsxl.c +++ b/board/buffalo/lsxl/lsxl.c @@ -9,6 +9,7 @@ #include #include +#include #include #include #include diff --git a/board/cavium/thunderx/atf.c b/board/cavium/thunderx/atf.c index ea2f2bade0..f01ead4e23 100644 --- a/board/cavium/thunderx/atf.c +++ b/board/cavium/thunderx/atf.c @@ -4,6 +4,7 @@ **/ #include +#include #include #include @@ -224,7 +225,7 @@ static void atf_print_part_table(void) } } -int do_atf(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_atf(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ssize_t ret; size_t size, offset; diff --git a/board/corscience/tricorder/tricorder-eeprom.c b/board/corscience/tricorder/tricorder-eeprom.c index 23c2ea9186..192af304d9 100644 --- a/board/corscience/tricorder/tricorder-eeprom.c +++ b/board/corscience/tricorder/tricorder-eeprom.c @@ -5,6 +5,7 @@ * Andreas Bießmann */ #include +#include #include #include #include @@ -186,7 +187,7 @@ int tricorder_eeprom_write(unsigned devaddr, const char *name, return ret; } -int do_tricorder_eeprom(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) +int do_tricorder_eeprom(struct cmd_tbl *cmdtp, int flag, int argc, char *argv[]) { if (argc == 3) { ulong dev_addr = simple_strtoul(argv[2], NULL, 16); diff --git a/board/egnite/ethernut5/ethernut5_pwrman.c b/board/egnite/ethernut5/ethernut5_pwrman.c index aa99d29c21..7dbb6e8f2b 100644 --- a/board/egnite/ethernut5/ethernut5_pwrman.c +++ b/board/egnite/ethernut5/ethernut5_pwrman.c @@ -32,6 +32,7 @@ * http://www.ethernut.de/ */ #include +#include #include #include #include @@ -215,7 +216,7 @@ void ethernut5_print_voltage(void) /* * Process the board specific 'pwrman' command. */ -int do_pwrman(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_pwrman(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { u8 val; int i; diff --git a/board/esd/vme8349/caddy.c b/board/esd/vme8349/caddy.c index db8d7bfe9b..ba91f4b3c8 100644 --- a/board/esd/vme8349/caddy.c +++ b/board/esd/vme8349/caddy.c @@ -7,6 +7,7 @@ */ #include +#include #include #include #include @@ -36,7 +37,7 @@ void generate_answer(struct caddy_cmd *cmd, uint32_t status, uint32_t *result) caddy_interface->answer_in = ptr; } -int do_caddy(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_caddy(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { unsigned long base_addr; uint32_t ptr; diff --git a/board/freescale/c29xpcie/cpld.c b/board/freescale/c29xpcie/cpld.c index f57047d1d3..b864a60c44 100644 --- a/board/freescale/c29xpcie/cpld.c +++ b/board/freescale/c29xpcie/cpld.c @@ -89,7 +89,7 @@ static void cpld_dump_regs(void) #endif #ifndef CONFIG_SPL_BUILD -int cpld_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int cpld_cmd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; unsigned char value; diff --git a/board/freescale/common/cmd_esbc_validate.c b/board/freescale/common/cmd_esbc_validate.c index 36b620ca23..638aa3c19a 100644 --- a/board/freescale/common/cmd_esbc_validate.c +++ b/board/freescale/common/cmd_esbc_validate.c @@ -8,8 +8,8 @@ #include #include -int do_esbc_halt(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_esbc_halt(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (fsl_check_boot_mode_secure() == 0) { printf("Boot Mode is Non-Secure. Not entering spin loop.\n"); @@ -24,8 +24,8 @@ loop: } #ifndef CONFIG_SPL_BUILD -static int do_esbc_validate(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_esbc_validate(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *hash_str = NULL; uintptr_t haddr; diff --git a/board/freescale/common/ngpixis.c b/board/freescale/common/ngpixis.c index d7254010bf..37a6f775a0 100644 --- a/board/freescale/common/ngpixis.c +++ b/board/freescale/common/ngpixis.c @@ -171,7 +171,8 @@ void pixis_sysclk_set(unsigned long sysclk) PIXIS_WRITE(sclk[2], sclk2); } -int pixis_reset_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int pixis_reset_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned int i; unsigned long sysclk; diff --git a/board/freescale/common/pixis.c b/board/freescale/common/pixis.c index e9b7127833..4127fbc139 100644 --- a/board/freescale/common/pixis.c +++ b/board/freescale/common/pixis.c @@ -266,8 +266,8 @@ static void set_px_go_with_watchdog(void) /* Disable the watchdog * */ -static int pixis_disable_watchdog_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int pixis_disable_watchdog_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* Disable the VELA sequencer and the watchdog */ clrbits_8(pixis_base + PIXIS_VCTL, 9); @@ -285,7 +285,8 @@ U_BOOT_CMD( /* Enable or disable SGMII mode for a TSEC */ -static int pixis_set_sgmii(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int pixis_set_sgmii(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int which_tsec = -1; unsigned char mask; @@ -411,7 +412,8 @@ static unsigned long strfractoint(char *strptr) return intval + decval; } -static int pixis_reset_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int pixis_reset_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned int i; char *p_cf = NULL; diff --git a/board/freescale/common/qixis.c b/board/freescale/common/qixis.c index dd1ee90b3c..591203132f 100644 --- a/board/freescale/common/qixis.c +++ b/board/freescale/common/qixis.c @@ -233,7 +233,8 @@ void __weak qixis_dump_switch(void) puts("Reverse engineering switch is not implemented for this board\n"); } -static int qixis_reset_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int qixis_reset_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int i; diff --git a/board/freescale/common/sys_eeprom.c b/board/freescale/common/sys_eeprom.c index 71af645b03..b3421052a5 100644 --- a/board/freescale/common/sys_eeprom.c +++ b/board/freescale/common/sys_eeprom.c @@ -383,7 +383,7 @@ static void set_mac_address(unsigned int index, const char *string) update_crc(); } -int do_mac(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_mac(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { char cmd; diff --git a/board/freescale/common/vid.c b/board/freescale/common/vid.c index 20852476dd..dfc6a91d1a 100644 --- a/board/freescale/common/vid.c +++ b/board/freescale/common/vid.c @@ -925,9 +925,9 @@ exit: } -static int do_vdd_override(cmd_tbl_t *cmdtp, +static int do_vdd_override(struct cmd_tbl *cmdtp, int flag, int argc, - char * const argv[]) + char *const argv[]) { ulong override; @@ -941,9 +941,8 @@ static int do_vdd_override(cmd_tbl_t *cmdtp, return 0; } -static int do_vdd_read(cmd_tbl_t *cmdtp, - int flag, int argc, - char * const argv[]) +static int do_vdd_read(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc < 1) return CMD_RET_USAGE; diff --git a/board/freescale/imx8mm_evk/imx8mm_evk.c b/board/freescale/imx8mm_evk/imx8mm_evk.c index 1f95f3b0c4..c43af9bc48 100644 --- a/board/freescale/imx8mm_evk/imx8mm_evk.c +++ b/board/freescale/imx8mm_evk/imx8mm_evk.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/freescale/imx8mm_evk/spl.c b/board/freescale/imx8mm_evk/spl.c index 3abf6be482..42b637be5c 100644 --- a/board/freescale/imx8mm_evk/spl.c +++ b/board/freescale/imx8mm_evk/spl.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/freescale/imx8mn_evk/imx8mn_evk.c b/board/freescale/imx8mn_evk/imx8mn_evk.c index 8bd54ea2aa..ea02bb75f4 100644 --- a/board/freescale/imx8mn_evk/imx8mn_evk.c +++ b/board/freescale/imx8mn_evk/imx8mn_evk.c @@ -4,6 +4,7 @@ */ #include +#include #include DECLARE_GLOBAL_DATA_PTR; diff --git a/board/freescale/imx8mn_evk/spl.c b/board/freescale/imx8mn_evk/spl.c index fae1f0c9c7..486863e367 100644 --- a/board/freescale/imx8mn_evk/spl.c +++ b/board/freescale/imx8mn_evk/spl.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/board/freescale/imx8mp_evk/imx8mp_evk.c b/board/freescale/imx8mp_evk/imx8mp_evk.c index aa5100f5bf..97ba15645a 100644 --- a/board/freescale/imx8mp_evk/imx8mp_evk.c +++ b/board/freescale/imx8mp_evk/imx8mp_evk.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/freescale/imx8mp_evk/spl.c b/board/freescale/imx8mp_evk/spl.c index e84e470ac2..e03c2c1118 100644 --- a/board/freescale/imx8mp_evk/spl.c +++ b/board/freescale/imx8mp_evk/spl.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/board/freescale/imxrt1020-evk/imxrt1020-evk.c b/board/freescale/imxrt1020-evk/imxrt1020-evk.c index 06ad524d5d..08f6ca9c52 100644 --- a/board/freescale/imxrt1020-evk/imxrt1020-evk.c +++ b/board/freescale/imxrt1020-evk/imxrt1020-evk.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/freescale/ls1012ardb/ls1012ardb.c b/board/freescale/ls1012ardb/ls1012ardb.c index fc929c441c..5b814f7abf 100644 --- a/board/freescale/ls1012ardb/ls1012ardb.c +++ b/board/freescale/ls1012ardb/ls1012ardb.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -394,8 +395,8 @@ static int convert_flash_bank(int bank) return ret; } -static int flash_bank_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int flash_bank_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 2) return CMD_RET_USAGE; diff --git a/board/freescale/ls1021atwr/ls1021atwr.c b/board/freescale/ls1021atwr/ls1021atwr.c index acf146de4d..c7f7baa8e6 100644 --- a/board/freescale/ls1021atwr/ls1021atwr.c +++ b/board/freescale/ls1021atwr/ls1021atwr.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include @@ -612,8 +613,8 @@ static void convert_flash_bank(char bank) cpld_data->system_rst = CONFIG_RESET; } -static int flash_bank_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int flash_bank_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 2) return CMD_RET_USAGE; @@ -633,8 +634,8 @@ U_BOOT_CMD( "bank[0-upper bank/1-lower bank] (e.g. boot_bank 0)" ); -static int cpld_reset_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int cpld_reset_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct cpld_data *cpld_data = (void *)(CONFIG_SYS_CPLD_BASE); @@ -692,8 +693,8 @@ static void print_serdes_mux(void) printf("B.\n"); } -static int serdes_mux_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int serdes_mux_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 2) return CMD_RET_USAGE; diff --git a/board/freescale/ls1043ardb/cpld.c b/board/freescale/ls1043ardb/cpld.c index 00c70b1e49..5d2e8015a0 100644 --- a/board/freescale/ls1043ardb/cpld.c +++ b/board/freescale/ls1043ardb/cpld.c @@ -133,7 +133,7 @@ void cpld_rev_bit(unsigned char *value) *value = rev_val; } -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/ls1046ardb/cpld.c b/board/freescale/ls1046ardb/cpld.c index a65751986a..548601a5ae 100644 --- a/board/freescale/ls1046ardb/cpld.c +++ b/board/freescale/ls1046ardb/cpld.c @@ -129,7 +129,7 @@ void cpld_rev_bit(unsigned char *value) *value = rev_val; } -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/p1010rdb/p1010rdb.c b/board/freescale/p1010rdb/p1010rdb.c index 1adc898441..66ccc0bd1e 100644 --- a/board/freescale/p1010rdb/p1010rdb.c +++ b/board/freescale/p1010rdb/p1010rdb.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -708,8 +709,8 @@ int misc_init_r(void) } #ifndef CONFIG_SPL_BUILD -static int pin_mux_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int pin_mux_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc < 2) return CMD_RET_USAGE; diff --git a/board/freescale/p2041rdb/cpld.c b/board/freescale/p2041rdb/cpld.c index 3037ef89f1..b042fe3bcb 100644 --- a/board/freescale/p2041rdb/cpld.c +++ b/board/freescale/p2041rdb/cpld.c @@ -87,7 +87,7 @@ static void cpld_dump_regs(void) } #endif -int cpld_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int cpld_cmd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/t102xrdb/cpld.c b/board/freescale/t102xrdb/cpld.c index 2b640e0450..47c3b1627e 100644 --- a/board/freescale/t102xrdb/cpld.c +++ b/board/freescale/t102xrdb/cpld.c @@ -72,7 +72,7 @@ static void cpld_dump_regs(void) putc('\n'); } -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/t102xrdb/t102xrdb.c b/board/freescale/t102xrdb/t102xrdb.c index 983c723a10..754fcb0ad5 100644 --- a/board/freescale/t102xrdb/t102xrdb.c +++ b/board/freescale/t102xrdb/t102xrdb.c @@ -368,8 +368,8 @@ static u32 t1023rdb_ctrl(u32 ctrl_type) return 0; } -static int switch_cmd(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int switch_cmd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc < 2) return CMD_RET_USAGE; diff --git a/board/freescale/t104xrdb/cpld.c b/board/freescale/t104xrdb/cpld.c index f9c8ab3752..ac34095f3b 100644 --- a/board/freescale/t104xrdb/cpld.c +++ b/board/freescale/t104xrdb/cpld.c @@ -82,7 +82,7 @@ static void cpld_dump_regs(void) } #endif -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/t208xrdb/cpld.c b/board/freescale/t208xrdb/cpld.c index 9a9b9d8e77..b9ba62adff 100644 --- a/board/freescale/t208xrdb/cpld.c +++ b/board/freescale/t208xrdb/cpld.c @@ -43,7 +43,7 @@ void cpld_set_defbank(void) CPLD_WRITE(reset_ctl, CPLD_LBMAP_RESET); } -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/freescale/t4qds/t4240qds.c b/board/freescale/t4qds/t4240qds.c index 0b00ec6e29..08ecf9a636 100644 --- a/board/freescale/t4qds/t4240qds.c +++ b/board/freescale/t4qds/t4240qds.c @@ -902,9 +902,9 @@ void qixis_dump_switch(void) } } -static int do_vdd_adjust(cmd_tbl_t *cmdtp, +static int do_vdd_adjust(struct cmd_tbl *cmdtp, int flag, int argc, - char * const argv[]) + char *const argv[]) { ulong override; diff --git a/board/freescale/t4rdb/cpld.c b/board/freescale/t4rdb/cpld.c index 470b5f9154..d484509bc2 100644 --- a/board/freescale/t4rdb/cpld.c +++ b/board/freescale/t4rdb/cpld.c @@ -95,7 +95,7 @@ static void cpld_dump_regs(void) #endif #ifndef CONFIG_SPL_BUILD -int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int rc = 0; diff --git a/board/gardena/smart-gateway-mt7688/board.c b/board/gardena/smart-gateway-mt7688/board.c index 89844ee69e..768e7acc35 100644 --- a/board/gardena/smart-gateway-mt7688/board.c +++ b/board/gardena/smart-gateway-mt7688/board.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -206,7 +207,7 @@ static void copy_or_generate_uuid(char *fd_ptr, const char *env_var_name) * Helper function to provide some sane factory-data values for testing * purpose, when these values are not programmed correctly */ -int do_fd_write(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_fd_write(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct factory_data_values *fd; struct spi_flash *sf; diff --git a/board/gateworks/gw_ventana/eeprom.c b/board/gateworks/gw_ventana/eeprom.c index 5e9cf11575..a833657b15 100644 --- a/board/gateworks/gw_ventana/eeprom.c +++ b/board/gateworks/gw_ventana/eeprom.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -158,7 +159,8 @@ static struct ventana_eeprom_config *get_config(const char *name) static u8 econfig_bytes[sizeof(ventana_info.config)]; static int econfig_init = -1; -static int do_econfig(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_econfig(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct ventana_eeprom_config *cfg; struct ventana_board_info *info = &ventana_info; diff --git a/board/gateworks/gw_ventana/gsc.c b/board/gateworks/gw_ventana/gsc.c index 068f8cd9e7..6d9565ccfe 100644 --- a/board/gateworks/gw_ventana/gsc.c +++ b/board/gateworks/gw_ventana/gsc.c @@ -5,6 +5,7 @@ * Author: Tim Harvey */ +#include #include #include #include @@ -176,8 +177,8 @@ int gsc_boot_wd_disable(void) } #if defined(CONFIG_CMD_GSC) && !defined(CONFIG_SPL_BUILD) -static int do_gsc_sleep(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_gsc_sleep(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned char reg; unsigned long secs = 0; @@ -218,7 +219,8 @@ error: return CMD_RET_FAILURE; } -static int do_gsc_wd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_gsc_wd(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned char reg; @@ -257,7 +259,7 @@ static int do_gsc_wd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_SUCCESS; } -static int do_gsc(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_gsc(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc < 2) return gsc_info(1); diff --git a/board/gdsys/a38x/controlcenterdc.c b/board/gdsys/a38x/controlcenterdc.c index 7aad683127..0d53d69ecc 100644 --- a/board/gdsys/a38x/controlcenterdc.c +++ b/board/gdsys/a38x/controlcenterdc.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/board/gdsys/a38x/hydra.c b/board/gdsys/a38x/hydra.c index fa50ad2830..daade6da0a 100644 --- a/board/gdsys/a38x/hydra.c +++ b/board/gdsys/a38x/hydra.c @@ -1,4 +1,5 @@ #include +#include #include /* ctrlc */ #include @@ -89,7 +90,7 @@ void hydra_initialize(void) #define REFL_PATTERN (0xdededede) #define REFL_PATTERN_INV (~REFL_PATTERN) -int do_hydrate(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_hydrate(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uint k = 0; void __iomem *pcie2_base = (void __iomem *)(MVEBU_REG_PCIE_BASE + diff --git a/board/gdsys/common/cmd_ioloop.c b/board/gdsys/common/cmd_ioloop.c index 05a14ff103..88ab8233d5 100644 --- a/board/gdsys/common/cmd_ioloop.c +++ b/board/gdsys/common/cmd_ioloop.c @@ -264,7 +264,7 @@ static void io_reflect(struct udevice *dev) * Syntax: * ioreflect {fpga} {reportrate} */ -int do_ioreflect(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_ioreflect(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uint fpga; uint rate = 0; @@ -321,7 +321,7 @@ int do_ioreflect(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * Syntax: * ioreflect {reportrate} */ -int do_ioreflect(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_ioreflect(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *fpga; struct regmap *map; @@ -374,7 +374,7 @@ int do_ioreflect(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * Syntax: * ioloop {fpga} {size} {rate} */ -int do_ioloop(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_ioloop(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uint fpga; uint size; @@ -440,7 +440,7 @@ int do_ioloop(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * Syntax: * ioloop {size} {rate} */ -int do_ioloop(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_ioloop(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uint size; uint rate = 0; @@ -501,7 +501,7 @@ int do_ioloop(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #endif /* CONFIG_GDSYS_LEGACY_DRIVERS */ #ifndef CONFIG_GDSYS_LEGACY_DRIVERS -int do_iodev(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_iodev(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *ioep = NULL; struct udevice *board; diff --git a/board/gdsys/common/osd.c b/board/gdsys/common/osd.c index 10c4329146..cda0cc6b48 100644 --- a/board/gdsys/common/osd.c +++ b/board/gdsys/common/osd.c @@ -7,6 +7,7 @@ #ifdef CONFIG_GDSYS_LEGACY_DRIVERS #include +#include #include #include @@ -259,7 +260,8 @@ static int osd_write_videomem(unsigned screen, unsigned offset, return charcount; } -static int osd_print(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int osd_print(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned screen; @@ -396,7 +398,7 @@ int osd_probe(unsigned screen) return 0; } -int osd_write(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int osd_write(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { unsigned screen; @@ -449,7 +451,7 @@ int osd_write(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return 0; } -int osd_size(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int osd_size(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { unsigned screen; unsigned x; @@ -500,4 +502,4 @@ U_BOOT_CMD( ") size_y(max. " __stringify(MAX_Y_CHARS) ")\n" ); -#endif /* CONFIG_GDSYS_LEGACY_DRIVERS */ \ No newline at end of file +#endif /* CONFIG_GDSYS_LEGACY_DRIVERS */ diff --git a/board/gdsys/common/osd_cmd.c b/board/gdsys/common/osd_cmd.c index 53179b9811..fe6249794e 100644 --- a/board/gdsys/common/osd_cmd.c +++ b/board/gdsys/common/osd_cmd.c @@ -10,13 +10,14 @@ */ #include +#include #include #include #include #include -static int do_osd_write(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_osd_write(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dev; uint x, y; @@ -68,8 +69,8 @@ static int do_osd_write(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_osd_print(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_osd_print(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dev; uint x, y; @@ -99,8 +100,8 @@ static int do_osd_print(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_osd_size(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_osd_size(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dev; uint x, y; diff --git a/board/gdsys/mpc8308/gazerbeam.c b/board/gdsys/mpc8308/gazerbeam.c index 8c9636d292..b64a6d992d 100644 --- a/board/gdsys/mpc8308/gazerbeam.c +++ b/board/gdsys/mpc8308/gazerbeam.c @@ -7,6 +7,7 @@ #include #include +#include #include #include #include diff --git a/board/gdsys/p1022/controlcenterd.c b/board/gdsys/p1022/controlcenterd.c index b39b0b6002..e960fa71ac 100644 --- a/board/gdsys/p1022/controlcenterd.c +++ b/board/gdsys/p1022/controlcenterd.c @@ -223,7 +223,7 @@ void hw_watchdog_reset(void) } #ifdef CONFIG_TRAILBLAZER -int do_bootd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bootd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { return run_command(env_get("bootcmd"), flag); } diff --git a/board/google/chromebook_coral/coral.c b/board/google/chromebook_coral/coral.c index 4e34710b97..12d4fe63cb 100644 --- a/board/google/chromebook_coral/coral.c +++ b/board/google/chromebook_coral/coral.c @@ -4,6 +4,7 @@ */ #include +#include int arch_misc_init(void) { diff --git a/board/keymile/common/common.c b/board/keymile/common/common.c index 08f7f8d884..f592eba9e5 100644 --- a/board/keymile/common/common.c +++ b/board/keymile/common/common.c @@ -157,8 +157,8 @@ int board_eth_init(bd_t *bis) * read out the board id and the hw key from the intventory EEPROM and set * this values as environment variables. */ -static int do_setboardid(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_setboardid(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned char buf[32]; char *p; @@ -203,8 +203,8 @@ U_BOOT_CMD(km_setboardid, 1, 0, do_setboardid, "setboardid", "read out bid and " * application and in the init scripts (?) * return 0 in case of match, 1 if not match or error */ -static int do_checkboardidhwk(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_checkboardidhwk(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned long ivmbid = 0, ivmhwkey = 0; unsigned long envbid = 0, envhwkey = 0; @@ -344,8 +344,8 @@ U_BOOT_CMD(km_checkbidhwk, 2, 0, do_checkboardidhwk, * if the testpin of the board is asserted, return 1 * * else return 0 */ -static int do_checktestboot(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_checktestboot(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int testpin = 0; char *s = NULL; diff --git a/board/mediatek/mt7622/mt7622_rfb.c b/board/mediatek/mt7622/mt7622_rfb.c index 912b993240..6a5f936635 100644 --- a/board/mediatek/mt7622/mt7622_rfb.c +++ b/board/mediatek/mt7622/mt7622_rfb.c @@ -6,6 +6,7 @@ #include #include +#include #include DECLARE_GLOBAL_DATA_PTR; diff --git a/board/phytium/durian/durian.c b/board/phytium/durian/durian.c index 7dceebdeae..414360fe47 100644 --- a/board/phytium/durian/durian.c +++ b/board/phytium/durian/durian.c @@ -6,6 +6,7 @@ */ #include +#include #include #include #include diff --git a/board/renesas/sh7752evb/sh7752evb.c b/board/renesas/sh7752evb/sh7752evb.c index 565ce5f5d1..c6e0c12976 100644 --- a/board/renesas/sh7752evb/sh7752evb.c +++ b/board/renesas/sh7752evb/sh7752evb.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -245,7 +246,7 @@ int board_late_init(void) } #ifdef CONFIG_DEPRECATED -int do_write_mac(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_write_mac(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int i, ret; char mac_string[256]; diff --git a/board/renesas/sh7753evb/sh7753evb.c b/board/renesas/sh7753evb/sh7753evb.c index 0a762bc553..cdeacb8aae 100644 --- a/board/renesas/sh7753evb/sh7753evb.c +++ b/board/renesas/sh7753evb/sh7753evb.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -261,7 +262,7 @@ int board_late_init(void) } #ifdef CONFIG_DEPRECATED -int do_write_mac(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_write_mac(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int i, ret; char mac_string[256]; diff --git a/board/renesas/sh7757lcr/sh7757lcr.c b/board/renesas/sh7757lcr/sh7757lcr.c index eef5d36fd5..5e76b9e7b4 100644 --- a/board/renesas/sh7757lcr/sh7757lcr.c +++ b/board/renesas/sh7757lcr/sh7757lcr.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -344,7 +345,7 @@ int board_late_init(void) return 0; } -int do_sh_g200(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_sh_g200(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct gctrl_regs *gctrl = GCTRL_BASE; unsigned long graofst; @@ -363,7 +364,7 @@ U_BOOT_CMD( ); #ifdef CONFIG_DEPRECATED -int do_write_mac(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_write_mac(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int i, ret; char mac_string[256]; diff --git a/board/renesas/stout/cpld.c b/board/renesas/stout/cpld.c index e6c2051bd4..b56ed1703f 100644 --- a/board/renesas/stout/cpld.c +++ b/board/renesas/stout/cpld.c @@ -8,6 +8,7 @@ */ #include +#include #include #include #include @@ -124,7 +125,8 @@ void cpld_init(void) #endif } -static int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 addr, val; diff --git a/board/renesas/ulcb/cpld.c b/board/renesas/ulcb/cpld.c index 528675651d..a20a34a92a 100644 --- a/board/renesas/ulcb/cpld.c +++ b/board/renesas/ulcb/cpld.c @@ -7,6 +7,7 @@ */ #include +#include #include #include #include @@ -82,7 +83,8 @@ static void cpld_write(struct udevice *dev, u8 addr, u32 data) dm_gpio_set_value(&priv->sstbz, 1); } -static int do_cpld(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_cpld(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dev; u32 addr, val; diff --git a/board/rockchip/kylin_rk3036/kylin_rk3036.c b/board/rockchip/kylin_rk3036/kylin_rk3036.c index c5e28df258..0ca91cdeb0 100644 --- a/board/rockchip/kylin_rk3036/kylin_rk3036.c +++ b/board/rockchip/kylin_rk3036/kylin_rk3036.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include diff --git a/board/samsung/common/board.c b/board/samsung/common/board.c index 948007c4a8..c54de9fc12 100644 --- a/board/samsung/common/board.c +++ b/board/samsung/common/board.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/samsung/common/misc.c b/board/samsung/common/misc.c index 9117669f71..146843d348 100644 --- a/board/samsung/common/misc.c +++ b/board/samsung/common/misc.c @@ -262,7 +262,7 @@ static int mode_leave_menu(int mode) char *exit_option; char *exit_reset = "reset"; char *exit_back = "back"; - cmd_tbl_t *cmd; + struct cmd_tbl *cmd; int cmd_result; int leave; diff --git a/board/siemens/capricorn/board.c b/board/siemens/capricorn/board.c index b4eae7f027..ef6630f4f0 100644 --- a/board/siemens/capricorn/board.c +++ b/board/siemens/capricorn/board.c @@ -6,7 +6,9 @@ * */ #include +#include #include +#include #include #include #include @@ -411,7 +413,7 @@ unsigned char get_button_state(char * const envname, unsigned char def) * 0 if button is not held down */ static int -do_userbutton(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_userbutton(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int button = 0; @@ -432,7 +434,7 @@ U_BOOT_CMD( #define ERST IMX_GPIO_NR(0, 3) static int -do_eth_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_eth_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { gpio_request(ERST, "ERST"); gpio_direction_output(ERST, 0); diff --git a/board/siemens/common/board.c b/board/siemens/common/board.c index f1bca4b27f..e0bd8590bc 100644 --- a/board/siemens/common/board.c +++ b/board/siemens/common/board.c @@ -10,6 +10,7 @@ */ #include +#include #include #include #include @@ -151,7 +152,7 @@ unsigned char get_button_state(char * const envname, unsigned char def) * 0 if button is not held down */ static int -do_userbutton(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_userbutton(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int button = 0; button = get_button_state("button_dfu0", BOARD_DFU_BUTTON_GPIO); @@ -167,7 +168,7 @@ U_BOOT_CMD( #endif static int -do_usertestwdt(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +do_usertestwdt(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { printf("\n\n\n Go into infinite loop\n\n\n"); while (1) @@ -251,8 +252,8 @@ void set_env_gpios(unsigned char state) } /* loop through defined led in environment */ } -static int do_board_led(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_board_led(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 2) return CMD_RET_USAGE; diff --git a/board/siemens/draco/board.c b/board/siemens/draco/board.c index 963de15fa8..b4893d39ae 100644 --- a/board/siemens/draco/board.c +++ b/board/siemens/draco/board.c @@ -13,6 +13,7 @@ */ #include +#include #include #include #include @@ -343,8 +344,8 @@ int board_eth_init(bd_t *bis) return n; } -static int do_switch_reset(cmd_tbl_t *cmdtp, int flag, int argc, - char *const argv[]) +static int do_switch_reset(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* Reset SMSC LAN9303 switch for default configuration */ gpio_request(GPIO_LAN9303_NRST, "nRST"); diff --git a/board/siemens/taurus/taurus.c b/board/siemens/taurus/taurus.c index 9f9cdfa234..927ef59650 100644 --- a/board/siemens/taurus/taurus.c +++ b/board/siemens/taurus/taurus.c @@ -386,8 +386,8 @@ static int upgrade_failure_fallback(void) return 0; } -static int do_upgrade_available(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_upgrade_available(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned long upgrade_available = 0; unsigned long boot_retry = 0; diff --git a/board/sifive/fu540/fu540.c b/board/sifive/fu540/fu540.c index e9d1cf9a4b..d2a1ed0a3e 100644 --- a/board/sifive/fu540/fu540.c +++ b/board/sifive/fu540/fu540.c @@ -8,6 +8,7 @@ #include #include +#include #include #include #include diff --git a/board/sks-kinkel/sksimx6/sksimx6.c b/board/sks-kinkel/sksimx6/sksimx6.c index e5f6e90e0c..235d87c053 100644 --- a/board/sks-kinkel/sksimx6/sksimx6.c +++ b/board/sks-kinkel/sksimx6/sksimx6.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/solidrun/clearfog/clearfog.c b/board/solidrun/clearfog/clearfog.c index b8391a35c0..9430097432 100644 --- a/board/solidrun/clearfog/clearfog.c +++ b/board/solidrun/clearfog/clearfog.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/st/common/cmd_stboard.c b/board/st/common/cmd_stboard.c index 915164aa0b..e1038619f0 100644 --- a/board/st/common/cmd_stboard.c +++ b/board/st/common/cmd_stboard.c @@ -31,6 +31,7 @@ #ifndef CONFIG_SPL_BUILD #include +#include #include #include #include @@ -67,8 +68,8 @@ static void display_stboard(u32 otp) otp & 0xF); } -static int do_stboard(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_stboard(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; u32 otp, lock; diff --git a/board/st/stm32f429-discovery/stm32f429-discovery.c b/board/st/stm32f429-discovery/stm32f429-discovery.c index 5b0744ff6b..d0948b7962 100644 --- a/board/st/stm32f429-discovery/stm32f429-discovery.c +++ b/board/st/stm32f429-discovery/stm32f429-discovery.c @@ -12,6 +12,7 @@ #include #include +#include #include #include diff --git a/board/st/stm32f429-evaluation/stm32f429-evaluation.c b/board/st/stm32f429-evaluation/stm32f429-evaluation.c index 1570d110bf..680f69dfd1 100644 --- a/board/st/stm32f429-evaluation/stm32f429-evaluation.c +++ b/board/st/stm32f429-evaluation/stm32f429-evaluation.c @@ -6,6 +6,7 @@ #include #include +#include #include #include diff --git a/board/st/stm32f469-discovery/stm32f469-discovery.c b/board/st/stm32f469-discovery/stm32f469-discovery.c index d9bcb39bea..4b71d40056 100644 --- a/board/st/stm32f469-discovery/stm32f469-discovery.c +++ b/board/st/stm32f469-discovery/stm32f469-discovery.c @@ -6,6 +6,7 @@ #include #include +#include #include #include diff --git a/board/synopsys/emsdp/emsdp.c b/board/synopsys/emsdp/emsdp.c index d98e606426..c1746b6110 100644 --- a/board/synopsys/emsdp/emsdp.c +++ b/board/synopsys/emsdp/emsdp.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -102,7 +103,8 @@ void reset_cpu(ulong addr) ; /* loop forever till reset */ } -static int do_emsdp_rom(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_emsdp_rom(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 creg_boot = readl(CREG_BOOT); @@ -118,13 +120,14 @@ static int do_emsdp_rom(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[] return CMD_RET_SUCCESS; } -cmd_tbl_t cmd_emsdp[] = { +struct cmd_tbl cmd_emsdp[] = { U_BOOT_CMD_MKENT(rom, 2, 0, do_emsdp_rom, "", ""), }; -static int do_emsdp(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_emsdp(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; c = find_cmd_tbl(argv[1], cmd_emsdp, ARRAY_SIZE(cmd_emsdp)); diff --git a/board/synopsys/hsdk/hsdk.c b/board/synopsys/hsdk/hsdk.c index e102d0f068..d68b9d75bc 100644 --- a/board/synopsys/hsdk/hsdk.c +++ b/board/synopsys/hsdk/hsdk.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -931,7 +932,8 @@ static int hsdk_go_prepare_and_run(void) return hsdk_go_run(reg); } -static int do_hsdk_go(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_hsdk_go(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; @@ -996,7 +998,8 @@ static void init_mark_done(void) writel(~INIT_MARKER_PENDING, INIT_MARKER_REGISTER); } -static int do_hsdk_init(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_hsdk_init(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; @@ -1024,7 +1027,7 @@ U_BOOT_CMD( "- Init HSDK HW\n" ); -static int do_hsdk_clock_set(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_hsdk_clock_set(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int ret = 0; @@ -1056,7 +1059,7 @@ static int do_hsdk_clock_set(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_hsdk_clock_get(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_hsdk_clock_get(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ulong rate; @@ -1084,7 +1087,7 @@ static int do_hsdk_clock_get(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_hsdk_clock_print(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_hsdk_clock_print(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* Main clocks */ @@ -1096,7 +1099,7 @@ static int do_hsdk_clock_print(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_hsdk_clock_print_all(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_hsdk_clock_print_all(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { /* @@ -1157,16 +1160,17 @@ static int do_hsdk_clock_print_all(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -cmd_tbl_t cmd_hsdk_clock[] = { +struct cmd_tbl cmd_hsdk_clock[] = { U_BOOT_CMD_MKENT(set, 3, 0, do_hsdk_clock_set, "", ""), U_BOOT_CMD_MKENT(get, 3, 0, do_hsdk_clock_get, "", ""), U_BOOT_CMD_MKENT(print, 4, 0, do_hsdk_clock_print, "", ""), U_BOOT_CMD_MKENT(print_all, 4, 0, do_hsdk_clock_print_all, "", ""), }; -static int do_hsdk_clock(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_hsdk_clock(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/board/syteco/zmx25/zmx25.c b/board/syteco/zmx25/zmx25.c index 715e20dbd0..9ea62bb796 100644 --- a/board/syteco/zmx25/zmx25.c +++ b/board/syteco/zmx25/zmx25.c @@ -15,6 +15,7 @@ */ #include #include +#include #include #include #include diff --git a/board/technexion/pico-imx6/pico-imx6.c b/board/technexion/pico-imx6/pico-imx6.c index eac30368f7..c60ce4b138 100644 --- a/board/technexion/pico-imx6/pico-imx6.c +++ b/board/technexion/pico-imx6/pico-imx6.c @@ -6,6 +6,7 @@ * Author: Fabio Estevam */ +#include #include #include #include diff --git a/board/theadorable/theadorable.c b/board/theadorable/theadorable.c index 9af1799fa5..6ee09034ea 100644 --- a/board/theadorable/theadorable.c +++ b/board/theadorable/theadorable.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -309,7 +310,7 @@ int board_late_init(void) #endif #if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_PCI) -int do_pcie_test(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_pcie_test(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { pci_dev_t bdf; u16 ven_id, dev_id; diff --git a/board/ti/j721e/evm.c b/board/ti/j721e/evm.c index d9af309818..c4d1cddc1d 100644 --- a/board/ti/j721e/evm.c +++ b/board/ti/j721e/evm.c @@ -8,6 +8,7 @@ */ #include +#include #include #include #include diff --git a/board/ti/sdp4430/cmd_bat.c b/board/ti/sdp4430/cmd_bat.c index c820435386..6c1e6ca393 100644 --- a/board/ti/sdp4430/cmd_bat.c +++ b/board/ti/sdp4430/cmd_bat.c @@ -9,7 +9,7 @@ #ifdef CONFIG_CMD_BAT #include -int do_vbat(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_vbat(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc == 2) { if (strncmp(argv[1], "startcharge", 12) == 0) diff --git a/board/toradex/apalis-tk1/apalis-tk1.c b/board/toradex/apalis-tk1/apalis-tk1.c index 81329a6131..3b7fa4b237 100644 --- a/board/toradex/apalis-tk1/apalis-tk1.c +++ b/board/toradex/apalis-tk1/apalis-tk1.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include diff --git a/board/toradex/apalis_imx6/do_fuse.c b/board/toradex/apalis_imx6/do_fuse.c index 22d191f52a..6991b1bc13 100644 --- a/board/toradex/apalis_imx6/do_fuse.c +++ b/board/toradex/apalis_imx6/do_fuse.c @@ -9,6 +9,7 @@ #include #ifndef CONFIG_SPL_BUILD +#include #include #include @@ -35,8 +36,8 @@ static int mfgr_fuse(void) return CMD_RET_SUCCESS; } -int do_mfgr_fuse(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_mfgr_fuse(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; puts("Fusing...\n"); @@ -48,8 +49,8 @@ int do_mfgr_fuse(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -int do_updt_fuse(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_updt_fuse(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned val; int ret; diff --git a/board/toradex/apalis_imx6/pf0100.c b/board/toradex/apalis_imx6/pf0100.c index ebd6418fd4..f8d0494332 100644 --- a/board/toradex/apalis_imx6/pf0100.c +++ b/board/toradex/apalis_imx6/pf0100.c @@ -8,6 +8,7 @@ */ #include +#include #include #include #include @@ -261,8 +262,8 @@ static int pf0100_prog(void) return CMD_RET_SUCCESS; } -static int do_pf0100_prog(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_pf0100_prog(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; puts("Programming PMIC OTP..."); diff --git a/board/toradex/colibri_imx6/do_fuse.c b/board/toradex/colibri_imx6/do_fuse.c index 22d191f52a..6991b1bc13 100644 --- a/board/toradex/colibri_imx6/do_fuse.c +++ b/board/toradex/colibri_imx6/do_fuse.c @@ -9,6 +9,7 @@ #include #ifndef CONFIG_SPL_BUILD +#include #include #include @@ -35,8 +36,8 @@ static int mfgr_fuse(void) return CMD_RET_SUCCESS; } -int do_mfgr_fuse(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_mfgr_fuse(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; puts("Fusing...\n"); @@ -48,8 +49,8 @@ int do_mfgr_fuse(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -int do_updt_fuse(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_updt_fuse(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned val; int ret; diff --git a/board/toradex/colibri_imx6/pf0100.c b/board/toradex/colibri_imx6/pf0100.c index e744243297..149e9bd3b9 100644 --- a/board/toradex/colibri_imx6/pf0100.c +++ b/board/toradex/colibri_imx6/pf0100.c @@ -8,6 +8,7 @@ */ #include +#include #include #include #include @@ -246,8 +247,8 @@ static int pf0100_prog(void) return CMD_RET_SUCCESS; } -static int do_pf0100_prog(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_pf0100_prog(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; puts("Programming PMIC OTP..."); diff --git a/board/toradex/common/tdx-cfg-block.c b/board/toradex/common/tdx-cfg-block.c index bd7d8b7f53..75216ecf6d 100644 --- a/board/toradex/common/tdx-cfg-block.c +++ b/board/toradex/common/tdx-cfg-block.c @@ -5,6 +5,7 @@ #include #include "tdx-cfg-block.h" +#include #include #if defined(CONFIG_TARGET_APALIS_IMX6) || \ @@ -514,8 +515,8 @@ static int get_cfgblock_barcode(char *barcode) return 0; } -static int do_cfgblock_create(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_cfgblock_create(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u8 *config_block; struct toradex_tag *tag; @@ -643,8 +644,8 @@ out: return ret; } -static int do_cfgblock(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_cfgblock(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; diff --git a/board/toradex/verdin-imx8mm/spl.c b/board/toradex/verdin-imx8mm/spl.c index 338952ea71..eedca1e218 100644 --- a/board/toradex/verdin-imx8mm/spl.c +++ b/board/toradex/verdin-imx8mm/spl.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include diff --git a/board/varisys/common/sys_eeprom.c b/board/varisys/common/sys_eeprom.c index 4c025087db..134c307e5d 100644 --- a/board/varisys/common/sys_eeprom.c +++ b/board/varisys/common/sys_eeprom.c @@ -306,7 +306,7 @@ static void set_mac_address(unsigned int index, const char *string) update_crc(); } -int do_mac(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_mac(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { char cmd; diff --git a/board/work-microwave/work_92105/work_92105_display.c b/board/work-microwave/work_92105/work_92105_display.c index db04dcabc7..3dd60ec827 100644 --- a/board/work-microwave/work_92105/work_92105_display.c +++ b/board/work-microwave/work_92105/work_92105_display.c @@ -11,6 +11,7 @@ */ #include +#include #include #include #include @@ -266,7 +267,7 @@ void work_92105_display_init(void) #ifdef CONFIG_CMD_MAX6957 -static int do_max6957aax(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_max6957aax(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int reg, val; @@ -315,7 +316,8 @@ U_BOOT_CMD( #error CONFIG_CMD_HD44760 requires CONFIG_HUSH_PARSER #endif -static int do_hd44780(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_hd44780(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *cmd; diff --git a/board/xilinx/common/board.c b/board/xilinx/common/board.c index 294a59df77..b8cdaaada1 100644 --- a/board/xilinx/common/board.c +++ b/board/xilinx/common/board.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include diff --git a/board/xilinx/microblaze-generic/microblaze-generic.c b/board/xilinx/microblaze-generic/microblaze-generic.c index 0e33f6af0b..0f81df3acc 100644 --- a/board/xilinx/microblaze-generic/microblaze-generic.c +++ b/board/xilinx/microblaze-generic/microblaze-generic.c @@ -12,6 +12,7 @@ #include #include +#include #include #include #include diff --git a/board/xilinx/versal/board.c b/board/xilinx/versal/board.c index 24cff0c370..44cc65e023 100644 --- a/board/xilinx/versal/board.c +++ b/board/xilinx/versal/board.c @@ -6,6 +6,7 @@ #include #include +#include #include #include #include diff --git a/board/xilinx/zynq/cmds.c b/board/xilinx/zynq/cmds.c index 27d44b760d..33589347da 100644 --- a/board/xilinx/zynq/cmds.c +++ b/board/xilinx/zynq/cmds.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -408,8 +409,8 @@ static int zynq_verify_image(u32 src_ptr) return 0; } -static int do_zynq_rsa(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_zynq_rsa(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 src_ptr; char *endp; @@ -429,8 +430,8 @@ static int do_zynq_rsa(cmd_tbl_t *cmdtp, int flag, int argc, #endif #ifdef CONFIG_CMD_ZYNQ_AES -static int zynq_decrypt_image(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int zynq_decrypt_image(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *endp; u32 srcaddr, srclen, dstaddr, dstlen; @@ -469,7 +470,7 @@ static int zynq_decrypt_image(cmd_tbl_t *cmdtp, int flag, int argc, } #endif -static cmd_tbl_t zynq_commands[] = { +static struct cmd_tbl zynq_commands[] = { #ifdef CONFIG_CMD_ZYNQ_RSA U_BOOT_CMD_MKENT(rsa, 3, 1, do_zynq_rsa, "", ""), #endif @@ -478,9 +479,10 @@ static cmd_tbl_t zynq_commands[] = { #endif }; -static int do_zynq(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_zynq(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *zynq_cmd; + struct cmd_tbl *zynq_cmd; int ret; if (!ARRAY_SIZE(zynq_commands)) { diff --git a/board/xilinx/zynqmp/cmds.c b/board/xilinx/zynqmp/cmds.c index 893616b6a1..0f1f26986f 100644 --- a/board/xilinx/zynqmp/cmds.c +++ b/board/xilinx/zynqmp/cmds.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -13,8 +14,8 @@ #include #include -static int do_zynqmp_verify_secure(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_zynqmp_verify_secure(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u64 src_addr, addr; u32 len, src_lo, src_hi; @@ -65,8 +66,8 @@ static int do_zynqmp_verify_secure(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -static int do_zynqmp_mmio_read(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_zynqmp_mmio_read(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 read_val, addr; int ret; @@ -86,8 +87,8 @@ static int do_zynqmp_mmio_read(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -static int do_zynqmp_mmio_write(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_zynqmp_mmio_write(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 addr, mask, val; int ret; @@ -107,8 +108,8 @@ static int do_zynqmp_mmio_write(cmd_tbl_t *cmdtp, int flag, int argc, } #ifdef CONFIG_DEFINE_TCM_OCM_MMAP -static int do_zynqmp_tcm_init(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_zynqmp_tcm_init(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u8 mode; @@ -129,7 +130,7 @@ static int do_zynqmp_tcm_init(cmd_tbl_t *cmdtp, int flag, int argc, } #endif -static cmd_tbl_t cmd_zynqmp_sub[] = { +static struct cmd_tbl cmd_zynqmp_sub[] = { U_BOOT_CMD_MKENT(secure, 5, 0, do_zynqmp_verify_secure, "", ""), U_BOOT_CMD_MKENT(mmio_read, 3, 0, do_zynqmp_mmio_read, "", ""), U_BOOT_CMD_MKENT(mmio_write, 5, 0, do_zynqmp_mmio_write, "", ""), @@ -149,10 +150,10 @@ static cmd_tbl_t cmd_zynqmp_sub[] = { * * Return: return 0 on success and CMD_RET_USAGE incase of misuse and error */ -static int do_zynqmp(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_zynqmp(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/board/xilinx/zynqmp/zynqmp.c b/board/xilinx/zynqmp/zynqmp.c index 6aad1352c4..7a8c745f9b 100644 --- a/board/xilinx/zynqmp/zynqmp.c +++ b/board/xilinx/zynqmp/zynqmp.c @@ -5,6 +5,7 @@ */ #include +#include #include #include #include @@ -415,7 +416,7 @@ int board_early_init_r(void) } unsigned long do_go_exec(ulong (*entry)(int, char * const []), int argc, - char * const argv[]) + char *const argv[]) { int ret = 0; diff --git a/cmd/ab_select.c b/cmd/ab_select.c index 7a4e51571b..6298fcfb60 100644 --- a/cmd/ab_select.c +++ b/cmd/ab_select.c @@ -6,10 +6,11 @@ #include #include #include +#include #include -static int do_ab_select(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_ab_select(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret; struct blk_desc *dev_desc; diff --git a/cmd/abootimg.c b/cmd/abootimg.c index 15e727f4a2..40e8978f15 100644 --- a/cmd/abootimg.c +++ b/cmd/abootimg.c @@ -6,6 +6,7 @@ #include #include +#include #include #include @@ -15,7 +16,7 @@ /* Please use abootimg_addr() macro to obtain the boot image address */ static ulong _abootimg_addr = -1; -static int abootimg_get_ver(int argc, char * const argv[]) +static int abootimg_get_ver(int argc, char *const argv[]) { const struct andr_img_hdr *hdr; int res = CMD_RET_SUCCESS; @@ -40,7 +41,7 @@ exit: return res; } -static int abootimg_get_recovery_dtbo(int argc, char * const argv[]) +static int abootimg_get_recovery_dtbo(int argc, char *const argv[]) { ulong addr; u32 size; @@ -62,7 +63,7 @@ static int abootimg_get_recovery_dtbo(int argc, char * const argv[]) return CMD_RET_SUCCESS; } -static int abootimg_get_dtb_load_addr(int argc, char * const argv[]) +static int abootimg_get_dtb_load_addr(int argc, char *const argv[]) { const struct andr_img_hdr *hdr; int res = CMD_RET_SUCCESS; @@ -93,7 +94,7 @@ exit: return res; } -static int abootimg_get_dtb_by_index(int argc, char * const argv[]) +static int abootimg_get_dtb_by_index(int argc, char *const argv[]) { const char *index_str; u32 num; @@ -140,7 +141,7 @@ static int abootimg_get_dtb_by_index(int argc, char * const argv[]) return CMD_RET_SUCCESS; } -static int abootimg_get_dtb(int argc, char * const argv[]) +static int abootimg_get_dtb(int argc, char *const argv[]) { if (argc < 1) return CMD_RET_USAGE; @@ -151,8 +152,8 @@ static int abootimg_get_dtb(int argc, char * const argv[]) return CMD_RET_USAGE; } -static int do_abootimg_addr(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_abootimg_addr(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *endp; ulong img_addr; @@ -170,8 +171,8 @@ static int do_abootimg_addr(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_abootimg_get(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_abootimg_get(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *param; @@ -193,8 +194,8 @@ static int do_abootimg_get(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_USAGE; } -static int do_abootimg_dump(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_abootimg_dump(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 2) return CMD_RET_USAGE; @@ -209,16 +210,16 @@ static int do_abootimg_dump(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static cmd_tbl_t cmd_abootimg_sub[] = { +static struct cmd_tbl cmd_abootimg_sub[] = { U_BOOT_CMD_MKENT(addr, 2, 1, do_abootimg_addr, "", ""), U_BOOT_CMD_MKENT(dump, 2, 1, do_abootimg_dump, "", ""), U_BOOT_CMD_MKENT(get, 5, 1, do_abootimg_get, "", ""), }; -static int do_abootimg(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_abootimg(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *cp; + struct cmd_tbl *cp; cp = find_cmd_tbl(argv[1], cmd_abootimg_sub, ARRAY_SIZE(cmd_abootimg_sub)); diff --git a/cmd/acpi.c b/cmd/acpi.c index 203bd93bd5..e9a9161a91 100644 --- a/cmd/acpi.c +++ b/cmd/acpi.c @@ -137,7 +137,7 @@ static int list_rsdp(struct acpi_rsdp *rsdp) return 0; } -static int do_acpi_list(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_acpi_list(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct acpi_rsdp *rsdp; @@ -153,7 +153,7 @@ static int do_acpi_list(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_acpi_dump(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_acpi_dump(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const char *name; diff --git a/cmd/adc.c b/cmd/adc.c index 381961cf51..16f914a030 100644 --- a/cmd/adc.c +++ b/cmd/adc.c @@ -8,7 +8,7 @@ #include #include -static int do_adc_list(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_adc_list(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *dev; @@ -31,7 +31,7 @@ static int do_adc_list(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_adc_info(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_adc_info(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *dev; @@ -68,7 +68,7 @@ static int do_adc_info(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_adc_single(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_adc_single(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *dev; @@ -95,7 +95,7 @@ static int do_adc_single(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_adc_scan(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_adc_scan(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct adc_channel ch[ADC_MAX_CHANNEL]; diff --git a/cmd/adtimg.c b/cmd/adtimg.c index 60bb01c349..aa943007f3 100644 --- a/cmd/adtimg.c +++ b/cmd/adtimg.c @@ -5,6 +5,7 @@ * Eugeniu Rosca */ +#include #include #include #include @@ -17,8 +18,8 @@ */ static ulong working_img; -static int do_adtimg_addr(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_adtimg_addr(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *endp; ulong hdr_addr; @@ -56,8 +57,8 @@ static int adtimg_check_working_img(void) return CMD_RET_SUCCESS; } -static int do_adtimg_dump(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_adtimg_dump(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc != 1) return CMD_RET_USAGE; @@ -99,7 +100,7 @@ static int adtimg_getopt_u32(char * const opt, char * const name, u32 *optval) return CMD_RET_SUCCESS; } -static int adtimg_getopt_index(int argc, char * const argv[], u32 *index, +static int adtimg_getopt_index(int argc, char *const argv[], u32 *index, char **avar, char **svar) { int ret; @@ -124,7 +125,7 @@ static int adtimg_getopt_index(int argc, char * const argv[], u32 *index, return CMD_RET_SUCCESS; } -static int adtimg_get_dt_by_index(int argc, char * const argv[]) +static int adtimg_get_dt_by_index(int argc, char *const argv[]) { ulong addr; u32 index, size; @@ -163,7 +164,7 @@ static int adtimg_get_dt_by_index(int argc, char * const argv[]) return CMD_RET_SUCCESS; } -static int adtimg_get_dt(int argc, char * const argv[]) +static int adtimg_get_dt(int argc, char *const argv[]) { if (argc < 2) { printf("Error: No options passed to '%s'\n", argv[0]); @@ -181,8 +182,8 @@ static int adtimg_get_dt(int argc, char * const argv[]) return CMD_RET_FAILURE; } -static int do_adtimg_get(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_adtimg_get(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { if (argc < 2) { printf("Error: No arguments passed to '%s'\n", argv[0]); @@ -203,15 +204,16 @@ static int do_adtimg_get(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static cmd_tbl_t cmd_adtimg_sub[] = { +static struct cmd_tbl cmd_adtimg_sub[] = { U_BOOT_CMD_MKENT(addr, CONFIG_SYS_MAXARGS, 1, do_adtimg_addr, "", ""), U_BOOT_CMD_MKENT(dump, CONFIG_SYS_MAXARGS, 1, do_adtimg_dump, "", ""), U_BOOT_CMD_MKENT(get, CONFIG_SYS_MAXARGS, 1, do_adtimg_get, "", ""), }; -static int do_adtimg(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_adtimg(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *cp; + struct cmd_tbl *cp; cp = find_cmd_tbl(argv[1], cmd_adtimg_sub, ARRAY_SIZE(cmd_adtimg_sub)); diff --git a/cmd/aes.c b/cmd/aes.c index 8c5b42fd2c..4c0dad9932 100644 --- a/cmd/aes.c +++ b/cmd/aes.c @@ -35,7 +35,7 @@ u32 aes_get_key_len(char *command) * Returns zero on success, CMD_RET_USAGE in case of misuse and negative * on error. */ -static int do_aes(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_aes(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uint32_t key_addr, iv_addr, src_addr, dst_addr, len; uint8_t *key_ptr, *iv_ptr, *src_ptr, *dst_ptr; diff --git a/cmd/arm/exception.c b/cmd/arm/exception.c index 33bc75976f..522f6dff53 100644 --- a/cmd/arm/exception.c +++ b/cmd/arm/exception.c @@ -8,8 +8,8 @@ #include #include -static int do_unaligned(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_unaligned(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* * The LDRD instruction requires the data source to be four byte aligned @@ -23,15 +23,15 @@ static int do_unaligned(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static int do_breakpoint(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_breakpoint(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { asm volatile ("BKPT #123\n"); return CMD_RET_FAILURE; } -static int do_undefined(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_undefined(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* * 0xe7f...f. is undefined in ARM mode @@ -41,7 +41,7 @@ static int do_undefined(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static cmd_tbl_t cmd_sub[] = { +static struct cmd_tbl cmd_sub[] = { U_BOOT_CMD_MKENT(breakpoint, CONFIG_SYS_MAXARGS, 1, do_breakpoint, "", ""), U_BOOT_CMD_MKENT(unaligned, CONFIG_SYS_MAXARGS, 1, do_unaligned, diff --git a/cmd/arm/exception64.c b/cmd/arm/exception64.c index a363818532..d5de50a080 100644 --- a/cmd/arm/exception64.c +++ b/cmd/arm/exception64.c @@ -8,8 +8,8 @@ #include #include -static int do_undefined(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_undefined(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* * 0xe7f...f. is undefined in ARM mode @@ -19,7 +19,7 @@ static int do_undefined(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static cmd_tbl_t cmd_sub[] = { +static struct cmd_tbl cmd_sub[] = { U_BOOT_CMD_MKENT(undefined, CONFIG_SYS_MAXARGS, 1, do_undefined, "", ""), }; diff --git a/cmd/armflash.c b/cmd/armflash.c index f82f3dd1a3..5e7315eb7c 100644 --- a/cmd/armflash.c +++ b/cmd/armflash.c @@ -267,7 +267,7 @@ static int exists(const char * const name) return CMD_RET_FAILURE; } -static int do_afs(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_afs(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int ret = CMD_RET_SUCCESS; diff --git a/cmd/avb.c b/cmd/avb.c index a4de5c40a2..398ad3ba97 100644 --- a/cmd/avb.c +++ b/cmd/avb.c @@ -15,7 +15,7 @@ #define AVB_BOOTARGS "avb_bootargs" static struct AvbOps *avb_ops; -int do_avb_init(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_avb_init(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { unsigned long mmc_dev; @@ -36,7 +36,8 @@ int do_avb_init(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_FAILURE; } -int do_avb_read_part(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_avb_read_part(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *part; s64 offset; @@ -68,7 +69,7 @@ int do_avb_read_part(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_FAILURE; } -int do_avb_read_part_hex(cmd_tbl_t *cmdtp, int flag, int argc, +int do_avb_read_part_hex(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const char *part; @@ -114,7 +115,8 @@ int do_avb_read_part_hex(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -int do_avb_write_part(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_avb_write_part(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *part; s64 offset; @@ -145,7 +147,8 @@ int do_avb_write_part(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_FAILURE; } -int do_avb_read_rb(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_avb_read_rb(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { size_t index; u64 rb_idx; @@ -171,7 +174,8 @@ int do_avb_read_rb(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_FAILURE; } -int do_avb_write_rb(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_avb_write_rb(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { size_t index; u64 rb_idx; @@ -196,8 +200,8 @@ int do_avb_write_rb(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return CMD_RET_FAILURE; } -int do_avb_get_uuid(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +int do_avb_get_uuid(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { const char *part; char buffer[UUID_STR_LEN + 1]; @@ -224,7 +228,7 @@ int do_avb_get_uuid(cmd_tbl_t *cmdtp, int flag, return CMD_RET_FAILURE; } -int do_avb_verify_part(cmd_tbl_t *cmdtp, int flag, +int do_avb_verify_part(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const char * const requested_partitions[] = {"boot", NULL}; @@ -315,8 +319,8 @@ int do_avb_verify_part(cmd_tbl_t *cmdtp, int flag, return res; } -int do_avb_is_unlocked(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +int do_avb_is_unlocked(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { bool unlock; @@ -341,8 +345,8 @@ int do_avb_is_unlocked(cmd_tbl_t *cmdtp, int flag, return CMD_RET_FAILURE; } -int do_avb_read_pvalue(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_avb_read_pvalue(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *name; size_t bytes; @@ -382,8 +386,8 @@ int do_avb_read_pvalue(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -int do_avb_write_pvalue(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +int do_avb_write_pvalue(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { const char *name; const char *value; @@ -411,7 +415,7 @@ int do_avb_write_pvalue(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static cmd_tbl_t cmd_avb[] = { +static struct cmd_tbl cmd_avb[] = { U_BOOT_CMD_MKENT(init, 2, 0, do_avb_init, "", ""), U_BOOT_CMD_MKENT(read_rb, 2, 0, do_avb_read_rb, "", ""), U_BOOT_CMD_MKENT(write_rb, 3, 0, do_avb_write_rb, "", ""), @@ -427,9 +431,9 @@ static cmd_tbl_t cmd_avb[] = { #endif }; -static int do_avb(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_avb(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *cp; + struct cmd_tbl *cp; cp = find_cmd_tbl(argv[1], cmd_avb, ARRAY_SIZE(cmd_avb)); diff --git a/cmd/axi.c b/cmd/axi.c index 588098fddd..18533efc0d 100644 --- a/cmd/axi.c +++ b/cmd/axi.c @@ -96,8 +96,8 @@ static int axi_get_cur_bus(struct udevice **busp) * Command handlers */ -static int do_axi_show_bus(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_axi_show_bus(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dummy; @@ -135,8 +135,8 @@ static int do_axi_show_bus(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_axi_bus_num(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_axi_bus_num(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret = 0; int bus_no; @@ -163,7 +163,8 @@ static int do_axi_bus_num(cmd_tbl_t *cmdtp, int flag, int argc, return ret ? CMD_RET_FAILURE : 0; } -static int do_axi_md(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_axi_md(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* Print that many bytes per line */ const uint DISP_LINE_LEN = 16; @@ -261,7 +262,8 @@ static int do_axi_md(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return 0; } -static int do_axi_mw(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_axi_mw(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { u32 writeval; ulong addr, count, size; @@ -312,17 +314,17 @@ static int do_axi_mw(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return 0; } -static cmd_tbl_t cmd_axi_sub[] = { +static struct cmd_tbl cmd_axi_sub[] = { U_BOOT_CMD_MKENT(bus, 1, 1, do_axi_show_bus, "", ""), U_BOOT_CMD_MKENT(dev, 1, 1, do_axi_bus_num, "", ""), U_BOOT_CMD_MKENT(md, 4, 1, do_axi_md, "", ""), U_BOOT_CMD_MKENT(mw, 5, 1, do_axi_mw, "", ""), }; -static int do_ihs_axi(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_ihs_axi(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/cmd/bcb.c b/cmd/bcb.c index b944e62b6a..d99a698012 100644 --- a/cmd/bcb.c +++ b/cmd/bcb.c @@ -109,8 +109,8 @@ static int bcb_field_get(char *name, char **fieldp, int *sizep) return 0; } -static int do_bcb_load(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_load(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct blk_desc *desc; struct disk_partition info; @@ -162,8 +162,8 @@ err: return CMD_RET_FAILURE; } -static int do_bcb_set(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_set(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int size, len; char *field, *str, *found; @@ -189,8 +189,8 @@ static int do_bcb_set(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_bcb_clear(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_clear(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int size; char *field; @@ -208,8 +208,8 @@ static int do_bcb_clear(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_bcb_test(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_test(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int size; char *field; @@ -235,8 +235,8 @@ static int do_bcb_test(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_FAILURE; } -static int do_bcb_dump(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_dump(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int size; char *field; @@ -249,8 +249,8 @@ static int do_bcb_dump(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static int do_bcb_store(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bcb_store(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct blk_desc *desc; struct disk_partition info; @@ -281,7 +281,7 @@ err: return CMD_RET_FAILURE; } -static cmd_tbl_t cmd_bcb_sub[] = { +static struct cmd_tbl cmd_bcb_sub[] = { U_BOOT_CMD_MKENT(load, CONFIG_SYS_MAXARGS, 1, do_bcb_load, "", ""), U_BOOT_CMD_MKENT(set, CONFIG_SYS_MAXARGS, 1, do_bcb_set, "", ""), U_BOOT_CMD_MKENT(clear, CONFIG_SYS_MAXARGS, 1, do_bcb_clear, "", ""), @@ -290,9 +290,9 @@ static cmd_tbl_t cmd_bcb_sub[] = { U_BOOT_CMD_MKENT(store, CONFIG_SYS_MAXARGS, 1, do_bcb_store, "", ""), }; -static int do_bcb(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_bcb(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/cmd/bdinfo.c b/cmd/bdinfo.c index ec399c07ae..dba552b03f 100644 --- a/cmd/bdinfo.c +++ b/cmd/bdinfo.c @@ -177,7 +177,7 @@ void __weak board_detail(void) /* Please define board_detail() for your platform */ } -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -222,7 +222,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_NIOS2) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -243,7 +243,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_MICROBLAZE) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -269,7 +269,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_M68K) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -301,7 +301,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_MIPS) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { print_std_bdinfo(gd->bd); print_num("relocaddr", gd->relocaddr); @@ -313,8 +313,8 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_ARM) -static int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { bd_t *bd = gd->bd; @@ -374,7 +374,7 @@ static int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, #elif defined(CONFIG_SH) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -389,7 +389,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_X86) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -411,7 +411,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_SANDBOX) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -429,7 +429,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_NDS32) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -445,7 +445,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_RISCV) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -462,7 +462,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_ARC) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { bd_t *bd = gd->bd; @@ -476,7 +476,7 @@ int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #elif defined(CONFIG_XTENSA) -int do_bdinfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bdinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { print_std_bdinfo(gd->bd); return 0; diff --git a/cmd/bedbug.c b/cmd/bedbug.c index d3e31212ea..425ba4af1f 100644 --- a/cmd/bedbug.c +++ b/cmd/bedbug.c @@ -56,7 +56,8 @@ int bedbug_init(void) * Entry point from the interpreter to the disassembler. Repeated calls * will resume from the last disassembled address. * ====================================================================== */ -int do_bedbug_dis (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_dis(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr; /* Address to start disassembly from */ ulong len; /* # of instructions to disassemble */ @@ -96,7 +97,8 @@ U_BOOT_CMD (ds, 3, 1, do_bedbug_dis, * instructions in consecutive memory locations until a '.' (period) is * entered on a line by itself. * ====================================================================== */ -int do_bedbug_asm (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_asm(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { long mem_addr; /* Address to assemble into */ unsigned long instr; /* Machine code for text */ @@ -146,7 +148,8 @@ U_BOOT_CMD (as, 2, 0, do_bedbug_asm, * CPU-specific break point set routine. * ====================================================================== */ -int do_bedbug_break (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_break(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* -------------------------------------------------- */ if (bug_ctx.do_break) @@ -242,7 +245,8 @@ void bedbug_main_loop (unsigned long addr, struct pt_regs *regs) * stopped flag in the context so that the breakpoint routine will * return. * ====================================================================== */ -int do_bedbug_continue (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_continue(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* -------------------------------------------------- */ @@ -265,7 +269,8 @@ U_BOOT_CMD (continue, 1, 0, do_bedbug_continue, * the address passes control to the CPU-specific set breakpoint routine * for the current breakpoint number. * ====================================================================== */ -int do_bedbug_step (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_step(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned long addr; /* Address to stop at */ @@ -296,7 +301,8 @@ U_BOOT_CMD (step, 1, 1, do_bedbug_step, * the address passes control to the CPU-specific set breakpoint routine * for the current breakpoint number. * ====================================================================== */ -int do_bedbug_next (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_next(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned long addr; /* Address to stop at */ @@ -325,7 +331,8 @@ U_BOOT_CMD (next, 1, 1, do_bedbug_next, * Interpreter command to print the current stack. This assumes an EABI * architecture, so it starts with GPR R1 and works back up the stack. * ====================================================================== */ -int do_bedbug_stack (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_stack(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { unsigned long sp; /* Stack pointer */ unsigned long func; /* LR from stack */ @@ -370,7 +377,8 @@ U_BOOT_CMD (where, 1, 1, do_bedbug_stack, * Interpreter command to dump the registers. Calls the CPU-specific * show registers routine. * ====================================================================== */ -int do_bedbug_rdump (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_bedbug_rdump(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* -------------------------------------------------- */ diff --git a/cmd/bind.c b/cmd/bind.c index 44a5f17f0d..068b1399ab 100644 --- a/cmd/bind.c +++ b/cmd/bind.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -194,8 +195,8 @@ static int unbind_by_node_path(const char *path) return 0; } -static int do_bind_unbind(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bind_unbind(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret = 0; bool bind; diff --git a/cmd/binop.c b/cmd/binop.c index 6d2df5f3dd..c85cb51568 100644 --- a/cmd/binop.c +++ b/cmd/binop.c @@ -64,7 +64,8 @@ void write_to_mem(char *varname, u8 *result, ulong len) unmap_sysmem(buf); } -static int do_binop(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_binop(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong len; u8 *result, *src1, *src2; diff --git a/cmd/blk_common.c b/cmd/blk_common.c index cc6e161ba0..87f94b5abb 100644 --- a/cmd/blk_common.c +++ b/cmd/blk_common.c @@ -10,8 +10,9 @@ #include #include +#include -int blk_common_cmd(int argc, char * const argv[], enum if_type if_type, +int blk_common_cmd(int argc, char *const argv[], enum if_type if_type, int *cur_devnump) { const char *if_name = blk_get_if_type_name(if_type); diff --git a/cmd/blkcache.c b/cmd/blkcache.c index 2cc65a9ee7..25f252e455 100644 --- a/cmd/blkcache.c +++ b/cmd/blkcache.c @@ -4,13 +4,14 @@ * Author: Eric Nelson * */ +#include #include #include #include #include -static int blkc_show(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int blkc_show(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { struct block_cache_stats stats; blkcache_stats(&stats); @@ -25,8 +26,8 @@ static int blkc_show(cmd_tbl_t *cmdtp, int flag, return 0; } -static int blkc_configure(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int blkc_configure(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { unsigned blocks_per_entry, max_entries; if (argc != 3) @@ -40,7 +41,7 @@ static int blkc_configure(cmd_tbl_t *cmdtp, int flag, return 0; } -static cmd_tbl_t cmd_blkc_sub[] = { +static struct cmd_tbl cmd_blkc_sub[] = { U_BOOT_CMD_MKENT(show, 0, 0, blkc_show, "", ""), U_BOOT_CMD_MKENT(configure, 3, 0, blkc_configure, "", ""), }; @@ -55,10 +56,10 @@ static __maybe_unused void blkc_reloc(void) }; } -static int do_blkcache(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_blkcache(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; #ifdef CONFIG_NEEDS_MANUAL_RELOC blkc_reloc(); diff --git a/cmd/blob.c b/cmd/blob.c index 80478b8802..c80e6977b4 100644 --- a/cmd/blob.c +++ b/cmd/blob.c @@ -48,7 +48,8 @@ __weak int blob_encap(u8 *key_mod, u8 *src, u8 *dst, u32 len) * Returns zero on success, CMD_RET_USAGE in case of misuse and negative * on error. */ -static int do_blob(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +static int do_blob(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong key_addr, src_addr, dst_addr, len; uint8_t *km_ptr, *src_ptr, *dst_ptr; diff --git a/cmd/bmp.c b/cmd/bmp.c index edf4f56426..0ad23231cb 100644 --- a/cmd/bmp.c +++ b/cmd/bmp.c @@ -91,7 +91,8 @@ struct bmp_image *gunzip_bmp(unsigned long addr, unsigned long *lenp, } #endif -static int do_bmp_info(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +static int do_bmp_info(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr; @@ -109,7 +110,8 @@ static int do_bmp_info(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[ return (bmp_info(addr)); } -static int do_bmp_display(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +static int do_bmp_display(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong addr; int x = 0, y = 0; @@ -141,7 +143,7 @@ static int do_bmp_display(cmd_tbl_t * cmdtp, int flag, int argc, char * const ar return (bmp_display(addr, x, y)); } -static cmd_tbl_t cmd_bmp_sub[] = { +static struct cmd_tbl cmd_bmp_sub[] = { U_BOOT_CMD_MKENT(info, 3, 0, do_bmp_info, "", ""), U_BOOT_CMD_MKENT(display, 5, 0, do_bmp_display, "", ""), }; @@ -162,9 +164,9 @@ void bmp_reloc(void) { * Return: None * */ -static int do_bmp(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_bmp(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; /* Strip off leading 'bmp' command argument */ argc--; diff --git a/cmd/boot.c b/cmd/boot.c index 9150fce80b..36aba22b30 100644 --- a/cmd/boot.c +++ b/cmd/boot.c @@ -16,12 +16,12 @@ /* Allow ports to override the default behavior */ __attribute__((weak)) unsigned long do_go_exec(ulong (*entry)(int, char * const []), int argc, - char * const argv[]) + char *const argv[]) { return entry (argc, argv); } -static int do_go(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_go(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { ulong addr, rc; int rcode = 0; diff --git a/cmd/bootcount.c b/cmd/bootcount.c index c358418ebe..654bbb805c 100644 --- a/cmd/bootcount.c +++ b/cmd/bootcount.c @@ -4,15 +4,15 @@ #include #include -static int do_bootcount_print(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootcount_print(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { printf("%lu\n", bootcount_load()); return CMD_RET_SUCCESS; } -static int do_bootcount_reset(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootcount_reset(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { /* * note that we're explicitly not resetting the environment @@ -22,15 +22,15 @@ static int do_bootcount_reset(cmd_tbl_t *cmdtp, int flag, int argc, return CMD_RET_SUCCESS; } -static cmd_tbl_t bootcount_sub[] = { +static struct cmd_tbl bootcount_sub[] = { U_BOOT_CMD_MKENT(print, 1, 1, do_bootcount_print, "", ""), U_BOOT_CMD_MKENT(reset, 1, 1, do_bootcount_reset, "", ""), }; -static int do_bootcount(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootcount(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *cp; + struct cmd_tbl *cp; if (argc < 2) return CMD_RET_USAGE; diff --git a/cmd/bootefi.c b/cmd/bootefi.c index b84373453d..0f6d0f7750 100644 --- a/cmd/bootefi.c +++ b/cmd/bootefi.c @@ -595,7 +595,8 @@ static int do_efi_selftest(void) * @argv: command line arguments * Return: status code */ -static int do_bootefi(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_bootefi(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { efi_status_t ret; void *fdt; diff --git a/cmd/booti.c b/cmd/booti.c index 4fff8cfcf6..ead2332631 100644 --- a/cmd/booti.c +++ b/cmd/booti.c @@ -18,8 +18,8 @@ DECLARE_GLOBAL_DATA_PTR; /* * Image booting support */ -static int booti_start(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[], bootm_headers_t *images) +static int booti_start(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[], bootm_headers_t *images) { int ret; ulong ld; @@ -98,7 +98,7 @@ static int booti_start(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -int do_booti(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_booti(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int ret; diff --git a/cmd/bootm.c b/cmd/bootm.c index 931d53f0c7..d5f877cb54 100644 --- a/cmd/bootm.c +++ b/cmd/bootm.c @@ -34,12 +34,13 @@ extern flash_info_t flash_info[]; /* info for FLASH chips */ #endif #if defined(CONFIG_CMD_IMLS) || defined(CONFIG_CMD_IMLS_NAND) -static int do_imls(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); +static int do_imls(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]); #endif /* we overload the cmd field with our state machine info instead of a * function pointer */ -static cmd_tbl_t cmd_bootm_sub[] = { +static struct cmd_tbl cmd_bootm_sub[] = { U_BOOT_CMD_MKENT(start, 0, 1, (void *)BOOTM_STATE_START, "", ""), U_BOOT_CMD_MKENT(loados, 0, 1, (void *)BOOTM_STATE_LOADOS, "", ""), #ifdef CONFIG_SYS_BOOT_RAMDISK_HIGH @@ -55,12 +56,12 @@ static cmd_tbl_t cmd_bootm_sub[] = { U_BOOT_CMD_MKENT(go, 0, 1, (void *)BOOTM_STATE_OS_GO, "", ""), }; -static int do_bootm_subcommand(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootm_subcommand(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret = 0; long state; - cmd_tbl_t *c; + struct cmd_tbl *c; c = find_cmd_tbl(argv[0], &cmd_bootm_sub[0], ARRAY_SIZE(cmd_bootm_sub)); argc--; argv++; @@ -89,7 +90,7 @@ static int do_bootm_subcommand(cmd_tbl_t *cmdtp, int flag, int argc, /* bootm - boot application image from image in memory */ /*******************************************************************/ -int do_bootm(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bootm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { #ifdef CONFIG_NEEDS_MANUAL_RELOC static int relocated = 0; @@ -136,7 +137,7 @@ int do_bootm(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) BOOTM_STATE_OS_GO, &images, 1); } -int bootm_maybe_autostart(cmd_tbl_t *cmdtp, const char *cmd) +int bootm_maybe_autostart(struct cmd_tbl *cmdtp, const char *cmd) { const char *ep = env_get("autostart"); @@ -201,7 +202,7 @@ U_BOOT_CMD( /* bootd - boot default image */ /*******************************************************************/ #if defined(CONFIG_CMD_BOOTD) -int do_bootd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bootd(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { return run_command(env_get("bootcmd"), flag); } @@ -226,7 +227,8 @@ U_BOOT_CMD( /* iminfo - print header info for a requested image */ /*******************************************************************/ #if defined(CONFIG_CMD_IMI) -static int do_iminfo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_iminfo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int arg; ulong addr; @@ -519,7 +521,8 @@ static int do_imls_nand(void) #endif #if defined(CONFIG_CMD_IMLS) || defined(CONFIG_CMD_IMLS_NAND) -static int do_imls(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_imls(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ret_nor = 0, ret_nand = 0; diff --git a/cmd/bootmenu.c b/cmd/bootmenu.c index 6af0617e65..2e3f56e152 100644 --- a/cmd/bootmenu.c +++ b/cmd/bootmenu.c @@ -482,7 +482,7 @@ int menu_show(int bootdelay) } #endif -int do_bootmenu(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +int do_bootmenu(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { char *delay_str = NULL; int delay = 10; diff --git a/cmd/bootstage.c b/cmd/bootstage.c index f1ea4e9598..0e623f216b 100644 --- a/cmd/bootstage.c +++ b/cmd/bootstage.c @@ -5,16 +5,17 @@ #include #include +#include -static int do_bootstage_report(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootstage_report(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { bootstage_report(); return 0; } -static int get_base_size(int argc, char * const argv[], ulong *basep, +static int get_base_size(int argc, char *const argv[], ulong *basep, ulong *sizep) { char *endp; @@ -35,8 +36,8 @@ static int get_base_size(int argc, char * const argv[], ulong *basep, return 0; } -static int do_bootstage_stash(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_bootstage_stash(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { ulong base, size; int ret; @@ -58,7 +59,7 @@ static int do_bootstage_stash(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static cmd_tbl_t cmd_bootstage_sub[] = { +static struct cmd_tbl cmd_bootstage_sub[] = { U_BOOT_CMD_MKENT(report, 2, 1, do_bootstage_report, "", ""), U_BOOT_CMD_MKENT(stash, 4, 0, do_bootstage_stash, "", ""), U_BOOT_CMD_MKENT(unstash, 4, 0, do_bootstage_stash, "", ""), @@ -67,10 +68,10 @@ static cmd_tbl_t cmd_bootstage_sub[] = { /* * Process a bootstage sub-command */ -static int do_boostage(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_boostage(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; /* Strip off leading 'bootstage' command argument */ argc--; diff --git a/cmd/bootz.c b/cmd/bootz.c index f14a5fefbf..ac15856f8d 100644 --- a/cmd/bootz.c +++ b/cmd/bootz.c @@ -23,8 +23,8 @@ int __weak bootz_setup(ulong image, ulong *start, ulong *end) /* * zImage booting support */ -static int bootz_start(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[], bootm_headers_t *images) +static int bootz_start(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[], bootm_headers_t *images) { int ret; ulong zi_start, zi_end; @@ -59,7 +59,7 @@ static int bootz_start(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -int do_bootz(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_bootz(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int ret; diff --git a/cmd/btrfs.c b/cmd/btrfs.c index faa1239cc8..7e3cbe12ce 100644 --- a/cmd/btrfs.c +++ b/cmd/btrfs.c @@ -8,7 +8,7 @@ #include #include -int do_btrsubvol(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +int do_btrsubvol(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc != 3) return CMD_RET_USAGE; diff --git a/cmd/cache.c b/cmd/cache.c index 7678615dd8..b68d45b98b 100644 --- a/cmd/cache.c +++ b/cmd/cache.c @@ -24,7 +24,8 @@ __weak void noncached_set_region(void) { } -static int do_icache(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_icache(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { switch (argc) { case 2: /* on / off / flush */ @@ -58,7 +59,8 @@ void __weak flush_dcache_all(void) /* please define arch specific flush_dcache_all */ } -static int do_dcache(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_dcache(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { switch (argc) { case 2: /* on / off / flush */ diff --git a/cmd/cbfs.c b/cmd/cbfs.c index 98e652a4e7..8e91d4bb8c 100644 --- a/cmd/cbfs.c +++ b/cmd/cbfs.c @@ -11,7 +11,7 @@ #include #include -static int do_cbfs_init(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cbfs_init(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { uintptr_t end_of_rom = 0xffffffff; @@ -45,7 +45,7 @@ U_BOOT_CMD( " CBFS is in. It defaults to 0xFFFFFFFF\n" ); -static int do_cbfs_fsload(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cbfs_fsload(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const struct cbfs_cachenode *file; @@ -92,7 +92,7 @@ U_BOOT_CMD( " - load binary file 'filename' from the cbfs to address 'addr'\n" ); -static int do_cbfs_ls(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cbfs_ls(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const struct cbfs_cachenode *file = file_cbfs_get_first(); @@ -201,7 +201,7 @@ U_BOOT_CMD( " - list the files in the cbfs\n" ); -static int do_cbfs_fsinfo(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cbfs_fsinfo(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { const struct cbfs_header *header = file_cbfs_get_header(); diff --git a/cmd/clk.c b/cmd/clk.c index 74ad868500..439736d072 100644 --- a/cmd/clk.c +++ b/cmd/clk.c @@ -72,7 +72,7 @@ int __weak soc_clk_dump(void) } #endif -static int do_clk_dump(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_clk_dump(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int ret; @@ -86,14 +86,14 @@ static int do_clk_dump(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -static cmd_tbl_t cmd_clk_sub[] = { +static struct cmd_tbl cmd_clk_sub[] = { U_BOOT_CMD_MKENT(dump, 1, 1, do_clk_dump, "", ""), }; -static int do_clk(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_clk(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *c; + struct cmd_tbl *c; if (argc < 2) return CMD_RET_USAGE; diff --git a/cmd/cls.c b/cmd/cls.c index f1ce6e8df1..eab4e6993b 100644 --- a/cmd/cls.c +++ b/cmd/cls.c @@ -11,7 +11,7 @@ #include #include -static int do_video_clear(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_video_clear(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { #if defined(CONFIG_DM_VIDEO) diff --git a/cmd/config.c b/cmd/config.c index d2810d573b..cf30841a35 100644 --- a/cmd/config.c +++ b/cmd/config.c @@ -11,7 +11,8 @@ #include "config_data_gz.h" #include "config_data_size.h" -static int do_config(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_config(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *dst; unsigned long len = data_size; diff --git a/cmd/conitrace.c b/cmd/conitrace.c index 85c5422b7e..e45e87a64c 100644 --- a/cmd/conitrace.c +++ b/cmd/conitrace.c @@ -8,8 +8,8 @@ #include #include -static int do_conitrace(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_conitrace(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { bool first = true; diff --git a/cmd/console.c b/cmd/console.c index 3f1d98b17b..9a1db83c7c 100644 --- a/cmd/console.c +++ b/cmd/console.c @@ -12,7 +12,8 @@ #include extern void _do_coninfo (void); -static int do_coninfo(cmd_tbl_t *cmd, int flag, int argc, char * const argv[]) +static int do_coninfo(struct cmd_tbl *cmd, int flag, int argc, + char *const argv[]) { int l; struct list_head *list = stdio_get_list(); diff --git a/cmd/cpu.c b/cmd/cpu.c index 8c0abc1756..ff553c16c4 100644 --- a/cmd/cpu.c +++ b/cmd/cpu.c @@ -64,7 +64,7 @@ static int print_cpu_list(bool detail) return 0; } -static int do_cpu_list(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cpu_list(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (print_cpu_list(false)) @@ -73,7 +73,7 @@ static int do_cpu_list(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_cpu_detail(cmd_tbl_t *cmdtp, int flag, int argc, +static int do_cpu_detail(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (print_cpu_list(true)) @@ -82,7 +82,7 @@ static int do_cpu_detail(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static cmd_tbl_t cmd_cpu_sub[] = { +static struct cmd_tbl cmd_cpu_sub[] = { U_BOOT_CMD_MKENT(list, 2, 1, do_cpu_list, "", ""), U_BOOT_CMD_MKENT(detail, 4, 0, do_cpu_detail, "", ""), }; @@ -90,10 +90,10 @@ static cmd_tbl_t cmd_cpu_sub[] = { /* * Process a cpu sub-command */ -static int do_cpu(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_cpu(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *c = NULL; + struct cmd_tbl *c = NULL; /* Strip off leading 'cpu' command argument */ argc--; diff --git a/cmd/cramfs.c b/cmd/cramfs.c index ad232deae0..1aeb56702c 100644 --- a/cmd/cramfs.c +++ b/cmd/cramfs.c @@ -94,7 +94,8 @@ extern int cramfs_info (struct part_info *info); * @param argv arguments list * @return 0 on success, 1 otherwise */ -int do_cramfs_load(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cramfs_load(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { char *filename; int size; @@ -162,7 +163,7 @@ int do_cramfs_load(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) * @param argv arguments list * @return 0 on success, 1 otherwise */ -int do_cramfs_ls(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_cramfs_ls(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { char *filename = "/"; int ret; diff --git a/cmd/cros_ec.c b/cmd/cros_ec.c index c6bbed9c4a..3c7dd4db9b 100644 --- a/cmd/cros_ec.c +++ b/cmd/cros_ec.c @@ -24,7 +24,7 @@ static const char * const ec_current_image_name[] = {"unknown", "RO", "RW"}; * @param argv List of remaining parameters * @return flash region (EC_FLASH_REGION_...) or -1 on error */ -static int cros_ec_decode_region(int argc, char * const argv[]) +static int cros_ec_decode_region(int argc, char *const argv[]) { if (argc > 0) { if (0 == strcmp(*argv, "rw")) @@ -51,7 +51,7 @@ static int cros_ec_decode_region(int argc, char * const argv[]) * (negative EC_RES_...) */ static int do_read_write(struct udevice *dev, int is_write, int argc, - char * const argv[]) + char *const argv[]) { uint32_t offset, size = -1U, region_size; unsigned long addr; @@ -93,7 +93,8 @@ static int do_read_write(struct udevice *dev, int is_write, int argc, return 0; } -static int do_cros_ec(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_cros_ec(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct udevice *dev; const char *cmd; diff --git a/cmd/dataflash_mmc_mux.c b/cmd/dataflash_mmc_mux.c index 9f271b6f61..73876e9464 100644 --- a/cmd/dataflash_mmc_mux.c +++ b/cmd/dataflash_mmc_mux.c @@ -9,7 +9,8 @@ static int mmc_nspi (const char *); -int do_dataflash_mmc_mux (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_dataflash_mmc_mux(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { switch (argc) { case 2: /* on / off */ diff --git a/cmd/date.c b/cmd/date.c index 7fa950a902..75a032cd27 100644 --- a/cmd/date.c +++ b/cmd/date.c @@ -29,7 +29,8 @@ int mk_date (const char *, struct rtc_time *); static struct rtc_time default_tm = { 0, 0, 0, 1, 1, 2000, 6, 0, 0 }; -static int do_date(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_date(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct rtc_time tm; int rcode = 0; diff --git a/cmd/demo.c b/cmd/demo.c index 52c6e7ec15..9da06f5e4d 100644 --- a/cmd/demo.c +++ b/cmd/demo.c @@ -7,14 +7,15 @@ */ #include +#include #include #include #include struct udevice *demo_dev; -static int do_demo_hello(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_demo_hello(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int ch = 0; @@ -24,8 +25,8 @@ static int do_demo_hello(cmd_tbl_t *cmdtp, int flag, int argc, return demo_hello(demo_dev, ch); } -static int do_demo_status(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_demo_status(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int status; int ret; @@ -39,8 +40,8 @@ static int do_demo_status(cmd_tbl_t *cmdtp, int flag, int argc, return 0; } -static int do_demo_light(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_demo_light(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int light; int ret; @@ -59,7 +60,7 @@ static int do_demo_light(cmd_tbl_t *cmdtp, int flag, int argc, return ret; } -int do_demo_list(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_demo_list(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { struct udevice *dev; int i, ret; @@ -78,16 +79,17 @@ int do_demo_list(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return cmd_process_error(cmdtp, ret); } -static cmd_tbl_t demo_commands[] = { +static struct cmd_tbl demo_commands[] = { U_BOOT_CMD_MKENT(list, 0, 1, do_demo_list, "", ""), U_BOOT_CMD_MKENT(hello, 2, 1, do_demo_hello, "", ""), U_BOOT_CMD_MKENT(light, 2, 1, do_demo_light, "", ""), U_BOOT_CMD_MKENT(status, 1, 1, do_demo_status, "", ""), }; -static int do_demo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_demo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { - cmd_tbl_t *demo_cmd; + struct cmd_tbl *demo_cmd; int devnum = 0; int ret; diff --git a/cmd/dfu.c b/cmd/dfu.c index b30f8a5667..7310595a02 100644 --- a/cmd/dfu.c +++ b/cmd/dfu.c @@ -11,6 +11,7 @@ */ #include +#include #include #include #include @@ -18,7 +19,7 @@ #include #include -static int do_dfu(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_dfu(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { if (argc < 2) diff --git a/cmd/diag.c b/cmd/diag.c index 8d21c7dde8..f51536dbfa 100644 --- a/cmd/diag.c +++ b/cmd/diag.c @@ -11,7 +11,7 @@ #include #include -int do_diag (cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) +int do_diag(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { unsigned int i; diff --git a/cmd/disk.c b/cmd/disk.c index da0660148c..dbd08a06b2 100644 --- a/cmd/disk.c +++ b/cmd/disk.c @@ -10,7 +10,7 @@ #include #include -int common_diskboot(cmd_tbl_t *cmdtp, const char *intf, int argc, +int common_diskboot(struct cmd_tbl *cmdtp, const char *intf, int argc, char *const argv[]) { __maybe_unused int dev; diff --git a/cmd/dm.c b/cmd/dm.c index 7a90685f8b..4e307ac524 100644 --- a/cmd/dm.c +++ b/cmd/dm.c @@ -16,39 +16,39 @@ #include #include -static int do_dm_dump_all(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_dm_dump_all(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { dm_dump_all(); return 0; } -static int do_dm_dump_uclass(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_dm_dump_uclass(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { dm_dump_uclass(); return 0; } -static int do_dm_dump_devres(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_dm_dump_devres(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { dm_dump_devres(); return 0; } -static int do_dm_dump_drivers(cmd_tbl_t *cmdtp, int flag, int argc, - char * const argv[]) +static int do_dm_dump_drivers(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { dm_dump_drivers(); return 0; } -static cmd_tbl_t test_commands[] = { +static struct cmd_tbl test_commands[] = { U_BOOT_CMD_MKENT(tree, 0, 1, do_dm_dump_all, "", ""), U_BOOT_CMD_MKENT(uclass, 1, 1, do_dm_dump_uclass, "", ""), U_BOOT_CMD_MKENT(devres, 1, 1, do_dm_dump_devres, "", ""), @@ -65,9 +65,9 @@ static __maybe_unused void dm_reloc(void) } } -static int do_dm(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_dm(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *test_cmd; + struct cmd_tbl *test_cmd; int ret; #ifdef CONFIG_NEEDS_MANUAL_RELOC diff --git a/cmd/echo.c b/cmd/echo.c index 5b018d9349..d02a4cfd58 100644 --- a/cmd/echo.c +++ b/cmd/echo.c @@ -7,7 +7,8 @@ #include #include -static int do_echo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_echo(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { int i; int putnl = 1; diff --git a/cmd/eeprom.c b/cmd/eeprom.c index 792415ef93..f61a5510e8 100644 --- a/cmd/eeprom.c +++ b/cmd/eeprom.c @@ -237,7 +237,7 @@ static int parse_numeric_param(char *str) * @returns: number of arguments parsed or CMD_RET_USAGE if error */ static int parse_i2c_bus_addr(int *i2c_bus, ulong *i2c_addr, int argc, - char * const argv[], int argc_no_bus_addr) + char *const argv[], int argc_no_bus_addr) { int argc_no_bus = argc_no_bus_addr + 1; int argc_bus_addr = argc_no_bus_addr + 2; @@ -355,7 +355,7 @@ static int eeprom_execute_command(enum eeprom_action action, int i2c_bus, } #define NEXT_PARAM(argc, index) { (argc)--; (index)++; } -int do_eeprom(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +int do_eeprom(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { int layout_ver = LAYOUT_VERSION_AUTODETECT; enum eeprom_action action = EEPROM_ACTION_INVALID; diff --git a/cmd/efi.c b/cmd/efi.c index ea239a01f0..c7640c862e 100644 --- a/cmd/efi.c +++ b/cmd/efi.c @@ -191,7 +191,8 @@ static void efi_print_mem_table(struct efi_entry_memmap *map, printf("*Some areas are merged (use 'all' to see)\n"); } -static int do_efi_mem(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_efi_mem(struct cmd_tbl *cmdtp, int flag, int argc, + char *const argv[]) { struct efi_mem_desc *desc; struct efi_entry_memmap *map; @@ -231,13 +232,13 @@ done: return ret ? CMD_RET_FAILURE : 0; } -static cmd_tbl_t efi_commands[] = { +static struct cmd_tbl efi_commands[] = { U_BOOT_CMD_MKENT(mem, 1, 1, do_efi_mem, "", ""), }; -static int do_efi(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +static int do_efi(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) { - cmd_tbl_t *efi_cmd; + struct cmd_tbl *efi_cmd; int ret; if (argc < 2) diff --git a/cmd/efidebug.c b/cmd/efidebug.c index f020d95dbb..9b5bf1e6cf 100644 --- a/cmd/efidebug.c +++ b/cmd/efidebug.c @@ -60,8 +60,8 @@ static const char sep[] = "================"; * Implement efidebug "devices" sub-command. * Show all UEFI devices and their information. */ -static int do_efi_show_devices(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_devices(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { efi_handle_t *handles; efi_uintn_t num, i; @@ -139,8 +139,8 @@ static int efi_get_driver_handle_info(efi_handle_t handle, u16 **driver_name, * Implement efidebug "drivers" sub-command. * Show all UEFI drivers and their information. */ -static int do_efi_show_drivers(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_drivers(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { efi_handle_t *handles; efi_uintn_t num, i; @@ -311,8 +311,8 @@ static const char *get_guid_text(const void *guid) * Show all UEFI handles and their information, currently all protocols * added to handle. */ -static int do_efi_show_handles(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_handles(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { efi_handle_t *handles; efi_guid_t **guid; @@ -371,8 +371,8 @@ static int do_efi_show_handles(cmd_tbl_t *cmdtp, int flag, * Implement efidebug "images" sub-command. * Show all UEFI loaded images and their information. */ -static int do_efi_show_images(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_images(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { efi_print_image_infos(NULL); @@ -453,8 +453,8 @@ static void print_memory_attributes(u64 attributes) * Implement efidebug "memmap" sub-command. * Show UEFI memory map. */ -static int do_efi_show_memmap(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_memmap(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { struct efi_mem_desc *memmap = NULL, *map; efi_uintn_t map_size = 0; @@ -521,8 +521,8 @@ static int do_efi_show_memmap(cmd_tbl_t *cmdtp, int flag, * Implement efidebug "tables" sub-command. * Show UEFI configuration tables. */ -static int do_efi_show_tables(cmd_tbl_t *cmdtp, int flag, - int argc, char * const argv[]) +static int do_efi_show_tables(struct cmd_tbl *cmdtp, int flag, + int argc, char *const argv[]) { efi_uintn_t i; const char *guid_str; @@ -551,8 +551,8 @@ static int do_efi_show_tables(cmd_tbl_t *cmdtp, int flag, * * efidebug boot add