Lines Matching refs:rqstp

2018 static struct nfsd4_conn *alloc_conn(struct svc_rqst *rqstp, u32 flags)
2025 svc_xprt_get(rqstp->rq_xprt);
2026 conn->cn_xprt = rqstp->rq_xprt;
2053 static void nfsd4_init_conn(struct svc_rqst *rqstp, struct nfsd4_conn *conn, struct nfsd4_session *ses)
2066 static struct nfsd4_conn *alloc_conn_from_crses(struct svc_rqst *rqstp, struct nfsd4_create_session *cses)
2072 return alloc_conn(rqstp, dir);
2108 static void init_session(struct svc_rqst *rqstp, struct nfsd4_session *new, struct nfs4_client *clp, struct nfsd4_create_session *cses)
2111 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
2130 struct sockaddr *sa = svc_addr(rqstp);
2548 static bool svc_rqst_integrity_protected(struct svc_rqst *rqstp)
2550 struct svc_cred *cr = &rqstp->rq_cred;
2560 bool nfsd4_mach_creds_match(struct nfs4_client *cl, struct svc_rqst *rqstp)
2562 struct svc_cred *cr = &rqstp->rq_cred;
2568 if (!svc_rqst_integrity_protected(rqstp))
3108 struct svc_rqst *rqstp, nfs4_verifier *verf)
3111 struct sockaddr *sa = svc_addr(rqstp);
3113 struct net *net = SVC_NET(rqstp);
3121 ret = copy_cred(&clp->cl_cred, &rqstp->rq_cred);
3281 gen_callback(struct nfs4_client *clp, struct nfsd4_setclientid *se, struct svc_rqst *rqstp)
3284 struct sockaddr *sa = svc_addr(rqstp);
3311 memcpy(&conn->cb_saddr, &rqstp->rq_daddr, rqstp->rq_daddrlen);
3337 copy_cred(&slot->sl_cred, &resp->rqstp->rq_cred);
3403 status = nfsd4_enc_sequence_replay(resp->rqstp->rq_argp, resp);
3476 nfsd4_exchange_id(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
3485 struct sockaddr *sa = svc_addr(rqstp);
3487 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3490 dprintk("%s rqstp=%p exid=%p clname.len=%u clname.data=%p "
3492 __func__, rqstp, exid, exid->clname.len, exid->clname.data,
3498 new = create_client(exid->clname, rqstp, &verf);
3523 if (!svc_rqst_integrity_protected(rqstp)) {
3553 bool creds_match = same_creds(&conf->cl_cred, &rqstp->rq_cred);
3561 if (!nfsd4_mach_creds_match(conf, rqstp)) {
3581 trace_nfsd_clid_cred_mismatch(conf, rqstp);
3592 trace_nfsd_clid_verf_mismatch(conf, rqstp, &verf);
3783 nfsd4_create_session(struct svc_rqst *rqstp,
3787 struct sockaddr *sa = svc_addr(rqstp);
3794 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3811 conn = alloc_conn_from_crses(rqstp, cr_ses);
3852 if (!nfsd4_mach_creds_match(conf, rqstp))
3856 if (!same_creds(&unconf->cl_cred, &rqstp->rq_cred) ||
3858 trace_nfsd_clid_cred_mismatch(unconf, rqstp);
3862 if (!nfsd4_mach_creds_match(unconf, rqstp))
3882 init_session(rqstp, new, conf, cr_ses);
3894 nfsd4_init_conn(rqstp, conn, new);
3939 __be32 nfsd4_backchannel_ctl(struct svc_rqst *rqstp,
3945 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4002 __be32 nfsd4_bind_conn_to_session(struct svc_rqst *rqstp,
4010 struct net *net = SVC_NET(rqstp);
4013 if (!nfsd4_last_compound_op(rqstp))
4021 if (!nfsd4_mach_creds_match(session->se_client, rqstp))
4023 status = nfsd4_match_existing_connection(rqstp, session,
4037 conn = alloc_conn(rqstp, bcts->dir);
4041 nfsd4_init_conn(rqstp, conn, session);
4126 static bool nfsd4_session_too_many_ops(struct svc_rqst *rqstp, struct nfsd4_session *session)
4128 struct nfsd4_compoundargs *args = rqstp->rq_argp;
4133 static bool nfsd4_request_too_big(struct svc_rqst *rqstp,
4136 struct xdr_buf *xb = &rqstp->rq_arg;
4141 static bool replay_matches_cache(struct svc_rqst *rqstp,
4144 struct nfsd4_compoundargs *argp = rqstp->rq_argp;
4163 if (!same_creds(&rqstp->rq_cred, &slot->sl_cred))
4175 nfsd4_sequence(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
4179 struct nfsd4_compoundres *resp = rqstp->rq_resp;
4187 struct net *net = SVC_NET(rqstp);
4197 conn = alloc_conn(rqstp, NFS4_CDFC4_FORE);
4208 if (nfsd4_session_too_many_ops(rqstp, session))
4212 if (nfsd4_request_too_big(rqstp, session))
4235 if (!replay_matches_cache(rqstp, seq, slot))
4259 if (xdr_restrict_buflen(xdr, buflen - rqstp->rq_auth_slack))
4261 svc_reserve(rqstp, buflen);
4291 trace_nfsd_seq4_status(rqstp, seq);
4319 nfsd4_destroy_clientid(struct svc_rqst *rqstp,
4327 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4349 if (!nfsd4_mach_creds_match(clp, rqstp)) {
4364 nfsd4_reclaim_complete(struct svc_rqst *rqstp,
4405 nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
4414 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4416 new = create_client(clname, rqstp, &clverifier);
4425 if (!same_creds(&conf->cl_cred, &rqstp->rq_cred)) {
4426 trace_nfsd_clid_cred_mismatch(conf, rqstp);
4438 trace_nfsd_clid_verf_mismatch(conf, rqstp,
4443 gen_callback(new, setclid, rqstp);
4462 nfsd4_setclientid_confirm(struct svc_rqst *rqstp,
4473 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4489 if (unconf && !same_creds(&unconf->cl_cred, &rqstp->rq_cred)) {
4490 trace_nfsd_clid_cred_mismatch(unconf, rqstp);
4493 if (conf && !same_creds(&conf->cl_cred, &rqstp->rq_cred)) {
4494 trace_nfsd_clid_cred_mismatch(conf, rqstp);
5131 * @rqstp: the RPC transaction being executed
5141 bool nfsd_wait_for_delegreturn(struct svc_rqst *rqstp, struct inode *inode)
5147 trace_nfsd_delegret_wakeup(rqstp, inode, timeo);
5485 nfsd4_truncate(struct svc_rqst *rqstp, struct svc_fh *fh,
5499 return nfsd_setattr(rqstp, fh, &attrs, NULL);
5502 static __be32 nfs4_get_vfs_file(struct svc_rqst *rqstp, struct nfs4_file *fp,
5557 status = nfsd_file_acquire_opened(rqstp, cur_fh, access,
5577 status = nfsd4_truncate(rqstp, cur_fh, open);
5590 nfs4_upgrade_open(struct svc_rqst *rqstp, struct nfs4_file *fp,
5598 return nfs4_get_vfs_file(rqstp, fp, cur_fh, stp, open, false);
5620 status = nfsd4_truncate(rqstp, cur_fh, open);
6037 * @rqstp: the RPC transaction being executed
6048 nfsd4_process_open2(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open)
6050 struct nfsd4_compoundres *resp = rqstp->rq_resp;
6092 status = nfs4_upgrade_open(rqstp, fp, current_fh, stp, open);
6098 status = nfs4_get_vfs_file(rqstp, fp, current_fh, stp, open, true);
6171 nfsd4_renew(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
6177 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
6883 nfs4_check_file(struct svc_rqst *rqstp, struct svc_fh *fhp, struct nfs4_stid *s,
6892 status = nfsd_permission(rqstp, fhp->fh_export, fhp->fh_dentry,
6899 status = nfsd_file_acquire(rqstp, fhp, acc, &nf);
6996 * @rqstp: incoming request from client
7009 nfs4_preprocess_stateid_op(struct svc_rqst *rqstp,
7014 struct net *net = SVC_NET(rqstp);
7058 status = nfs4_check_file(rqstp, fhp, s, nfp, flags);
7073 nfsd4_test_stateid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7117 nfsd4_free_stateid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7266 nfsd4_open_confirm(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7273 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7278 status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0);
7333 nfsd4_open_downgrade(struct svc_rqst *rqstp,
7339 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7405 nfsd4_close(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7411 struct net *net = SVC_NET(rqstp);
7459 nfsd4_delegreturn(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7467 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7469 if ((status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0)))
7865 nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7885 struct net *net = SVC_NET(rqstp);
7895 if ((status = fh_verify(rqstp, &cstate->current_fh,
8114 static __be32 nfsd_test_lock(struct svc_rqst *rqstp, struct svc_fh *fhp, struct file_lock *lock)
8120 err = nfsd_file_acquire(rqstp, fhp, NFSD_MAY_READ, &nf);
8141 nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
8148 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
8150 if (locks_in_grace(SVC_NET(rqstp)))
8162 if ((status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0)))
8198 status = nfsd_test_lock(rqstp, &cstate->current_fh, file_lock);
8223 nfsd4_locku(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
8232 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
8334 * @rqstp: RPC transaction
8348 nfsd4_release_lockowner(struct svc_rqst *rqstp,
8353 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
8814 * @rqstp: RPC transaction context
8830 nfsd4_deleg_getattr_conflict(struct svc_rqst *rqstp, struct inode *inode,
8834 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
8863 if (dp->dl_recall.cb_clp == *(rqstp->rq_lease_breaker)) {
8879 !nfsd_wait_for_delegreturn(rqstp, inode))