diff options
author | Niels de Vos <ndevos@redhat.com> | 2015-12-07 16:24:15 +0000 |
---|---|---|
committer | Niels de Vos <ndevos@redhat.com> | 2016-05-11 11:23:00 -0700 |
commit | b2222c1e13d3bff17fa04b8f9b4870cefd457fe2 (patch) | |
tree | a2f5b7fca493f9c71a5906ec4e3763ebbd9e77bd /xlators/features/upcall/src/upcall-internal.c | |
parent | 163568951746f7a7af181bb8c592404581eced78 (diff) |
upcall: Add support to invalidate xattrs
When SElinux is used, clients should get a notification that the
extended attributes have been updated. Other components (like md-cache)
will be able to use this too.
A big part of the implementation comes from Poornima through the first
version of http://review.gluster.org/12996.
Also moving the flags from upcall-cache-invalidation.h to the main
libglusterfs upcall-utils.h file, so that other places can easily use
them in future.
Change-Id: I525345bed8f22d029524ff19ccaf726a2c905454
BUG: 1211863
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Signed-off-by: Poornima G <pgurusid@redhat.com>
Reviewed-on: http://review.gluster.org/12995
Reviewed-by: soumya k <skoduri@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.com>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
Diffstat (limited to 'xlators/features/upcall/src/upcall-internal.c')
-rw-r--r-- | xlators/features/upcall/src/upcall-internal.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/xlators/features/upcall/src/upcall-internal.c b/xlators/features/upcall/src/upcall-internal.c index 81199eb074c..f9005df2ed7 100644 --- a/xlators/features/upcall/src/upcall-internal.c +++ b/xlators/features/upcall/src/upcall-internal.c @@ -31,7 +31,6 @@ /* * Check if any of the upcall options are enabled: * - cache_invalidation - * - XXX: lease_lk */ gf_boolean_t is_upcall_enabled(xlator_t *this) { @@ -50,25 +49,6 @@ is_upcall_enabled(xlator_t *this) { } /* - * Check if any of cache_invalidation is enabled - */ -gf_boolean_t -is_cache_invalidation_enabled(xlator_t *this) { - upcall_private_t *priv = NULL; - gf_boolean_t is_enabled = _gf_false; - - if (this->private) { - priv = (upcall_private_t *)this->private; - - if (priv->cache_invalidation_enabled) { - is_enabled = _gf_true; - } - } - - return is_enabled; -} - -/* * Get the cache_invalidation_timeout */ int32_t @@ -476,7 +456,7 @@ upcall_cache_invalidate (call_frame_t *frame, xlator_t *this, client_t *client, upcall_inode_ctx_t *up_inode_ctx = NULL; gf_boolean_t found = _gf_false; - if (!is_cache_invalidation_enabled(this)) + if (!is_upcall_enabled(this)) return; /* server-side generated fops like quota/marker will not have any |