From b02989fe9544311179cd9b333f9d9e450410c6bb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?V=C3=A1clav=20Pavl=C3=ADn?= <vpavlin@redhat.com>
Date: Tue, 9 Apr 2013 14:25:14 +0200
Subject: [PATCH] Update help and man to cover all possible arguments
---
biosdevname.1 | 8 ++++----
src/bios_dev_name.c | 12 ++++++------
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/biosdevname.1 b/biosdevname.1
index 7067a56..22a53bd 100644
--- a/biosdevname.1
+++ b/biosdevname.1
@@ -31,16 +31,16 @@ Treat [args] as ethernet devs
.B \-d, \-\-debug
Enable debugging
.TP
-.B \-\-policy \fI[physical|all_ethN]
+.B \-p, \-\-policy \fI[physical|all_ethN]
.TP
-.B \-\-prefix \fI[string]
+.B \-P, \-\-prefix \fI[string]
string use for embedded NICs in the physical policy (default=em)
.TP
-.B \-\-nopirq
+.B \-x, \-\-nopirq
Do not use $PIR table for mapping PCI device to slot. Some BIOS have
incorrect values.
.TP
-.B \-\-smbios \fI[x.y]
+.B \-s, \-\-smbios \fI[x.y]
Require minimum SMBIOS version x.y
.SH POLICIES
.br
diff --git a/src/bios_dev_name.c b/src/bios_dev_name.c
index 6084d28..5001f85 100644
--- a/src/bios_dev_name.c
+++ b/src/bios_dev_name.c
@@ -25,11 +25,11 @@ static void usage(void)
fprintf(stderr, " Options:\n");
fprintf(stderr, " -i or --interface treat [args] as ethernet devs\n");
fprintf(stderr, " -d or --debug enable debugging\n");
- fprintf(stderr, " --policy [physical | all_ethN ]\n");
- fprintf(stderr, " --prefix [string] string use for embedded NICs (default='em')\n");
- fprintf(stderr, " --smbios [x.y] Require SMBIOS x.y or greater\n");
- fprintf(stderr, " --nopirq Don't use $PIR table for slot numbers\n");
- fprintf(stderr, " --version Show biosdevname version\n");
+ fprintf(stderr, " -p or --policy [physical | all_ethN ]\n");
+ fprintf(stderr, " -P or --prefix [string] string use for embedded NICs (default='em')\n");
+ fprintf(stderr, " -s or --smbios [x.y] Require SMBIOS x.y or greater\n");
+ fprintf(stderr, " -x or --nopirq Don't use $PIR table for slot numbers\n");
+ fprintf(stderr, " -v or --version Show biosdevname version\n");
fprintf(stderr, " Example: biosdevname -i eth0\n");
fprintf(stderr, " returns: em1\n");
fprintf(stderr, " when eth0 is an embedded NIC with label '1' on the chassis.\n");
@@ -68,7 +68,7 @@ parse_opts(int argc, char **argv)
{0, 0, 0, 0}
};
c = getopt_long(argc, argv,
- "dinp:",
+ "dip:",
long_options, &option_index);
if (c == -1)
break;
--
1.8.1.4