From 09140113108541b95d340f3c7b6ee597d31ccc73 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Sun, 10 May 2020 11:40:03 -0600 Subject: 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 --- cmd/blkcache.c | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'cmd/blkcache.c') diff --git a/cmd/blkcache.c b/cmd/blkcache.c index 2cc65a9..25f252e 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(); -- cgit v1.1