xref: /utopia/UTPA2-700.0.x/projects/tools/lint/mips-linux-gnu_include/fstab.h (revision 53ee8cc121a030b8d368113ac3e966b4705770ef)
1*53ee8cc1Swenshuai.xi /*
2*53ee8cc1Swenshuai.xi  * Copyright (c) 1980, 1993
3*53ee8cc1Swenshuai.xi  *	The Regents of the University of California.  All rights reserved.
4*53ee8cc1Swenshuai.xi  *
5*53ee8cc1Swenshuai.xi  * Redistribution and use in source and binary forms, with or without
6*53ee8cc1Swenshuai.xi  * modification, are permitted provided that the following conditions
7*53ee8cc1Swenshuai.xi  * are met:
8*53ee8cc1Swenshuai.xi  * 1. Redistributions of source code must retain the above copyright
9*53ee8cc1Swenshuai.xi  *    notice, this list of conditions and the following disclaimer.
10*53ee8cc1Swenshuai.xi  * 2. Redistributions in binary form must reproduce the above copyright
11*53ee8cc1Swenshuai.xi  *    notice, this list of conditions and the following disclaimer in the
12*53ee8cc1Swenshuai.xi  *    documentation and/or other materials provided with the distribution.
13*53ee8cc1Swenshuai.xi  * 4. Neither the name of the University nor the names of its contributors
14*53ee8cc1Swenshuai.xi  *    may be used to endorse or promote products derived from this software
15*53ee8cc1Swenshuai.xi  *    without specific prior written permission.
16*53ee8cc1Swenshuai.xi  *
17*53ee8cc1Swenshuai.xi  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
18*53ee8cc1Swenshuai.xi  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19*53ee8cc1Swenshuai.xi  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20*53ee8cc1Swenshuai.xi  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
21*53ee8cc1Swenshuai.xi  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22*53ee8cc1Swenshuai.xi  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23*53ee8cc1Swenshuai.xi  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24*53ee8cc1Swenshuai.xi  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25*53ee8cc1Swenshuai.xi  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26*53ee8cc1Swenshuai.xi  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27*53ee8cc1Swenshuai.xi  * SUCH DAMAGE.
28*53ee8cc1Swenshuai.xi  *
29*53ee8cc1Swenshuai.xi  *	@(#)fstab.h	8.1 (Berkeley) 6/2/93
30*53ee8cc1Swenshuai.xi  */
31*53ee8cc1Swenshuai.xi 
32*53ee8cc1Swenshuai.xi #ifndef _FSTAB_H
33*53ee8cc1Swenshuai.xi #define _FSTAB_H	1
34*53ee8cc1Swenshuai.xi 
35*53ee8cc1Swenshuai.xi #include <features.h>
36*53ee8cc1Swenshuai.xi 
37*53ee8cc1Swenshuai.xi /*
38*53ee8cc1Swenshuai.xi  * File system table, see fstab(5).
39*53ee8cc1Swenshuai.xi  *
40*53ee8cc1Swenshuai.xi  * Used by dump, mount, umount, swapon, fsck, df, ...
41*53ee8cc1Swenshuai.xi  *
42*53ee8cc1Swenshuai.xi  * For ufs fs_spec field is the block special name.  Programs that want to
43*53ee8cc1Swenshuai.xi  * use the character special name must create that name by prepending a 'r'
44*53ee8cc1Swenshuai.xi  * after the right most slash.  Quota files are always named "quotas", so
45*53ee8cc1Swenshuai.xi  * if type is "rq", then use concatenation of fs_file and "quotas" to locate
46*53ee8cc1Swenshuai.xi  * quota file.
47*53ee8cc1Swenshuai.xi  */
48*53ee8cc1Swenshuai.xi #define	_PATH_FSTAB	"/etc/fstab"
49*53ee8cc1Swenshuai.xi #define	FSTAB		"/etc/fstab"	/* deprecated */
50*53ee8cc1Swenshuai.xi 
51*53ee8cc1Swenshuai.xi #define	FSTAB_RW	"rw"		/* read/write device */
52*53ee8cc1Swenshuai.xi #define	FSTAB_RQ	"rq"		/* read/write with quotas */
53*53ee8cc1Swenshuai.xi #define	FSTAB_RO	"ro"		/* read-only device */
54*53ee8cc1Swenshuai.xi #define	FSTAB_SW	"sw"		/* swap device */
55*53ee8cc1Swenshuai.xi #define	FSTAB_XX	"xx"		/* ignore totally */
56*53ee8cc1Swenshuai.xi 
57*53ee8cc1Swenshuai.xi struct fstab
58*53ee8cc1Swenshuai.xi   {
59*53ee8cc1Swenshuai.xi     char *fs_spec;			/* block special device name */
60*53ee8cc1Swenshuai.xi     char *fs_file;			/* file system path prefix */
61*53ee8cc1Swenshuai.xi     char *fs_vfstype;			/* File system type, ufs, nfs */
62*53ee8cc1Swenshuai.xi     char *fs_mntops;			/* Mount options ala -o */
63*53ee8cc1Swenshuai.xi     const char *fs_type;		/* FSTAB_* from fs_mntops */
64*53ee8cc1Swenshuai.xi     int	fs_freq;			/* dump frequency, in days */
65*53ee8cc1Swenshuai.xi     int	fs_passno;			/* pass number on parallel dump */
66*53ee8cc1Swenshuai.xi   };
67*53ee8cc1Swenshuai.xi 
68*53ee8cc1Swenshuai.xi 
69*53ee8cc1Swenshuai.xi __BEGIN_DECLS
70*53ee8cc1Swenshuai.xi 
71*53ee8cc1Swenshuai.xi extern struct fstab *getfsent (void) __THROW;
72*53ee8cc1Swenshuai.xi extern struct fstab *getfsspec (__const char *__name) __THROW;
73*53ee8cc1Swenshuai.xi extern struct fstab *getfsfile (__const char *__name) __THROW;
74*53ee8cc1Swenshuai.xi extern int setfsent (void) __THROW;
75*53ee8cc1Swenshuai.xi extern void endfsent (void) __THROW;
76*53ee8cc1Swenshuai.xi 
77*53ee8cc1Swenshuai.xi __END_DECLS
78*53ee8cc1Swenshuai.xi 
79*53ee8cc1Swenshuai.xi #endif /* fstab.h */
80