Lines Matching refs:cmsgs

1594 			     struct sctp_cmsgs *cmsgs);
1596 static int sctp_sendmsg_parse(struct sock *sk, struct sctp_cmsgs *cmsgs, in sctp_sendmsg_parse() argument
1609 memset(cmsgs, 0, sizeof(*cmsgs)); in sctp_sendmsg_parse()
1610 err = sctp_msghdr_parse(msg, cmsgs); in sctp_sendmsg_parse()
1617 if (cmsgs->srinfo) { in sctp_sendmsg_parse()
1618 srinfo->sinfo_stream = cmsgs->srinfo->sinfo_stream; in sctp_sendmsg_parse()
1619 srinfo->sinfo_flags = cmsgs->srinfo->sinfo_flags; in sctp_sendmsg_parse()
1620 srinfo->sinfo_ppid = cmsgs->srinfo->sinfo_ppid; in sctp_sendmsg_parse()
1621 srinfo->sinfo_context = cmsgs->srinfo->sinfo_context; in sctp_sendmsg_parse()
1622 srinfo->sinfo_assoc_id = cmsgs->srinfo->sinfo_assoc_id; in sctp_sendmsg_parse()
1623 srinfo->sinfo_timetolive = cmsgs->srinfo->sinfo_timetolive; in sctp_sendmsg_parse()
1626 if (cmsgs->sinfo) { in sctp_sendmsg_parse()
1627 srinfo->sinfo_stream = cmsgs->sinfo->snd_sid; in sctp_sendmsg_parse()
1628 srinfo->sinfo_flags = cmsgs->sinfo->snd_flags; in sctp_sendmsg_parse()
1629 srinfo->sinfo_ppid = cmsgs->sinfo->snd_ppid; in sctp_sendmsg_parse()
1630 srinfo->sinfo_context = cmsgs->sinfo->snd_context; in sctp_sendmsg_parse()
1631 srinfo->sinfo_assoc_id = cmsgs->sinfo->snd_assoc_id; in sctp_sendmsg_parse()
1634 if (cmsgs->prinfo) { in sctp_sendmsg_parse()
1635 srinfo->sinfo_timetolive = cmsgs->prinfo->pr_value; in sctp_sendmsg_parse()
1637 cmsgs->prinfo->pr_policy); in sctp_sendmsg_parse()
1658 struct sctp_cmsgs *cmsgs, in sctp_sendmsg_new_asoc() argument
1693 err = sctp_connect_new_asoc(ep, daddr, cmsgs->init, tp); in sctp_sendmsg_new_asoc()
1698 if (!cmsgs->addrs_msg) in sctp_sendmsg_new_asoc()
1705 for_each_cmsghdr(cmsg, cmsgs->addrs_msg) { in sctp_sendmsg_new_asoc()
1896 struct sctp_cmsgs *cmsgs) in sctp_sendmsg_get_daddr() argument
1919 struct sctp_cmsgs *cmsgs) in sctp_sendmsg_update_sinfo() argument
1921 if (!cmsgs->srinfo && !cmsgs->sinfo) { in sctp_sendmsg_update_sinfo()
1927 if (!cmsgs->prinfo) in sctp_sendmsg_update_sinfo()
1931 if (!cmsgs->srinfo && !cmsgs->prinfo) in sctp_sendmsg_update_sinfo()
1934 if (cmsgs->authinfo) { in sctp_sendmsg_update_sinfo()
1939 sinfo->sinfo_ssn = cmsgs->authinfo->auth_keynumber; in sctp_sendmsg_update_sinfo()
1949 struct sctp_cmsgs cmsgs; in sctp_sendmsg() local
1956 err = sctp_sendmsg_parse(sk, &cmsgs, &_sinfo, msg, msg_len); in sctp_sendmsg()
1964 daddr = sctp_sendmsg_get_daddr(sk, msg, &cmsgs); in sctp_sendmsg()
1982 sctp_sendmsg_update_sinfo(asoc, sinfo, &cmsgs); in sctp_sendmsg()
2004 err = sctp_sendmsg_new_asoc(sk, sflags, &cmsgs, daddr, in sctp_sendmsg()
2028 sctp_sendmsg_update_sinfo(asoc, sinfo, &cmsgs); in sctp_sendmsg()
8829 static int sctp_msghdr_parse(const struct msghdr *msg, struct sctp_cmsgs *cmsgs) in sctp_msghdr_parse() argument
8861 cmsgs->init = CMSG_DATA(cmsg); in sctp_msghdr_parse()
8879 cmsgs->srinfo = CMSG_DATA(cmsg); in sctp_msghdr_parse()
8881 if (cmsgs->srinfo->sinfo_flags & in sctp_msghdr_parse()
8903 cmsgs->sinfo = CMSG_DATA(cmsg); in sctp_msghdr_parse()
8905 if (cmsgs->sinfo->snd_flags & in sctp_msghdr_parse()
8924 cmsgs->prinfo = CMSG_DATA(cmsg); in sctp_msghdr_parse()
8925 if (cmsgs->prinfo->pr_policy & ~SCTP_PR_SCTP_MASK) in sctp_msghdr_parse()
8928 if (cmsgs->prinfo->pr_policy == SCTP_PR_SCTP_NONE) in sctp_msghdr_parse()
8929 cmsgs->prinfo->pr_value = 0; in sctp_msghdr_parse()
8944 cmsgs->authinfo = CMSG_DATA(cmsg); in sctp_msghdr_parse()
8959 cmsgs->addrs_msg = my_msg; in sctp_msghdr_parse()