Lines Matching refs:l_ctx

116 nfs_iocounter_wait(struct nfs_lock_context *l_ctx)  in nfs_iocounter_wait()  argument
118 return wait_var_event_killable(&l_ctx->io_count, in nfs_iocounter_wait()
119 !atomic_read(&l_ctx->io_count)); in nfs_iocounter_wait()
132 nfs_async_iocounter_wait(struct rpc_task *task, struct nfs_lock_context *l_ctx) in nfs_async_iocounter_wait() argument
134 struct inode *inode = d_inode(l_ctx->open_context->dentry); in nfs_async_iocounter_wait()
137 if (atomic_read(&l_ctx->io_count) > 0) { in nfs_async_iocounter_wait()
142 if (atomic_read(&l_ctx->io_count) == 0) { in nfs_async_iocounter_wait()
435 __nfs_create_request(struct nfs_lock_context *l_ctx, struct page *page, in __nfs_create_request() argument
440 struct nfs_open_context *ctx = l_ctx->open_context; in __nfs_create_request()
449 req->wb_lock_context = l_ctx; in __nfs_create_request()
450 refcount_inc(&l_ctx->count); in __nfs_create_request()
451 atomic_inc(&l_ctx->io_count); in __nfs_create_request()
484 struct nfs_lock_context *l_ctx = nfs_get_lock_context(ctx); in nfs_create_request() local
487 if (IS_ERR(l_ctx)) in nfs_create_request()
488 return ERR_CAST(l_ctx); in nfs_create_request()
489 ret = __nfs_create_request(l_ctx, page, offset, offset, count); in nfs_create_request()
492 nfs_put_lock_context(l_ctx); in nfs_create_request()
560 struct nfs_lock_context *l_ctx = req->wb_lock_context; in nfs_clear_request() local
567 if (l_ctx != NULL) { in nfs_clear_request()
568 if (atomic_dec_and_test(&l_ctx->io_count)) { in nfs_clear_request()
569 wake_up_var(&l_ctx->io_count); in nfs_clear_request()
570 ctx = l_ctx->open_context; in nfs_clear_request()
574 nfs_put_lock_context(l_ctx); in nfs_clear_request()