summaryrefslogtreecommitdiff
path: root/quota.h
diff options
context:
space:
mode:
authorPetr Písař <ppisar@redhat.com>2013-01-09 17:00:44 +0100
committerJan Kara <jack@suse.cz>2013-01-21 22:49:25 +0100
commit0ada9c13f9b8299ff607b66c37022ce2a3c4444b (patch)
tree9c52766219d2a636bb6d68a8ccca55f2ed36dbbf /quota.h
parent17e8b1a111d9d1c9a23ce91ab2e83df6c09b7e92 (diff)
Recognize units at block limits by setquota
This patch allows to specify suffixes at block limits on setquota command line. Binary units K, M, G, T are implemented. Numeric value without suffix is equivatent to kibibytes as before. This is complementary functionality to `quota -s'. Signed-off-by: Petr Písař <ppisar@redhat.com> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'quota.h')
-rw-r--r--quota.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/quota.h b/quota.h
index ac034d0..6787eab 100644
--- a/quota.h
+++ b/quota.h
@@ -2,9 +2,11 @@
#define GUARD_QUOTA_H
#include <sys/types.h>
+#include <stdint.h>
typedef u_int32_t qid_t; /* Type in which we store ids in memory */
typedef int64_t qsize_t; /* Type in which we store size limitations */
+#define QSIZE_MAX INT64_MAX /* Maximum value storable in qsize_t */
#define MAXQUOTAS 2
#define USRQUOTA 0 /* element used for user quotas */