Samuel Holland has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36049 )
Change subject: util/ifdtool: Fix argument parsing for layout/validate ......................................................................
util/ifdtool: Fix argument parsing for layout/validate
When `mode_validate` was added, a second copy of `mode_layout` was accidentally added to the multiple-mode-argument check instead. This prevents `-f` from working. Fix the check to reference the correct variable.
Change-Id: Ibac6f090550ff63ec9158355b0450da204a300a7 Signed-off-by: Samuel Holland samuel@sholland.org --- M util/ifdtool/ifdtool.c 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/49/36049/1
diff --git a/util/ifdtool/ifdtool.c b/util/ifdtool/ifdtool.c index 0e83c76..24e20e1 100644 --- a/util/ifdtool/ifdtool.c +++ b/util/ifdtool/ifdtool.c @@ -1659,7 +1659,7 @@
if ((mode_dump + mode_layout + mode_extract + mode_inject + mode_newlayout + (mode_spifreq | mode_em100 | mode_unlocked | - mode_locked) + mode_altmedisable + mode_layout) > 1) { + mode_locked) + mode_altmedisable + mode_validate) > 1) { fprintf(stderr, "You may not specify more than one mode.\n\n"); print_usage(argv[0]); exit(EXIT_FAILURE);