]> git.proxmox.com Git - mirror_zfs-debian.git/blame - lib/libspl/include/sys/param.h
Imported Upstream version 0.6.4.2
[mirror_zfs-debian.git] / lib / libspl / include / sys / param.h
CommitLineData
a26baf28
BB
1/*
2 * CDDL HEADER START
3 *
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
7 * with the License.
8 *
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.
13 *
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]
19 *
20 * CDDL HEADER END
21 */
22/*
23 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
25 */
26
27#ifndef _LIBSPL_SYS_PARAM_H
a08ee875 28#define _LIBSPL_SYS_PARAM_H
a26baf28
BB
29
30#include_next <sys/param.h>
31#include <unistd.h>
32
33/*
34 * File system parameters and macros.
35 *
36 * The file system is made out of blocks of at most MAXBSIZE units,
37 * with smaller units (fragments) only in the last direct block.
38 * MAXBSIZE primarily determines the size of buffers in the buffer
39 * pool. It may be made larger without any effect on existing
40 * file systems; however making it smaller make make some file
41 * systems unmountable.
42 *
43 * Note that the blocked devices are assumed to have DEV_BSIZE
44 * "sectors" and that fragments must be some multiple of this size.
45 */
a08ee875
LG
46#define MAXBSIZE 8192
47#define DEV_BSIZE 512
48#define DEV_BSHIFT 9 /* log2(DEV_BSIZE) */
a26baf28 49
a08ee875
LG
50#define MAXNAMELEN 256
51#define MAXOFFSET_T LLONG_MAX
a26baf28 52
a08ee875
LG
53#define UID_NOBODY 60001 /* user ID no body */
54#define GID_NOBODY UID_NOBODY
55#define UID_NOACCESS 60002 /* user ID no access */
a26baf28 56
a08ee875
LG
57#define MAXUID UINT32_MAX /* max user id */
58#define MAXPROJID MAXUID /* max project id */
a26baf28 59
ea04106b 60#ifndef PAGESIZE
a08ee875 61#define PAGESIZE (sysconf(_SC_PAGESIZE))
ea04106b 62#endif /* PAGESIZE */
a26baf28
BB
63
64#endif