4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
22 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
23 /* All Rights Reserved */
27 * Copyright 2014 Garrett D'Amore <garrett@damore.org>
29 * Copyright (c) 1996, 1999 by Sun Microsystems, Inc.
30 * All rights reserved.
41 * Flag bits passed to mount(2).
43 #define MS_RDONLY 0x0001 /* Read-only */
44 #define MS_FSS 0x0002 /* Old (4-argument) mount (compatibility) */
45 #define MS_DATA 0x0004 /* 6-argument mount */
46 #define MS_NOSUID 0x0010 /* Setuid programs disallowed */
47 #define MS_REMOUNT 0x0020 /* Remount */
48 #define MS_NOTRUNC 0x0040 /* Return ENAMETOOLONG for long filenames */
49 #define MS_OVERLAY 0x0080 /* Allow overlay mounts */
50 #define MS_OPTIONSTR 0x0100 /* Data is a an in/out option string */
51 #define MS_FORCE 0x0400 /* Forced unmount */
52 #define MS_NOMNTTAB 0x0800 /* Don't show mount in mnttab */
54 * Additional flag bits that domount() is prepared to interpret, but that
55 * can't be passed through mount(2).
57 #define MS_SYSSPACE 0x0008 /* Mounta already in kernel space */
58 #define MS_NOSPLICE 0x1000 /* Don't splice fs instance into name space */
59 #define MS_NOCHECK 0x2000 /* Clustering: suppress mount busy checks */
61 * Mask to sift out flag bits allowable from mount(2).
64 (MS_RDONLY|MS_FSS|MS_DATA|MS_NOSUID|MS_REMOUNT|MS_NOTRUNC|MS_OVERLAY|\
65 MS_OPTIONSTR|MS_NOMNTTAB)
68 * Mask to sift out flag bits allowable from umount2(2).
71 #define MS_UMOUNT_MASK (MS_FORCE)
74 * Maximum option string length accepted or returned by mount(2).
76 #define MAX_MNTOPT_STR 1024 /* max length of mount options string */
79 int mount(const char *, const char *, int, ...);
80 int umount(const char *);
81 int umount2(const char *, int);
88 #endif /* _SYS_MOUNT_H */