Lines Matching refs:uap
140 sys_sctp_peeloff(struct thread *td, struct sctp_peeloff_args *uap) in sys_sctp_peeloff() argument
149 AUDIT_ARG_FD(uap->sd); in sys_sctp_peeloff()
150 error = getsock_cap(td, uap->sd, in sys_sctp_peeloff()
160 error = sctp_can_peel_off(head, (sctp_assoc_t)uap->name); in sys_sctp_peeloff()
181 error = sctp_do_peeloff(head, so, (sctp_assoc_t)uap->name); in sys_sctp_peeloff()
208 sys_sctp_generic_sendmsg(struct thread *td, struct sctp_generic_sendmsg_args *uap) in sys_sctp_generic_sendmsg() argument
222 if (uap->sinfo != NULL) { in sys_sctp_generic_sendmsg()
223 error = copyin(uap->sinfo, &sinfo, sizeof (sinfo)); in sys_sctp_generic_sendmsg()
230 if (uap->tolen != 0) { in sys_sctp_generic_sendmsg()
231 error = getsockaddr(&to, uap->to, uap->tolen); in sys_sctp_generic_sendmsg()
239 AUDIT_ARG_FD(uap->sd); in sys_sctp_generic_sendmsg()
240 error = getsock(td, uap->sd, &rights, &fp); in sys_sctp_generic_sendmsg()
248 iov[0].iov_base = uap->msg; in sys_sctp_generic_sendmsg()
249 iov[0].iov_len = uap->mlen; in sys_sctp_generic_sendmsg()
273 len = auio.uio_resid = uap->mlen; in sys_sctp_generic_sendmsg()
276 (struct mbuf *)NULL, uap->flags, u_sinfo, td); in sys_sctp_generic_sendmsg()
284 !(uap->flags & MSG_NOSIGNAL)) { in sys_sctp_generic_sendmsg()
296 ktrgenio(uap->sd, UIO_WRITE, ktruio, error); in sys_sctp_generic_sendmsg()
308 sys_sctp_generic_sendmsg_iov(struct thread *td, struct sctp_generic_sendmsg_iov_args *uap) in sys_sctp_generic_sendmsg_iov() argument
323 if (uap->sinfo != NULL) { in sys_sctp_generic_sendmsg_iov()
324 error = copyin(uap->sinfo, &sinfo, sizeof (sinfo)); in sys_sctp_generic_sendmsg_iov()
330 if (uap->tolen != 0) { in sys_sctp_generic_sendmsg_iov()
331 error = getsockaddr(&to, uap->to, uap->tolen); in sys_sctp_generic_sendmsg_iov()
339 AUDIT_ARG_FD(uap->sd); in sys_sctp_generic_sendmsg_iov()
340 error = getsock(td, uap->sd, &rights, &fp); in sys_sctp_generic_sendmsg_iov()
346 error = freebsd32_copyiniov((struct iovec32 *)uap->iov, in sys_sctp_generic_sendmsg_iov()
347 uap->iovlen, &iov, EMSGSIZE); in sys_sctp_generic_sendmsg_iov()
350 error = copyiniov(uap->iov, uap->iovlen, &iov, EMSGSIZE); in sys_sctp_generic_sendmsg_iov()
370 auio.uio_iovcnt = uap->iovlen; in sys_sctp_generic_sendmsg_iov()
377 for (i = 0; i <uap->iovlen; i++, tiov++) { in sys_sctp_generic_sendmsg_iov()
391 uap->flags, u_sinfo, td); in sys_sctp_generic_sendmsg_iov()
399 !(uap->flags & MSG_NOSIGNAL)) { in sys_sctp_generic_sendmsg_iov()
411 ktrgenio(uap->sd, UIO_WRITE, ktruio, error); in sys_sctp_generic_sendmsg_iov()
425 sys_sctp_generic_recvmsg(struct thread *td, struct sctp_generic_recvmsg_args *uap) in sys_sctp_generic_recvmsg() argument
441 AUDIT_ARG_FD(uap->sd); in sys_sctp_generic_recvmsg()
442 error = getsock(td, uap->sd, cap_rights_init_one(&rights, CAP_RECV), in sys_sctp_generic_recvmsg()
448 error = freebsd32_copyiniov((struct iovec32 *)uap->iov, in sys_sctp_generic_recvmsg()
449 uap->iovlen, &iov, EMSGSIZE); in sys_sctp_generic_recvmsg()
452 error = copyiniov(uap->iov, uap->iovlen, &iov, EMSGSIZE); in sys_sctp_generic_recvmsg()
467 if (uap->fromlenaddr != NULL) { in sys_sctp_generic_recvmsg()
468 error = copyin(uap->fromlenaddr, &fromlen, sizeof (fromlen)); in sys_sctp_generic_recvmsg()
474 if (uap->msg_flags) { in sys_sctp_generic_recvmsg()
475 error = copyin(uap->msg_flags, &msg_flags, sizeof (int)); in sys_sctp_generic_recvmsg()
482 auio.uio_iovcnt = uap->iovlen; in sys_sctp_generic_recvmsg()
489 for (i = 0; i <uap->iovlen; i++, tiov++) { in sys_sctp_generic_recvmsg()
513 if (uap->sinfo) in sys_sctp_generic_recvmsg()
514 error = copyout(&sinfo, uap->sinfo, sizeof (sinfo)); in sys_sctp_generic_recvmsg()
519 ktrgenio(uap->sd, UIO_READ, ktruio, error); in sys_sctp_generic_recvmsg()
526 if (fromlen && uap->from) { in sys_sctp_generic_recvmsg()
532 error = copyout(fromsa, uap->from, (size_t)len); in sys_sctp_generic_recvmsg()
536 error = copyout(&len, uap->fromlenaddr, sizeof (socklen_t)); in sys_sctp_generic_recvmsg()
544 if (uap->msg_flags) { in sys_sctp_generic_recvmsg()
545 error = copyout(&msg_flags, uap->msg_flags, sizeof (int)); in sys_sctp_generic_recvmsg()