summaryrefslogtreecommitdiff
path: root/quotaio.h
diff options
context:
space:
mode:
authorjkar8572 <jkar8572>2001-09-27 21:34:57 +0000
committerjkar8572 <jkar8572>2001-09-27 21:34:57 +0000
commit1f1b463eb250b98954c96837d880cc0e07e109aa (patch)
treefddf4986a37d15d5640a3115b2aac4fd4611a090 /quotaio.h
parent6cac7d8ee94d9262117e27df014a8b76ff889bde (diff)
downloadlinuxquota-1f1b463eb250b98954c96837d880cc0e07e109aa.tar.gz
Implemented setting only limits by commit_dquot() so edquota & setquota can operate
safe on live filesystem.
Diffstat (limited to 'quotaio.h')
-rw-r--r--quotaio.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/quotaio.h b/quotaio.h
index e6bee75..22c6d8a 100644
--- a/quotaio.h
+++ b/quotaio.h
@@ -128,6 +128,11 @@ struct dquot {
struct util_dqblk dq_dqb; /* Parsed data of dquot */
};
+/* Flags for commit function (have effect only when quota in kernel is turned on) */
+#define COMMIT_USAGE 1
+#define COMMIT_LIMITS 2
+#define COMMIT_ALL (COMMIT_USAGE | COMMIT_LIMITS)
+
/* Structure of quotafile operations */
struct quotafile_ops {
int (*init_io) (struct quota_handle * h); /* Open quotafile */
@@ -135,7 +140,7 @@ struct quotafile_ops {
int (*end_io) (struct quota_handle * h); /* Write all changes and close quotafile */
int (*write_info) (struct quota_handle * h); /* Write info about quotafile */
struct dquot *(*read_dquot) (struct quota_handle * h, qid_t id); /* Read dquot into memory */
- int (*commit_dquot) (struct dquot * dquot); /* Write given dquot to disk */
+ int (*commit_dquot) (struct dquot * dquot, int flag); /* Write given dquot to disk */
int (*scan_dquots) (struct quota_handle * h, int (*process_dquot) (struct dquot * dquot, char * dqname)); /* Scan quotafile and call callback on every structure */
int (*report) (struct quota_handle * h, int verbose); /* Function called after 'repquota' to print format specific file information */
};