summaryrefslogtreecommitdiffstats
path: root/usr.sbin/fwcontrol/fwcontrol.c
diff options
context:
space:
mode:
authorsimokawa <simokawa@FreeBSD.org>2003-02-09 07:26:48 +0000
committersimokawa <simokawa@FreeBSD.org>2003-02-09 07:26:48 +0000
commit4cf30c0db17b52d457836b0b562462e7122bf29e (patch)
treee348d1192cfb566722a20a07790701f2765b7c3e /usr.sbin/fwcontrol/fwcontrol.c
parentedadda996abe3ce21aa9a1b10dbccc363acfec42 (diff)
downloadFreeBSD-src-4cf30c0db17b52d457836b0b562462e7122bf29e.zip
FreeBSD-src-4cf30c0db17b52d457836b0b562462e7122bf29e.tar.gz
Improve device listing.
Diffstat (limited to 'usr.sbin/fwcontrol/fwcontrol.c')
-rw-r--r--usr.sbin/fwcontrol/fwcontrol.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/usr.sbin/fwcontrol/fwcontrol.c b/usr.sbin/fwcontrol/fwcontrol.c
index d27896a..6044ece 100644
--- a/usr.sbin/fwcontrol/fwcontrol.c
+++ b/usr.sbin/fwcontrol/fwcontrol.c
@@ -95,11 +95,11 @@ list_dev(int fd)
data = get_dev(fd);
printf("%d devices (info_len=%d)\n", data->n, data->info_len);
+ printf("node EUI64 status\n");
for (i = 0; i < data->info_len; i++) {
devinfo = &data->dev[i];
- printf("%d node %d eui:%08x%08x status:%d\n",
- i,
- devinfo->dst,
+ printf("%4d %08x%08x %6d\n",
+ (devinfo->status || i == 0) ? devinfo->dst : -1,
devinfo->eui.hi,
devinfo->eui.lo,
devinfo->status
@@ -376,7 +376,6 @@ main(int argc, char **argv)
if (argc < 2) {
list_dev(fd);
- usage();
}
while ((ch = getopt(argc, argv, "g:b:rtc:d:l:R:S:")) != -1)
OpenPOWER on IntegriCloud