softlink
[sysadmin-cn.git] / quotaio.h
1 /*
2  *
3  *      Header of IO operations for quota utilities
4  *
5  */
6
7 #ifndef _QUOTAIO_H
8 #define _QUOTAIO_H
9
10 #include <limits.h>
11 #include <sys/types.h>
12 #include <sys/stat.h>
13
14 #include "quota.h"
15
16 /* Latest known versions */
17 #define INITKNOWNVERSIONS {\
18         0,\
19         0\
20 }
21
22 #define QUOTAFORMATS 4
23
24 #define INITQFBASENAMES {\
25         "quota",\
26         "aquota",\
27         "",\
28         ""\
29 }
30
31 #define INITQFMTNAMES {\
32         "vfsold",\
33         "vfsv0",\
34         "rpc",\
35         "xfs"\
36 }
37
38 /* Values for format handling */
39 #define QF_UNKNOWN -3           /* Format cannot be detected from filename */
40 #define QF_TOONEW -2            /* Quota format is too new to handle */
41 #define QF_ERROR -1             /* There was error while detecting format (maybe unknown format...) */
42 #define QF_VFSOLD 0             /* Old quota format */
43 #define QF_VFSV0 1              /* New quota format - version 0 */
44 #define QF_RPC 2                /* RPC should be used on given filesystem */
45 #define QF_XFS 3                /* XFS quota format */
46
47 /*
48  * Definitions for disk quotas imposed on the average user
49  * (big brother finally hits Linux).
50  *
51  * The following constants define the default amount of time given a user
52  * before the soft limits are treated as hard limits (usually resulting
53  * in an allocation failure). The timer is started when the user crosses
54  * their soft limit, it is reset when they go below their soft limit.
55  */
56 #define MAX_IQ_TIME  604800     /* (7*24*60*60) 1 week */
57 #define MAX_DQ_TIME  604800     /* (7*24*60*60) 1 week */
58
59 #endif /* _QUOTAIO_H */