xref: /csrg-svn/sys/dev/vnioctl.h (revision 41480)
1*41480Smckusick /*
2*41480Smckusick  * Copyright (c) 1988 University of Utah.
3*41480Smckusick  * Copyright (c) 1990 The Regents of the University of California.
4*41480Smckusick  * All rights reserved.
5*41480Smckusick  *
6*41480Smckusick  * This code is derived from software contributed to Berkeley by
7*41480Smckusick  * the Systems Programming Group of the University of Utah Computer
8*41480Smckusick  * Science Department.
9*41480Smckusick  *
10*41480Smckusick  * %sccs.include.redist.c%
11*41480Smckusick  *
12*41480Smckusick  * from: Utah $Hdr: fdioctl.h 1.1 89/11/20$
13*41480Smckusick  *
14*41480Smckusick  *	@(#)vnioctl.h	7.1 (Berkeley) 05/08/90
15*41480Smckusick  */
16*41480Smckusick 
17*41480Smckusick /*
18*41480Smckusick  * Ioctl definitions for file (vnode) disk pseudo-device.
19*41480Smckusick  */
20*41480Smckusick 
21*41480Smckusick #define FDISKFILE	"/etc/fdisks"	/* default config file */
22*41480Smckusick 
23*41480Smckusick struct fd_ioctl {
24*41480Smckusick 	char	*fd_file;	/* pathname of file to mount */
25*41480Smckusick 	int	fd_size;	/* (returned) size of disk */
26*41480Smckusick };
27*41480Smckusick 
28*41480Smckusick /*
29*41480Smckusick  * Before you can use a unit, it must be configured with FDIOCSET.
30*41480Smckusick  * The configuration persists across opens and closes of the device;
31*41480Smckusick  * an FDIOCCLR must be used to reset a configuration.  An attempt to
32*41480Smckusick  * FDIOCSET an already active unit will return EBUSY.
33*41480Smckusick  */
34*41480Smckusick #define FDIOCSET	_IOWR('F', 0, struct fd_ioctl)	/* enable disk */
35*41480Smckusick #define FDIOCCLR	_IOW('F', 1, struct fd_ioctl)	/* disable disk */
36