Sync. usage string and synopsis. Add rcsid.

This commit is contained in:
Philippe Charnier 1998-01-05 07:10:42 +00:00
parent 49fea209d4
commit 57e78ffb16
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=32270
4 changed files with 27 additions and 26 deletions

View File

@ -23,7 +23,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
.\" $Id: kldstat.8,v 1.1 1997/05/07 18:19:54 dfr Exp $
.\" $Id: kldstat.8,v 1.2 1997/10/21 09:59:22 jmg Exp $
.\"
.Dd April 25, 1997
.Dt KLDSTAT 8
@ -35,15 +35,15 @@
.Nm kldstat
.Op Fl v
.Op Fl i Ar id
.Op Fl n Ar filename
.Op Fl n Ar name
.Sh DESCRIPTION
The
.Nm
utility displays the status of any files dynamically linked into the
kernel.
.Pp
The options are:
.Bl -tag -width XXXXXXX -offset indent
The following options are available:
.Bl -tag -width indent
.It Fl v
Be more verbose.
.It Fl i Ar id
@ -60,7 +60,4 @@ The
command first appeared in
.Fx 3.0 .
.Sh AUTHOR
.Bl -tag
Doug Rabson
.Aq dfr@freebsd.org
.El.
.An Doug Rabson Aq dfr@freebsd.org

View File

@ -22,10 +22,13 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: kldstat.c,v 1.2 1997/10/19 11:15:44 jmg Exp $
*/
#ifndef lint
static const char rcsid[] =
"$Id$";
#endif /* not lint */
#include <err.h>
#include <stdio.h>
#include <stdlib.h>
@ -42,7 +45,7 @@ printmod(int modid)
stat.version = sizeof(struct module_stat);
if (modstat(modid, &stat) < 0)
warn("Can't stat module id %d", modid);
warn("can't stat module id %d", modid);
else
printf("\t\t%2d %s\n", stat.id, stat.name);
}
@ -54,7 +57,7 @@ static void printfile(int fileid, int verbose)
stat.version = sizeof(struct kld_file_stat);
if (kldstat(fileid, &stat) < 0)
warn("Can't stat file id %d", fileid);
warn("can't stat file id %d", fileid);
else
printf("%2d %4d %p %-8x %s\n",
stat.id, stat.refs, stat.address, stat.size, stat.name);
@ -71,7 +74,7 @@ static void printfile(int fileid, int verbose)
static void
usage(void)
{
fprintf(stderr, "usage: kldstat [-v]\n");
fprintf(stderr, "usage: kldstat [-v] [-i id] [-n name]\n");
exit(1);
}
@ -105,7 +108,7 @@ main(int argc, char** argv)
if (filename) {
if ((fileid = kldfind(filename)) < 0)
err(1, "Can't find file %s", filename);
err(1, "can't find file %s", filename);
}
printf("Id Refs Address Size Name\n");

View File

@ -23,7 +23,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
.\" $Id: kldunload.8,v 1.1 1997/05/07 18:19:54 dfr Exp $
.\" $Id: kldunload.8,v 1.2 1997/10/21 09:59:25 jmg Exp $
.\"
.Dd April 25, 1997
.Dt KLDUNLOAD 8
@ -35,15 +35,15 @@
.Nm kldunload
.Op Fl v
.Op Fl i Ar id
.Op Fl n Ar filename
.Op Fl n Ar name
.Sh DESCRIPTION
The
.Nm
utility unloads a file which was previously loaded with
.Xr kldload 8 .
.Pp
The options are:
.Bl -tag -width XXXXXXX -offset indent
The following options are available:
.Bl -tag -width indent
.It Fl v
Be more verbose.
.It Fl i Ar id
@ -60,5 +60,4 @@ The
command first appeared in
.Fx 3.0 .
.Sh AUTHOR
Doug Rabson
.Aq dfr@freebsd.org
.An Doug Rabson Aq dfr@freebsd.org

View File

@ -22,10 +22,13 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: kldunload.c,v 1.3 1997/10/21 09:59:26 jmg Exp $
*/
#ifndef lint
static const char rcsid[] =
"$Id$";
#endif /* not lint */
#include <err.h>
#include <stdio.h>
#include <stdlib.h>
@ -36,7 +39,7 @@
static void
usage(void)
{
fprintf(stderr, "usage: kldunload [-i id] [-n filename]\n");
fprintf(stderr, "usage: kldunload [-v] [-i id] [-n name]\n");
exit(1);
}
@ -73,7 +76,7 @@ main(int argc, char** argv)
if (filename) {
if ((fileid = kldfind(filename)) < 0)
err(1, "Can't find file %s", filename);
err(1, "can't find file %s", filename);
}
if (verbose) {
@ -85,8 +88,7 @@ main(int argc, char** argv)
}
if (kldunload(fileid) < 0)
err(1, "Can't unload file");
err(1, "can't unload file");
return 0;
}