diff options
author | msmith <msmith@FreeBSD.org> | 1998-10-31 02:48:29 +0000 |
---|---|---|
committer | msmith <msmith@FreeBSD.org> | 1998-10-31 02:48:29 +0000 |
commit | e6108119c4a18c3dd11e5fda0bbd6b84a63a923f (patch) | |
tree | 77ffcdb32b212aed315a6b8b4ea9e120a4452dff /lib/libstand/dev_net.c | |
parent | 02030ba04b7d957e3218848bb30779ab2dbd82b1 (diff) | |
download | FreeBSD-src-e6108119c4a18c3dd11e5fda0bbd6b84a63a923f.zip FreeBSD-src-e6108119c4a18c3dd11e5fda0bbd6b84a63a923f.tar.gz |
Add a new field to the devsw structure; dv_print, to print all valid units
etc. associated with the device entry.
Consider EOF an 'error' for fgetstr if we haven't read anything yet.
You *MUST* recompile and reinstall libstand before rebuilding the bootstrap.
Diffstat (limited to 'lib/libstand/dev_net.c')
-rw-r--r-- | lib/libstand/dev_net.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/libstand/dev_net.c b/lib/libstand/dev_net.c index 8d09e4f..cfa9fbf 100644 --- a/lib/libstand/dev_net.c +++ b/lib/libstand/dev_net.c @@ -73,6 +73,8 @@ static int netdev_opens; static int net_getparams(int sock); +static void net_print(int verbose); + struct devsw netdev = { "net", DEVT_NET, @@ -81,9 +83,20 @@ struct devsw netdev = { net_open, net_close, noioctl + net_print, }; /* + * Print stuff about our net 'device'. + */ +static void +net_print(int verbose) +{ + pager_output(" net: network interface"); + /* XXX much more verbose stuff here */ +} + +/* * Called by devopen after it sets f->f_dev to our devsw entry. * This opens the low-level device and sets f->f_devdata. * This is declared with variable arguments... |