diff options
author | Peter Stuge <peter@stuge.se> | 2008-01-27 16:21:21 +0000 |
---|---|---|
committer | Peter Stuge <peter@stuge.se> | 2008-01-27 16:21:21 +0000 |
commit | 6b53fed02d38d7d7a53afeac540d1c7e8ace4ec3 (patch) | |
tree | f93b1a792eec2ea04d1196a725fa4cbd796a7918 /flashrom.c | |
parent | 79fd6d21d2d41c74e03973a6be6851e9086de7eb (diff) | |
download | ast2050-flashrom-6b53fed02d38d7d7a53afeac540d1c7e8ace4ec3.zip ast2050-flashrom-6b53fed02d38d7d7a53afeac540d1c7e8ace4ec3.tar.gz |
Make the vendor name optional in the -m flashrom parameter when there's only one board name that matches
The full syntax still works, and is required when two vendors have
boards with the same names.
Corresponding to flashrom svn r190 and coreboot v2 svn r3082.
Signed-off-by: Peter Stuge <peter@stuge.se>
Acked-by: Stefan Reinauer <stepan@coresystems.de>
Diffstat (limited to 'flashrom.c')
-rw-r--r-- | flashrom.c | 32 |
1 files changed, 16 insertions, 16 deletions
@@ -196,21 +196,21 @@ int verify_flash(struct flashchip *flash, uint8_t *buf) void usage(const char *name) { printf("usage: %s [-rwvEVfhR] [-c chipname] [-s exclude_start]\n", name); - printf(" [-e exclude_end] [-m vendor:part] [-l file.layout] [-i imagename] [file]\n"); + printf(" [-e exclude_end] [-m [vendor:]part] [-l file.layout] [-i imagename] [file]\n"); printf - (" -r | --read: read flash and save into file\n" - " -w | --write: write file into flash\n" - " -v | --verify: verify flash against file\n" - " -E | --erase: erase flash device\n" - " -V | --verbose: more verbose output\n" - " -c | --chip <chipname>: probe only for specified flash chip\n" - " -s | --estart <addr>: exclude start position\n" - " -e | --eend <addr>: exclude end postion\n" - " -m | --mainboard <vendor:part>: override mainboard settings\n" - " -f | --force: force write without checking image\n" - " -l | --layout <file.layout>: read rom layout from file\n" - " -i | --image <name>: only flash image name from flash layout\n" - " -R | --version: print the version (release)\n" + (" -r | --read: read flash and save into file\n" + " -w | --write: write file into flash\n" + " -v | --verify: verify flash against file\n" + " -E | --erase: erase flash device\n" + " -V | --verbose: more verbose output\n" + " -c | --chip <chipname>: probe only for specified flash chip\n" + " -s | --estart <addr>: exclude start position\n" + " -e | --eend <addr>: exclude end postion\n" + " -m | --mainboard <[vendor:]part>: override mainboard settings\n" + " -f | --force: force write without checking image\n" + " -l | --layout <file.layout>: read rom layout from file\n" + " -i | --image <name>: only flash image name from flash layout\n" + " -R | --version: print the version (release)\n" "\n" " If no file is specified, then all that happens" " is that flash info is dumped.\n\n"); exit(1); @@ -301,8 +301,8 @@ int main(int argc, char *argv[]) lb_vendor = tempstr; lb_part = tempstr2; } else { - printf("warning: ignored wrong format of" - " mainboard: %s\n", tempstr); + lb_vendor = NULL; + lb_part = tempstr; } break; case 'f': |