void upcall_cache_flush_one(struct upcall_cache *cache, __u64 key, void *args);
struct upcall_cache *upcall_cache_init(const char *name, const char *upcall,
- int hashsz, struct upcall_cache_ops *ops);
+ int hashsz, time64_t entry_expire,
+ time64_t acquire_expire,
+ struct upcall_cache_ops *ops);
void upcall_cache_cleanup(struct upcall_cache *cache);
/** @} ucache */
m->mdt_identity_cache = upcall_cache_init(mdt_obd_name(m),
identity_upcall,
UC_IDCACHE_HASH_SIZE,
+ 1200, /* entry expire: 20 mn */
+ 30, /* acquire expire: 30 s */
&mdt_identity_upcall_cache_ops);
if (IS_ERR(m->mdt_identity_cache)) {
rc = PTR_ERR(m->mdt_identity_cache);
EXPORT_SYMBOL(upcall_cache_flush_one);
struct upcall_cache *upcall_cache_init(const char *name, const char *upcall,
- int hashsz, struct upcall_cache_ops *ops)
+ int hashsz, time64_t entry_expire,
+ time64_t acquire_expire,
+ struct upcall_cache_ops *ops)
{
struct upcall_cache *cache;
int i;
strlcpy(cache->uc_name, name, sizeof(cache->uc_name));
/* upcall pathname proc tunable */
strlcpy(cache->uc_upcall, upcall, sizeof(cache->uc_upcall));
- cache->uc_entry_expire = 20 * 60;
- cache->uc_acquire_expire = 30;
+ cache->uc_entry_expire = entry_expire;
+ cache->uc_acquire_expire = acquire_expire;
cache->uc_ops = ops;
RETURN(cache);