diff options
Diffstat (limited to 'xlators/features/marker/src/marker.h')
-rw-r--r-- | xlators/features/marker/src/marker.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/xlators/features/marker/src/marker.h b/xlators/features/marker/src/marker.h index eeb64a16a87..5602456ff5d 100644 --- a/xlators/features/marker/src/marker.h +++ b/xlators/features/marker/src/marker.h @@ -16,11 +16,15 @@ <http://www.gnu.org/licenses/>. */ +#ifndef _MARKER_H +#define _MARKER_H + #ifndef _CONFIG_H #define _CONFIG_H #include "config.h" #endif +#include "marker-quota.h" #include "xlator.h" #include "defaults.h" #include "uuid.h" @@ -31,11 +35,18 @@ #define VOLUME_UUID "volume-uuid" #define TIMESTAMP_FILE "timestamp-file" +enum { + GF_QUOTA=1, + GF_GSYNC=2 +}; + /*initialize the local variable*/ #define MARKER_INIT_LOCAL(_frame,_local) do { \ _frame->local = _local; \ _local->pid = _frame->root->pid; \ memset (&_local->loc, 0, sizeof (loc_t)); \ + _local->ref = 1; \ + LOCK_INIT (&_local->lock); \ _local->oplocal = NULL; \ } while (0) @@ -54,15 +65,28 @@ struct marker_local{ uint32_t timebuf[2]; pid_t pid; loc_t loc; + int32_t ref; + gf_lock_t lock; struct marker_local *oplocal; }; typedef struct marker_local marker_local_t; +struct marker_inode_ctx { + struct quota_inode_ctx *quota_ctx; +}; +typedef struct marker_inode_ctx marker_inode_ctx_t; + struct marker_conf{ + char feature_enabled; + char *size_key; + char *dirty_key; char *volume_uuid; uuid_t volume_uuid_bin; char *timestamp_file; char *marker_xattr; }; typedef struct marker_conf marker_conf_t; + +int32_t k; +#endif |