Lines Matching defs:rqstp

1880 static struct nfsd4_conn *alloc_conn(struct svc_rqst *rqstp, u32 flags)
1887 svc_xprt_get(rqstp->rq_xprt);
1888 conn->cn_xprt = rqstp->rq_xprt;
1915 static void nfsd4_init_conn(struct svc_rqst *rqstp, struct nfsd4_conn *conn, struct nfsd4_session *ses)
1928 static struct nfsd4_conn *alloc_conn_from_crses(struct svc_rqst *rqstp, struct nfsd4_create_session *cses)
1934 return alloc_conn(rqstp, dir);
1970 static void init_session(struct svc_rqst *rqstp, struct nfsd4_session *new, struct nfs4_client *clp, struct nfsd4_create_session *cses)
1973 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
1992 struct sockaddr *sa = svc_addr(rqstp);
2399 static bool svc_rqst_integrity_protected(struct svc_rqst *rqstp)
2401 struct svc_cred *cr = &rqstp->rq_cred;
2411 bool nfsd4_mach_creds_match(struct nfs4_client *cl, struct svc_rqst *rqstp)
2413 struct svc_cred *cr = &rqstp->rq_cred;
2419 if (!svc_rqst_integrity_protected(rqstp))
2903 struct svc_rqst *rqstp, nfs4_verifier *verf)
2906 struct sockaddr *sa = svc_addr(rqstp);
2908 struct net *net = SVC_NET(rqstp);
2916 ret = copy_cred(&clp->cl_cred, &rqstp->rq_cred);
3076 gen_callback(struct nfs4_client *clp, struct nfsd4_setclientid *se, struct svc_rqst *rqstp)
3079 struct sockaddr *sa = svc_addr(rqstp);
3106 memcpy(&conn->cb_saddr, &rqstp->rq_daddr, rqstp->rq_daddrlen);
3132 copy_cred(&slot->sl_cred, &resp->rqstp->rq_cred);
3198 status = nfsd4_enc_sequence_replay(resp->rqstp->rq_argp, resp);
3271 nfsd4_exchange_id(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
3280 struct sockaddr *sa = svc_addr(rqstp);
3282 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3285 dprintk("%s rqstp=%p exid=%p clname.len=%u clname.data=%p "
3287 __func__, rqstp, exid, exid->clname.len, exid->clname.data,
3293 new = create_client(exid->clname, rqstp, &verf);
3318 if (!svc_rqst_integrity_protected(rqstp)) {
3348 bool creds_match = same_creds(&conf->cl_cred, &rqstp->rq_cred);
3356 if (!nfsd4_mach_creds_match(conf, rqstp)) {
3376 trace_nfsd_clid_cred_mismatch(conf, rqstp);
3387 trace_nfsd_clid_verf_mismatch(conf, rqstp, &verf);
3579 nfsd4_create_session(struct svc_rqst *rqstp,
3583 struct sockaddr *sa = svc_addr(rqstp);
3590 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3607 conn = alloc_conn_from_crses(rqstp, cr_ses);
3618 if (!nfsd4_mach_creds_match(conf, rqstp))
3629 if (!same_creds(&unconf->cl_cred, &rqstp->rq_cred) ||
3631 trace_nfsd_clid_cred_mismatch(unconf, rqstp);
3635 if (!nfsd4_mach_creds_match(unconf, rqstp))
3665 init_session(rqstp, new, conf, cr_ses);
3679 nfsd4_init_conn(rqstp, conn, new);
3710 __be32 nfsd4_backchannel_ctl(struct svc_rqst *rqstp,
3716 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
3773 __be32 nfsd4_bind_conn_to_session(struct svc_rqst *rqstp,
3781 struct net *net = SVC_NET(rqstp);
3784 if (!nfsd4_last_compound_op(rqstp))
3792 if (!nfsd4_mach_creds_match(session->se_client, rqstp))
3794 status = nfsd4_match_existing_connection(rqstp, session,
3808 conn = alloc_conn(rqstp, bcts->dir);
3812 nfsd4_init_conn(rqstp, conn, session);
3897 static bool nfsd4_session_too_many_ops(struct svc_rqst *rqstp, struct nfsd4_session *session)
3899 struct nfsd4_compoundargs *args = rqstp->rq_argp;
3904 static bool nfsd4_request_too_big(struct svc_rqst *rqstp,
3907 struct xdr_buf *xb = &rqstp->rq_arg;
3912 static bool replay_matches_cache(struct svc_rqst *rqstp,
3915 struct nfsd4_compoundargs *argp = rqstp->rq_argp;
3934 if (!same_creds(&rqstp->rq_cred, &slot->sl_cred))
3946 nfsd4_sequence(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
3950 struct nfsd4_compoundres *resp = rqstp->rq_resp;
3958 struct net *net = SVC_NET(rqstp);
3968 conn = alloc_conn(rqstp, NFS4_CDFC4_FORE);
3979 if (nfsd4_session_too_many_ops(rqstp, session))
3983 if (nfsd4_request_too_big(rqstp, session))
4005 if (!replay_matches_cache(rqstp, seq, slot))
4029 if (xdr_restrict_buflen(xdr, buflen - rqstp->rq_auth_slack))
4031 svc_reserve(rqstp, buflen);
4086 nfsd4_destroy_clientid(struct svc_rqst *rqstp,
4094 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4116 if (!nfsd4_mach_creds_match(clp, rqstp)) {
4131 nfsd4_reclaim_complete(struct svc_rqst *rqstp,
4172 nfsd4_setclientid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
4181 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4183 new = create_client(clname, rqstp, &clverifier);
4192 if (!same_creds(&conf->cl_cred, &rqstp->rq_cred)) {
4193 trace_nfsd_clid_cred_mismatch(conf, rqstp);
4205 trace_nfsd_clid_verf_mismatch(conf, rqstp,
4210 gen_callback(new, setclid, rqstp);
4229 nfsd4_setclientid_confirm(struct svc_rqst *rqstp,
4240 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
4256 if (unconf && !same_creds(&unconf->cl_cred, &rqstp->rq_cred)) {
4257 trace_nfsd_clid_cred_mismatch(unconf, rqstp);
4260 if (conf && !same_creds(&conf->cl_cred, &rqstp->rq_cred)) {
4261 trace_nfsd_clid_cred_mismatch(conf, rqstp);
4820 * @rqstp: the RPC transaction being executed
4830 bool nfsd_wait_for_delegreturn(struct svc_rqst *rqstp, struct inode *inode)
4836 trace_nfsd_delegret_wakeup(rqstp, inode, timeo);
5177 nfsd4_truncate(struct svc_rqst *rqstp, struct svc_fh *fh,
5191 return nfsd_setattr(rqstp, fh, &attrs, 0, (time64_t)0);
5194 static __be32 nfs4_get_vfs_file(struct svc_rqst *rqstp, struct nfs4_file *fp,
5249 status = nfsd_file_acquire_opened(rqstp, cur_fh, access,
5269 status = nfsd4_truncate(rqstp, cur_fh, open);
5282 nfs4_upgrade_open(struct svc_rqst *rqstp, struct nfs4_file *fp,
5290 return nfs4_get_vfs_file(rqstp, fp, cur_fh, stp, open, false);
5312 status = nfsd4_truncate(rqstp, cur_fh, open);
5713 * @rqstp: the RPC transaction being executed
5724 nfsd4_process_open2(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_open *open)
5726 struct nfsd4_compoundres *resp = rqstp->rq_resp;
5768 status = nfs4_upgrade_open(rqstp, fp, current_fh, stp, open);
5774 status = nfs4_get_vfs_file(rqstp, fp, current_fh, stp, open, true);
5852 nfsd4_renew(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
5858 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
6509 nfs4_check_file(struct svc_rqst *rqstp, struct svc_fh *fhp, struct nfs4_stid *s,
6518 status = nfsd_permission(rqstp, fhp->fh_export, fhp->fh_dentry,
6525 status = nfsd_file_acquire(rqstp, fhp, acc, &nf);
6621 * @rqstp: incoming request from client
6634 nfs4_preprocess_stateid_op(struct svc_rqst *rqstp,
6639 struct net *net = SVC_NET(rqstp);
6686 status = nfs4_check_file(rqstp, fhp, s, nfp, flags);
6701 nfsd4_test_stateid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
6745 nfsd4_free_stateid(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
6882 nfsd4_open_confirm(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
6889 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
6894 status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0);
6949 nfsd4_open_downgrade(struct svc_rqst *rqstp,
6955 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7021 nfsd4_close(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7027 struct net *net = SVC_NET(rqstp);
7070 nfsd4_delegreturn(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7078 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7080 if ((status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0)))
7476 nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7495 struct net *net = SVC_NET(rqstp);
7505 if ((status = fh_verify(rqstp, &cstate->current_fh,
7712 static __be32 nfsd_test_lock(struct svc_rqst *rqstp, struct svc_fh *fhp, struct file_lock *lock)
7718 err = nfsd_file_acquire(rqstp, fhp, NFSD_MAY_READ, &nf);
7739 nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7746 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7748 if (locks_in_grace(SVC_NET(rqstp)))
7760 if ((status = fh_verify(rqstp, &cstate->current_fh, S_IFREG, 0)))
7796 status = nfsd_test_lock(rqstp, &cstate->current_fh, file_lock);
7813 nfsd4_locku(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
7822 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
7924 * @rqstp: RPC transaction
7938 nfsd4_release_lockowner(struct svc_rqst *rqstp,
7943 struct nfsd_net *nn = net_generic(SVC_NET(rqstp), nfsd_net_id);
8407 * @rqstp: RPC transaction context
8425 nfsd4_deleg_getattr_conflict(struct svc_rqst *rqstp, struct inode *inode)
8451 if (dp->dl_recall.cb_clp == *(rqstp->rq_lease_breaker)) {
8460 !nfsd_wait_for_delegreturn(rqstp, inode))