/linux-6.6.21/fs/nfs/ |
D | pagelist.c | 155 nfs_iocounter_wait(struct nfs_lock_context *l_ctx) in nfs_iocounter_wait() argument 157 return wait_var_event_killable(&l_ctx->io_count, in nfs_iocounter_wait() 158 !atomic_read(&l_ctx->io_count)); in nfs_iocounter_wait() 171 nfs_async_iocounter_wait(struct rpc_task *task, struct nfs_lock_context *l_ctx) in nfs_async_iocounter_wait() argument 173 struct inode *inode = d_inode(l_ctx->open_context->dentry); in nfs_async_iocounter_wait() 176 if (atomic_read(&l_ctx->io_count) > 0) { in nfs_async_iocounter_wait() 181 if (atomic_read(&l_ctx->io_count) == 0) { in nfs_async_iocounter_wait() 472 static struct nfs_page *nfs_page_create(struct nfs_lock_context *l_ctx, in nfs_page_create() argument 477 struct nfs_open_context *ctx = l_ctx->open_context; in nfs_page_create() 486 req->wb_lock_context = l_ctx; in nfs_page_create() [all …]
|
D | nfs3proc.c | 924 struct nfs_lock_context *l_ctx = data; in nfs3_nlm_alloc_call() local 925 if (l_ctx && test_bit(NFS_CONTEXT_UNLOCK, &l_ctx->open_context->flags)) { in nfs3_nlm_alloc_call() 926 get_nfs_open_context(l_ctx->open_context); in nfs3_nlm_alloc_call() 927 nfs_get_lock_context(l_ctx->open_context); in nfs3_nlm_alloc_call() 933 struct nfs_lock_context *l_ctx = data; in nfs3_nlm_unlock_prepare() local 934 if (l_ctx && test_bit(NFS_CONTEXT_UNLOCK, &l_ctx->open_context->flags)) in nfs3_nlm_unlock_prepare() 935 return nfs_async_iocounter_wait(task, l_ctx); in nfs3_nlm_unlock_prepare() 942 struct nfs_lock_context *l_ctx = data; in nfs3_nlm_release_call() local 944 if (l_ctx && test_bit(NFS_CONTEXT_UNLOCK, &l_ctx->open_context->flags)) { in nfs3_nlm_release_call() 945 ctx = l_ctx->open_context; in nfs3_nlm_release_call() [all …]
|
D | direct.c | 196 if (dreq->l_ctx != NULL) in nfs_direct_req_free() 197 nfs_put_lock_context(dreq->l_ctx); in nfs_direct_req_free() 424 struct nfs_lock_context *l_ctx; in nfs_file_direct_read() local 447 l_ctx = nfs_get_lock_context(dreq->ctx); in nfs_file_direct_read() 448 if (IS_ERR(l_ctx)) { in nfs_file_direct_read() 449 result = PTR_ERR(l_ctx); in nfs_file_direct_read() 453 dreq->l_ctx = l_ctx; in nfs_file_direct_read() 957 struct nfs_lock_context *l_ctx; in nfs_file_direct_write() local 987 l_ctx = nfs_get_lock_context(dreq->ctx); in nfs_file_direct_write() 988 if (IS_ERR(l_ctx)) { in nfs_file_direct_write() [all …]
|
D | file.c | 752 struct nfs_lock_context *l_ctx; in do_unlk() local 761 l_ctx = nfs_get_lock_context(nfs_file_open_context(filp)); in do_unlk() 762 if (!IS_ERR(l_ctx)) { in do_unlk() 763 status = nfs_iocounter_wait(l_ctx); in do_unlk() 764 nfs_put_lock_context(l_ctx); in do_unlk()
|
D | inode.c | 929 static void nfs_init_lock_context(struct nfs_lock_context *l_ctx) in nfs_init_lock_context() argument 931 refcount_set(&l_ctx->count, 1); in nfs_init_lock_context() 932 l_ctx->lockowner = current->files; in nfs_init_lock_context() 933 INIT_LIST_HEAD(&l_ctx->list); in nfs_init_lock_context() 934 atomic_set(&l_ctx->io_count, 0); in nfs_init_lock_context() 982 void nfs_put_lock_context(struct nfs_lock_context *l_ctx) in nfs_put_lock_context() argument 984 struct nfs_open_context *ctx = l_ctx->open_context; in nfs_put_lock_context() 987 if (!refcount_dec_and_lock(&l_ctx->count, &inode->i_lock)) in nfs_put_lock_context() 989 list_del_rcu(&l_ctx->list); in nfs_put_lock_context() 992 kfree_rcu(l_ctx, rcu_head); in nfs_put_lock_context()
|
D | nfs42proc.c | 597 struct nfs_lock_context *l_ctx; in _nfs42_proc_copy_notify() local 600 l_ctx = nfs_get_lock_context(ctx); in _nfs42_proc_copy_notify() 601 if (IS_ERR(l_ctx)) { in _nfs42_proc_copy_notify() 602 status = PTR_ERR(l_ctx); in _nfs42_proc_copy_notify() 606 status = nfs4_set_rw_stateid(&args->cna_src_stateid, ctx, l_ctx, in _nfs42_proc_copy_notify() 608 nfs_put_lock_context(l_ctx); in _nfs42_proc_copy_notify()
|
D | nfs4state.c | 993 const struct nfs_lock_context *l_ctx) in nfs4_copy_lock_stateid() argument 999 if (l_ctx == NULL) in nfs4_copy_lock_stateid() 1005 fl_owner = l_ctx->lockowner; in nfs4_copy_lock_stateid() 1006 fl_flock_owner = l_ctx->open_context->flock_owner; in nfs4_copy_lock_stateid() 1046 fmode_t fmode, const struct nfs_lock_context *l_ctx, in nfs4_select_rw_stateid() argument 1055 ret = nfs4_copy_lock_stateid(dst, state, l_ctx); in nfs4_select_rw_stateid()
|
D | internal.h | 296 int nfs_iocounter_wait(struct nfs_lock_context *l_ctx); 928 struct nfs_lock_context *l_ctx; /* Lock context info */ member
|
D | write.c | 1193 struct nfs_lock_context *l_ctx; in nfs_flush_incompatible() local 1209 l_ctx = req->wb_lock_context; in nfs_flush_incompatible() 1212 if (l_ctx && flctx && in nfs_flush_incompatible() 1215 do_flush |= l_ctx->lockowner != current->files; in nfs_flush_incompatible()
|
D | nfs4_fs.h | 321 const struct nfs_lock_context *l_ctx,
|
D | nfs4proc.c | 3325 struct nfs_lock_context *l_ctx; in _nfs4_do_setattr() local 3328 l_ctx = nfs_get_lock_context(ctx); in _nfs4_do_setattr() 3329 if (IS_ERR(l_ctx)) in _nfs4_do_setattr() 3330 return PTR_ERR(l_ctx); in _nfs4_do_setattr() 3331 status = nfs4_select_rw_stateid(ctx->state, FMODE_WRITE, l_ctx, in _nfs4_do_setattr() 3333 nfs_put_lock_context(l_ctx); in _nfs4_do_setattr() 5358 const struct nfs_lock_context *l_ctx, in nfs4_set_rw_stateid() argument 5361 return nfs4_select_rw_stateid(ctx->state, fmode, l_ctx, stateid, NULL); in nfs4_set_rw_stateid() 5367 const struct nfs_lock_context *l_ctx, in nfs4_stateid_is_current() argument 5373 if (nfs4_set_rw_stateid(&_current_stateid, ctx, l_ctx, fmode) == -EIO) in nfs4_stateid_is_current() [all …]
|
/linux-6.6.21/include/linux/ |
D | nfs_fs.h | 447 extern void nfs_put_lock_context(struct nfs_lock_context *l_ctx);
|