Add optional "-f disktab" argument, that will look up a disk
typename in the given disktab(5) file, instead of in /etc/disktab.
This commit is contained in:
parent
fb1ea64022
commit
bba72d2b40
|
@ -1,4 +1,4 @@
|
|||
.\" $NetBSD: vnconfig.8,v 1.19 2001/11/08 15:41:55 christos Exp $
|
||||
.\" $NetBSD: vnconfig.8,v 1.20 2001/12/12 16:55:10 fredette Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1997 The NetBSD Foundation, Inc.
|
||||
.\" All rights reserved.
|
||||
|
@ -79,8 +79,9 @@
|
|||
.Nm vnconfig
|
||||
.Nd configure vnode disks
|
||||
.Sh SYNOPSIS
|
||||
.Nm
|
||||
.Nm ""
|
||||
.Op Fl c
|
||||
.Op Fl f Ar disktab
|
||||
.Op Fl t Ar typename
|
||||
.Op Fl v
|
||||
.Ar vnode_disk
|
||||
|
@ -138,6 +139,13 @@ is the number of sectors per track.
|
|||
is the number of tracks per cylinder.
|
||||
.Ar ncylinders
|
||||
is the number of cylinders in the device.
|
||||
.It Fl f Ar disktab
|
||||
Specifies that the
|
||||
.Fl t
|
||||
option should look up in
|
||||
.Ar disktab
|
||||
instead of in
|
||||
.Pa /etc/disktab .
|
||||
.It Fl t Ar typename
|
||||
If configuring the device, look up
|
||||
.Ar typename
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: vnconfig.c,v 1.23 2001/11/08 07:44:32 tron Exp $ */
|
||||
/* $NetBSD: vnconfig.c,v 1.24 2001/12/12 16:55:10 fredette Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1997 The NetBSD Foundation, Inc.
|
||||
|
@ -116,11 +116,15 @@ main(argc, argv)
|
|||
{
|
||||
int ch, rv, action = VND_CONFIG;
|
||||
|
||||
while ((ch = getopt(argc, argv, "ct:uv")) != -1) {
|
||||
while ((ch = getopt(argc, argv, "cf:t:uv")) != -1) {
|
||||
switch (ch) {
|
||||
case 'c':
|
||||
action = VND_CONFIG;
|
||||
break;
|
||||
case 'f':
|
||||
if (setdisktab(optarg) == -1)
|
||||
usage();
|
||||
break;
|
||||
case 't':
|
||||
tabname = optarg;
|
||||
break;
|
||||
|
@ -284,7 +288,7 @@ usage()
|
|||
{
|
||||
|
||||
(void)fprintf(stderr, "%s%s",
|
||||
"usage: vnconfig [-c] [-t typename] [-v] special-file"
|
||||
"usage: vnconfig [-c] [-f disktab] [-t typename] [-v] special-file"
|
||||
" regular-file [geomspec]\n",
|
||||
" vnconfig -u [-v] special-file\n");
|
||||
exit(1);
|
||||
|
|
Loading…
Reference in New Issue