130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Copyright (c) 1995-2001,2004 Silicon Graphics, Inc.  All Rights Reserved.
330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng *
430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * This program is free software; you can redistribute it and/or
530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * modify it under the terms of the GNU Lesser General Public License
630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * as published by the Free Software Foundation.
730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng *
830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * This program is distributed in the hope that it will be useful,
930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * but WITHOUT ANY WARRANTY; without even the implied warranty of
1030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * GNU Lesser General Public License for more details.
1230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng *
1330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * You should have received a copy of the GNU Lesset General Public License
1430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * along with this program; if not, write to the Free Software Foundation,
1530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
1630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
1730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#ifndef _LINUX_DQBLK_XFS_H
1830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define _LINUX_DQBLK_XFS_H
1930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
2030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#include <linux/types.h>
2130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
2230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
2330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Disk quota - quotactl(2) commands for the XFS Quota Manager (XQM).
2430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
2530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
2630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_CMD(x)	(('X'<<8)+(x))	/* note: forms first QCMD argument */
2730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_COMMAND(x)	(((x) & (0xff<<8)) == ('X'<<8))	/* test if for XFS */
2830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
2930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_USRQUOTA	0	/* system call user quota type */
3030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_GRPQUOTA	1	/* system call group quota type */
3130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_PRJQUOTA	2	/* system call project quota type */
3230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define XQM_MAXQUOTAS	3
3330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
3430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XQUOTAON	XQM_CMD(1)	/* enable accounting/enforcement */
3530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XQUOTAOFF	XQM_CMD(2)	/* disable accounting/enforcement */
3630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XGETQUOTA	XQM_CMD(3)	/* get disk limits and usage */
3730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XSETQLIM	XQM_CMD(4)	/* set disk limits */
3830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XGETQSTAT	XQM_CMD(5)	/* get quota subsystem status */
3930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XQUOTARM	XQM_CMD(6)	/* free disk space used by dquots */
4030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define Q_XQUOTASYNC	XQM_CMD(7)	/* delalloc flush, updates dquots */
41e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl#define Q_XGETQSTATV	XQM_CMD(8)	/* newer version of get quota */
4230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
4330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
4430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * fs_disk_quota structure:
4530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng *
4630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * This contains the current quota information regarding a user/proj/group.
4730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * It is 64-bit aligned, and all the blk units are in BBs (Basic Blocks) of
4830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * 512 bytes.
4930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
5030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQUOT_VERSION	1	/* fs_disk_quota.d_version */
5130692c65c4174412c90e79489e98ab85c1a7412fBen Chengtypedef struct fs_disk_quota {
5230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s8		d_version;	/* version of this structure */
5330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s8		d_flags;	/* FS_{USER,PROJ,GROUP}_QUOTA */
5430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16		d_fieldmask;	/* field specifier */
5530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u32		d_id;		/* user, project, or group ID */
5630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_blk_hardlimit;/* absolute limit on disk blks */
5730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_blk_softlimit;/* preferred limit on disk blks */
5830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_ino_hardlimit;/* maximum # allocated inodes */
5930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_ino_softlimit;/* preferred inode limit */
6030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_bcount;	/* # disk blocks owned by the user */
6130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_icount;	/* # inodes owned by the user */
6230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		d_itimer;	/* zero if within inode limits */
6330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng					/* if not, we refuse service */
6430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		d_btimer;	/* similar to above; for disk blocks */
6530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16	  	d_iwarns;       /* # warnings issued wrt num inodes */
6630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16	  	d_bwarns;       /* # warnings issued wrt disk blocks */
6730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		d_padding2;	/* padding2 - for future use */
6830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_rtb_hardlimit;/* absolute limit on realtime blks */
6930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_rtb_softlimit;/* preferred limit on RT disk blks */
7030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		d_rtbcount;	/* # realtime blocks owned */
7130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		d_rtbtimer;	/* similar to above; for RT disk blks */
7230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16	  	d_rtbwarns;     /* # warnings issued wrt RT disk blks */
7330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s16		d_padding3;	/* padding3 - for future use */
7430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	char		d_padding4[8];	/* yet more padding */
7530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng} fs_disk_quota_t;
7630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
7730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
7830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * These fields are sent to Q_XSETQLIM to specify fields that need to change.
7930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
8030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_ISOFT	(1<<0)
8130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_IHARD	(1<<1)
8230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_BSOFT	(1<<2)
8330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_BHARD 	(1<<3)
8430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_RTBSOFT	(1<<4)
8530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_RTBHARD	(1<<5)
8630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_LIMIT_MASK	(FS_DQ_ISOFT | FS_DQ_IHARD | FS_DQ_BSOFT | \
8730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng				 FS_DQ_BHARD | FS_DQ_RTBSOFT | FS_DQ_RTBHARD)
8830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
8930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * These timers can only be set in super user's dquot. For others, timers are
9030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * automatically started and stopped. Superusers timer values set the limits
9130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * for the rest.  In case these values are zero, the DQ_{F,B}TIMELIMIT values
9230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * defined below are used.
9330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * These values also apply only to the d_fieldmask field for Q_XSETQLIM.
9430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
9530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_BTIMER	(1<<6)
9630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_ITIMER	(1<<7)
9730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_RTBTIMER 	(1<<8)
9830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_TIMER_MASK	(FS_DQ_BTIMER | FS_DQ_ITIMER | FS_DQ_RTBTIMER)
9930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
10030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
10130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Warning counts are set in both super user's dquot and others. For others,
10230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * warnings are set/cleared by the administrators (or automatically by going
10330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * below the soft limit).  Superusers warning values set the warning limits
10430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * for the rest.  In case these values are zero, the DQ_{F,B}WARNLIMIT values
10530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * defined below are used.
10630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * These values also apply only to the d_fieldmask field for Q_XSETQLIM.
10730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
10830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_BWARNS	(1<<9)
10930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_IWARNS	(1<<10)
11030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_RTBWARNS	(1<<11)
11130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_WARNS_MASK	(FS_DQ_BWARNS | FS_DQ_IWARNS | FS_DQ_RTBWARNS)
11230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
11330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
11430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Accounting values.  These can only be set for filesystem with
11530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * non-transactional quotas that require quotacheck(8) in userspace.
11630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
11730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_BCOUNT		(1<<12)
11830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_ICOUNT		(1<<13)
11930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_RTBCOUNT		(1<<14)
12030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_DQ_ACCT_MASK		(FS_DQ_BCOUNT | FS_DQ_ICOUNT | FS_DQ_RTBCOUNT)
12130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
12230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
12330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Various flags related to quotactl(2).
12430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
12530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_UDQ_ACCT	(1<<0)  /* user quota accounting */
12630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_UDQ_ENFD	(1<<1)  /* user quota limits enforcement */
12730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_GDQ_ACCT	(1<<2)  /* group quota accounting */
12830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_GDQ_ENFD	(1<<3)  /* group quota limits enforcement */
12930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_PDQ_ACCT	(1<<4)  /* project quota accounting */
13030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QUOTA_PDQ_ENFD	(1<<5)  /* project quota limits enforcement */
13130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
13230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_USER_QUOTA		(1<<0)	/* user quota type */
13330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_PROJ_QUOTA		(1<<1)	/* project quota type */
13430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_GROUP_QUOTA		(1<<2)	/* group quota type */
13530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
13630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
13730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * fs_quota_stat is the struct returned in Q_XGETQSTAT for a given file system.
13830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Provides a centralized way to get meta information about the quota subsystem.
13930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * eg. space taken up for user and group quotas, number of dquots currently
14030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * incore.
14130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
14230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#define FS_QSTAT_VERSION	1	/* fs_quota_stat.qs_version */
14330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
14430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng/*
14530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng * Some basic information about 'quota files'.
14630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng */
14730692c65c4174412c90e79489e98ab85c1a7412fBen Chengtypedef struct fs_qfilestat {
14830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		qfs_ino;	/* inode number */
14930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u64		qfs_nblks;	/* number of BBs 512-byte-blks */
15030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u32		qfs_nextents;	/* number of extents */
15130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng} fs_qfilestat_t;
15230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
15330692c65c4174412c90e79489e98ab85c1a7412fBen Chengtypedef struct fs_quota_stat {
15430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s8		qs_version;	/* version number for future changes */
15530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16		qs_flags;	/* FS_QUOTA_{U,P,G}DQ_{ACCT,ENFD} */
15630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s8		qs_pad;		/* unused */
15730692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	fs_qfilestat_t	qs_uquota;	/* user quota storage information */
15830692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	fs_qfilestat_t	qs_gquota;	/* group quota storage information */
15930692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u32		qs_incoredqs;	/* number of dquots incore */
16030692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		qs_btimelimit;  /* limit for blks timer */
16130692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		qs_itimelimit;  /* limit for inodes timer */
16230692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__s32		qs_rtbtimelimit;/* limit for rt blks timer */
16330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16		qs_bwarnlimit;	/* limit for num warnings */
16430692c65c4174412c90e79489e98ab85c1a7412fBen Cheng	__u16		qs_iwarnlimit;	/* limit for num warnings */
16530692c65c4174412c90e79489e98ab85c1a7412fBen Cheng} fs_quota_stat_t;
16630692c65c4174412c90e79489e98ab85c1a7412fBen Cheng
167e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl/*
168e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * fs_quota_statv is used by Q_XGETQSTATV for a given file system. It provides
169e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * a centralized way to get meta information about the quota subsystem. eg.
170e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * space taken up for user, group, and project quotas, number of dquots
171e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * currently incore.
172e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl *
173e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * This version has proper versioning support with appropriate padding for
174e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * future expansions, and ability to expand for future without creating any
175e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * backward compatibility issues.
176e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl *
177e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * Q_XGETQSTATV uses the passed in value of the requested version via
178e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * fs_quota_statv.qs_version to determine the return data layout of
179e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * fs_quota_statv.  The kernel will fill the data fields relevant to that
180e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * version.
181e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl *
182e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * If kernel does not support user space caller specified version, EINVAL will
183e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * be returned. User space caller can then reduce the version number and retry
184e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * the same command.
185e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl */
186e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl#define FS_QSTATV_VERSION1	1	/* fs_quota_statv.qs_version */
187e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl/*
188e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl * Some basic information about 'quota files' for Q_XGETQSTATV command
189e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl */
190e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heylstruct fs_qfilestatv {
191e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u64		qfs_ino;	/* inode number */
192e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u64		qfs_nblks;	/* number of BBs 512-byte-blks */
193e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u32		qfs_nextents;	/* number of extents */
194e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u32		qfs_pad;	/* pad for 8-byte alignment */
195e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl};
196e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl
197e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heylstruct fs_quota_statv {
198e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__s8			qs_version;	/* version for future changes */
199e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u8			qs_pad1;	/* pad for 16bit alignment */
200e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u16			qs_flags;	/* FS_QUOTA_.* flags */
201e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u32			qs_incoredqs;	/* number of dquots incore */
202e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	struct fs_qfilestatv	qs_uquota;	/* user quota information */
203e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	struct fs_qfilestatv	qs_gquota;	/* group quota information */
204e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	struct fs_qfilestatv	qs_pquota;	/* project quota information */
205e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__s32			qs_btimelimit;  /* limit for blks timer */
206e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__s32			qs_itimelimit;  /* limit for inodes timer */
207e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__s32			qs_rtbtimelimit;/* limit for rt blks timer */
208e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u16			qs_bwarnlimit;	/* limit for num warnings */
209e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u16			qs_iwarnlimit;	/* limit for num warnings */
210e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl	__u64			qs_pad2[8];	/* for future proofing */
211e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl};
212e87eaf040ab639e94ed0a58ff0eac68d1d38fb0aEd Heyl
21330692c65c4174412c90e79489e98ab85c1a7412fBen Cheng#endif	/* _LINUX_DQBLK_XFS_H */
214