2008-02-11 Martin Mares <mj@ucw.cz>
+ * lspci.c, setpci.c: Cleaned up the list of options.
+
* lib/names.c: Fix displaying of errors reported by zlib.
Previously, the buffer containing the error message had
been deallocated by gzclose() before the message was printed.
static char options[] = "nvbxs:d:ti:mgp:kMD" GENERIC_OPTIONS ;
-static char help_msg[] = "\
-Usage: lspci [<switches>]\n\
-\n\
--v\t\tBe verbose\n\
--n\t\tShow numeric ID's\n\
--nn\t\tShow both textual and numeric ID's (names & numbers)\n\
--b\t\tBus-centric view (PCI addresses and IRQ's instead of those seen by the CPU)\n\
--x\t\tShow hex-dump of the standard portion of config space\n\
--xxx\t\tShow hex-dump of the whole config space (dangerous; root only)\n\
--xxxx\t\tShow hex-dump of the 4096-byte extended config space (root only)\n\
--s [[[[<domain>]:]<bus>]:][<slot>][.[<func>]]\tShow only devices in selected slots\n\
--d [<vendor>]:[<device>]\tShow only selected devices\n\
--t\t\tShow bus tree\n\
--m\t\tProduce machine-readable output\n\
--i <file>\tUse specified ID database instead of %s\n"
+static char help_msg[] =
+"Usage: lspci [<switches>]\n"
+"\n"
+"-v\t\tBe verbose\n"
+"-n\t\tShow numeric ID's\n"
+"-nn\t\tShow both textual and numeric ID's (names & numbers)\n"
+"-b\t\tBus-centric view (PCI addresses and IRQ's instead of those seen by the CPU)\n"
+"-x\t\tShow hex-dump of the standard portion of config space\n"
+"-xxx\t\tShow hex-dump of the whole config space (dangerous; root only)\n"
+"-xxxx\t\tShow hex-dump of the 4096-byte extended config space (root only)\n"
+"-s [[[[<domain>]:]<bus>]:][<slot>][.[<func>]]\tShow only devices in selected slots\n"
+"-d [<vendor>]:[<device>]\tShow only selected devices\n"
+"-t\t\tShow bus tree\n"
+"-m\t\tProduce machine-readable output\n"
+"-i <file>\tUse specified ID database instead of %s\n"
#ifdef PCI_OS_LINUX
-"\
--k\t\tShow kernel drivers handling each device\n\
--p <file>\tLook up kernel modules in a given file instead of default modules.pcimap\n"
+"-k\t\tShow kernel drivers handling each device\n"
+"-p <file>\tLook up kernel modules in a given file instead of default modules.pcimap\n"
#endif
-"\
--D\t\tAlways show domain numbers\n\
--M\t\tEnable `bus mapping' mode (dangerous; root only)\n"
+"-D\t\tAlways show domain numbers\n"
+"-M\t\tEnable `bus mapping' mode (dangerous; root only)\n"
GENERIC_HELP
;
fprintf(stderr, "\n\n");
}
fprintf(stderr,
-"Usage: setpci [<options>] (<device>+ <reg>[=<values>]*)*\n\
--f\t\tDon't complain if there's nothing to do\n\
--v\t\tBe verbose\n\
--D\t\tList changes, don't commit them\n"
+"Usage: setpci [<options>] (<device>+ <reg>[=<values>]*)*\n"
+"-f\t\tDon't complain if there's nothing to do\n"
+"-v\t\tBe verbose\n"
+"-D\t\tList changes, don't commit them\n"
GENERIC_HELP
"<device>:\t-s [[[<domain>]:][<bus>]:][<slot>][.[<func>]]\n"
"\t|\t-d [<vendor>]:[<device>]\n"