mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-10-25 18:40:18 -04:00
Allow setting of passthrough max-stack-depth
This commit is contained in:
parent
0f24bb29ac
commit
f29df7b0cb
3 changed files with 19 additions and 2 deletions
|
|
@ -861,11 +861,25 @@ fuse_syslog_fuse_init_out(const struct fuse_init_out *arg_)
|
|||
output = fmt::format("fuse_init_out:"
|
||||
" major={};"
|
||||
" minor={};"
|
||||
" max_readahead={};"
|
||||
" max_background={};"
|
||||
" congestion_threshold={};"
|
||||
" max_write={};"
|
||||
" time_gran={};"
|
||||
" max_pages={};"
|
||||
" map_alignment={};"
|
||||
" max_stack_depth={};"
|
||||
" flags=(",
|
||||
arg_->major,
|
||||
arg_->minor,
|
||||
arg_->max_pages);
|
||||
arg_->max_readahead,
|
||||
arg_->max_background,
|
||||
arg_->congestion_threshold,
|
||||
arg_->max_write,
|
||||
arg_->time_gran,
|
||||
arg_->max_pages,
|
||||
arg_->map_alignment,
|
||||
arg_->max_stack_depth);
|
||||
|
||||
for(uint64_t i = 0; i < (sizeof(flags)*8); i++)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ struct fuse_notify_req
|
|||
|
||||
struct fuse_ll
|
||||
{
|
||||
unsigned passthrough_max_stack_depth;
|
||||
int debug;
|
||||
int no_remote_posix_lock;
|
||||
int no_remote_flock;
|
||||
|
|
|
|||
|
|
@ -1288,7 +1288,7 @@ do_init(fuse_req_t req,
|
|||
if(f->conn.want & FUSE_CAP_PASSTHROUGH)
|
||||
{
|
||||
outargflags |= FUSE_PASSTHROUGH;
|
||||
outarg.max_stack_depth = 2;
|
||||
outarg.max_stack_depth = f->passthrough_max_stack_depth;
|
||||
}
|
||||
|
||||
if(inargflags & FUSE_INIT_EXT)
|
||||
|
|
@ -1810,6 +1810,7 @@ static const struct fuse_opt fuse_ll_opts[] =
|
|||
{ "no_remote_lock", offsetof(struct fuse_ll, no_remote_flock), 1},
|
||||
{ "no_remote_flock", offsetof(struct fuse_ll, no_remote_flock), 1},
|
||||
{ "no_remote_posix_lock", offsetof(struct fuse_ll, no_remote_posix_lock), 1},
|
||||
{ "passthrough-max-stack-depth=%u", offsetof(struct fuse_ll, passthrough_max_stack_depth), 0},
|
||||
FUSE_OPT_KEY("max_read=", FUSE_OPT_KEY_DISCARD),
|
||||
FUSE_OPT_KEY("-h", KEY_HELP),
|
||||
FUSE_OPT_KEY("--help", KEY_HELP),
|
||||
|
|
@ -2072,6 +2073,7 @@ fuse_lowlevel_new_common(struct fuse_args *args,
|
|||
|
||||
f->conn.max_write = UINT_MAX;
|
||||
f->conn.max_readahead = UINT_MAX;
|
||||
f->passthrough_max_stack_depth = 2;
|
||||
list_init_nreq(&f->notify_list);
|
||||
f->notify_ctr = 1;
|
||||
mutex_init(&f->lock);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue