diff options
Diffstat (limited to 'xlators')
-rw-r--r-- | xlators/features/upcall/src/upcall-internal.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/xlators/features/upcall/src/upcall-internal.c b/xlators/features/upcall/src/upcall-internal.c index 3b6186ea943..007a8f854bf 100644 --- a/xlators/features/upcall/src/upcall-internal.c +++ b/xlators/features/upcall/src/upcall-internal.c @@ -397,6 +397,7 @@ upcall_reaper_thread (void *data) upcall_inode_ctx_t *inode_ctx = NULL; upcall_inode_ctx_t *tmp = NULL; xlator_t *this = NULL; + time_t timeout = 0; this = (xlator_t *)data; GF_ASSERT (this); @@ -429,6 +430,10 @@ upcall_reaper_thread (void *data) } UNLOCK (&priv->inode_ctx_lk); } + + /* don't do a very busy loop */ + timeout = get_cache_invalidation_timeout (this); + sleep (timeout / 2); } return NULL; |