From 9a5d6e958f4ff9fd35439bf6c6f37c852725592c Mon Sep 17 00:00:00 2001 From: Arthur Heymans Date: Wed, 17 Feb 2021 14:57:02 +0100 Subject: [PATCH] util/cbfstool/ifittool: Remove dead code The 'x' option is not set up in the getopt options. Change-Id: Ib4aa10b0ea2a3f97e8d2439152b708613bcf43db Signed-off-by: Arthur Heymans Reviewed-on: https://review.coreboot.org/c/coreboot/+/50923 Tested-by: build bot (Jenkins) Reviewed-by: Angel Pons --- util/cbfstool/ifittool.c | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/util/cbfstool/ifittool.c b/util/cbfstool/ifittool.c index 7e99d4fd43..10ed2eb012 100644 --- a/util/cbfstool/ifittool.c +++ b/util/cbfstool/ifittool.c @@ -127,7 +127,6 @@ enum fit_operation { NO_OP = 0, ADD_CBFS_OP, ADD_REGI_OP, - ADD_ADDR_OP, DEL_OP }; @@ -182,15 +181,6 @@ int main(int argc, char *argv[]) } op = ADD_REGI_OP; break; - case 'x': - if (op != NO_OP) { - ERROR("specified multiple actions at once\n"); - usage(argv[0]); - return 1; - } - op = ADD_ADDR_OP; - addr = atoll(optarg); - break; case 'c': clear_table = true; break; @@ -262,17 +252,6 @@ int main(int argc, char *argv[]) return 1; } } - if (op == ADD_ADDR_OP) { - if (fit_type == 0) { - ERROR("Adding FIT entry, but no type given\n"); - usage(argv[0]); - return 1; - } else if (max_table_size == 0) { - ERROR("Maximum table size not given\n"); - usage(argv[0]); - return 1; - } - } if (!region_name) { ERROR("Region not given\n"); @@ -373,15 +352,6 @@ int main(int argc, char *argv[]) } break; } - case ADD_ADDR_OP: - { - if (fit_add_entry(fit, addr, 0, fit_type, max_table_size)) { - partitioned_file_close(image_file); - ERROR("Adding type %u FIT entry\n", fit_type); - return 1; - } - } - break; case DEL_OP: { if (fit_delete_entry(fit, table_entry)) {