diff options
author | pancake <pancake@dazo> | 2007-06-11 02:29:11 +0200 |
---|---|---|
committer | pancake <pancake@dazo> | 2007-06-11 02:29:11 +0200 |
commit | a3af55acb4141cd0d23f53b2ec0c5c1d2434aa22 (patch) | |
tree | 03cfa1c2e5d0c0cf39dae4be5373fb0ad4f36765 /src/main.c | |
parent | 83b41f9371fa221ee701bb83cf5c72f5984dcfaa (diff) | |
download | 0xFFFF-a3af55acb4141cd0d23f53b2ec0c5c1d2434aa22.tar.bz2 |
* Initial implementation of the pretty-print config partition dumper
* Handled with the '-x' flag.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -93,6 +93,7 @@ void show_usage() printf(" -d [vid:pid] injects a usb device into the supported list\n"); printf(" -D [0|1|2] sets the root device to flash (0), mmc (1) or usb (2)\n"); printf(" -R reboot the omap board\n"); + printf(" -x extract configuration entries from /dev/mtd1\n"); printf(" -v be verbose and noisy\n"); printf(" -V show 0xFFFF version information\n"); printf("Pieces are: "); @@ -152,8 +153,10 @@ int main(int argc, char **argv) { int c; - while((c = getopt(argc, argv, "C:cp:vVhRu:ib:U:r:e:ld:I:D:f:s:")) != -1) { + while((c = getopt(argc, argv, "C:cp:vVhRu:ib:U:r:e:ld:I:D:f:s:x")) != -1) { switch(c) { + case 'x': + return dump_config(); case 'c': return console_prompt(); case 'd': @@ -240,7 +243,7 @@ int main(int argc, char **argv) && (root_device == -1)) { printf("Usage: 0xFFFF [-hvVRi] [-e path] [-U 0|1] [-p [piece%%]file [-p ...]]\n"); - printf(" [-b boot-args] [-I piece [-I ...]] [-u fiasco-image]\n"); + printf(" [-b boot-args] [-I piece [-I ...]] [-u fiasco-image] [-x]\n"); printf(" [-D 0|1|2] [-F rd flags] [-s serial-dev] [-c] [-C mtd-dev]\n"); return 1; } |