/* * Copyright (c) 1982, 1986 Regents of the University of California. * All rights reserved. * * This code is derived from software contributed to Berkeley by * Robert Elz at The University of Melbourne. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * 3. Neither the name of the University nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ #ifndef _UAPI_LINUX_QUOTA_ #define _UAPI_LINUX_QUOTA_ #include <linux/types.h> #define __DQUOT_VERSION__ … #define MAXQUOTAS … #define USRQUOTA … #define GRPQUOTA … #define PRJQUOTA … /* * Definitions for the default names of the quotas files. */ #define INITQFNAMES … /* * Command definitions for the 'quotactl' system call. * The commands are broken into a main command defined below * and a subcommand that is used to convey the type of * quota that is being manipulated (see above). */ #define SUBCMDMASK … #define SUBCMDSHIFT … #define QCMD(cmd, type) … #define Q_SYNC … #define Q_QUOTAON … #define Q_QUOTAOFF … #define Q_GETFMT … #define Q_GETINFO … #define Q_SETINFO … #define Q_GETQUOTA … #define Q_SETQUOTA … #define Q_GETNEXTQUOTA … /* Quota format type IDs */ #define QFMT_VFS_OLD … #define QFMT_VFS_V0 … #define QFMT_OCFS2 … #define QFMT_VFS_V1 … #define QFMT_SHMEM … /* Size of block in which space limits are passed through the quota * interface */ #define QIF_DQBLKSIZE_BITS … #define QIF_DQBLKSIZE … /* * Quota structure used for communication with userspace via quotactl * Following flags are used to specify which fields are valid */ enum { … }; #define QIF_BLIMITS … #define QIF_SPACE … #define QIF_ILIMITS … #define QIF_INODES … #define QIF_BTIME … #define QIF_ITIME … #define QIF_LIMITS … #define QIF_USAGE … #define QIF_TIMES … #define QIF_ALL … struct if_dqblk { … }; struct if_nextdqblk { … }; /* * Structure used for setting quota information about file via quotactl * Following flags are used to specify which fields are valid */ #define IIF_BGRACE … #define IIF_IGRACE … #define IIF_FLAGS … #define IIF_ALL … enum { … }; /* Root squash enabled (for v1 quota format) */ #define DQF_ROOT_SQUASH … /* Quota stored in a system file */ #define DQF_SYS_FILE … struct if_dqinfo { … }; /* * Definitions for quota netlink interface */ #define QUOTA_NL_NOWARN … #define QUOTA_NL_IHARDWARN … #define QUOTA_NL_ISOFTLONGWARN … #define QUOTA_NL_ISOFTWARN … #define QUOTA_NL_BHARDWARN … #define QUOTA_NL_BSOFTLONGWARN … #define QUOTA_NL_BSOFTWARN … #define QUOTA_NL_IHARDBELOW … #define QUOTA_NL_ISOFTBELOW … #define QUOTA_NL_BHARDBELOW … #define QUOTA_NL_BSOFTBELOW … enum { … }; #define QUOTA_NL_C_MAX … enum { … }; #define QUOTA_NL_A_MAX … #endif /* _UAPI_LINUX_QUOTA_ */