Home | History | Annotate | Download | only in netinet6

Lines Matching refs:inp

251 	if ((in6p->ip_inp.inp.inp_flags & INP_CONTROLOPTS)
280 /* inp's ref-count reduced && stcb unlocked */
313 sctp6_notify_mbuf(struct sctp_inpcb *inp,
321 if ((inp == NULL) || (stcb == NULL) || (net == NULL) ||
342 sctp_timer_stop(SCTP_TIMER_TYPE_PATHMTURAISE, inp, stcb, NULL);
389 sctp_timer_start(SCTP_TIMER_TYPE_PATHMTURAISE, inp, stcb, NULL);
391 if (inp) {
392 /* reduce inp's ref-count */
393 SCTP_INP_WLOCK(inp);
394 SCTP_INP_DECR_REF(inp);
395 SCTP_INP_WUNLOCK(inp);
435 struct sctp_inpcb *inp;
446 inp = NULL;
458 &inp, &net, 1);
459 /* inp's ref-count increased && stcb locked */
460 if (stcb != NULL && inp && (inp->sctp_socket != NULL)) {
462 sctp6_notify_mbuf(inp,
467 /* inp's ref-count reduced && stcb unlocked */
474 sctp_notify(inp, cm, &sh, sin6tosa(&final),
476 /* inp's ref-count reduced && stcb unlocked */
479 if (PRC_IS_REDIRECT(cmd) && inp) {
480 in6pcb_rtchange((struct inpcb *)inp, inet6ctlerrmap[cmd]);
482 if (inp) {
483 /* reduce inp's ref-count */
484 SCTP_INP_WLOCK(inp);
485 SCTP_INP_DECR_REF(inp);
486 SCTP_INP_WUNLOCK(inp);
506 struct sctp_inpcb *inp;
530 &inp, &net, 1);
531 if (stcb == NULL || inp == NULL || inp->sctp_socket == NULL) {
533 if (inp) {
534 SCTP_INP_WLOCK(inp);
535 SCTP_INP_DECR_REF(inp);
536 SCTP_INP_WUNLOCK(inp);
540 error = SYSCTL_OUT(req, inp->sctp_socket->so_cred,
560 struct sctp_inpcb *inp;
565 inp = (struct sctp_inpcb *)so->so_pcb;
566 if (inp == 0)
569 sctp_inpcb_free(inp, 1);
579 struct sctp_inpcb *inp;
582 inp = (struct sctp_inpcb *)so->so_pcb;
583 if (inp != NULL)
594 inp = (struct sctp_inpcb *)so->so_pcb;
595 inp->sctp_flags |= SCTP_PCB_FLAGS_BOUND_V6; /* I'm v6! */
596 inp6 = (struct in6pcb *)inp;
598 inp->inp_vflag |= INP_IPV6;
616 inp->inp_ip_ttl = ip_defttl;
628 struct sctp_inpcb *inp;
634 inp = (struct sctp_inpcb *)so->so_pcb;
635 if (inp == 0)
638 inp6 = (struct in6pcb *)inp;
639 inp->inp_vflag &= ~INP_IPV4;
640 inp->inp_vflag |= INP_IPV6;
645 inp->inp_vflag |= INP_IPV4;
646 inp->inp_vflag &= ~INP_IPV6;
652 inp->inp_vflag |= INP_IPV4;
657 inp->inp_vflag |= INP_IPV4;
658 inp->inp_vflag &= ~INP_IPV6;
686 struct sctp_inpcb *inp;
688 inp = (struct sctp_inpcb *)so->so_pcb;
689 if (inp == 0)
694 sctp_inpcb_free(inp, 1);
696 sctp_inpcb_free(inp, 0);
703 struct sctp_inpcb *inp;
705 inp = (struct sctp_inpcb *)so->so_pcb;
706 if (inp == NULL) {
709 if (inp->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) {
710 if (LIST_EMPTY(&inp->sctp_asoc_list)) {
718 stcb = LIST_FIRST(&inp->sctp_asoc_list);
795 struct sctp_inpcb *inp;
802 inp = (struct sctp_inpcb *)so->so_pcb;
803 if (inp == NULL) {
809 inp6 = (struct in6pcb *)inp;
813 if ((inp->sctp_flags & SCTP_PCB_FLAGS_CONNECTED) &&
858 if (inp->control) {
860 m_freem(inp->control);
861 inp->control = NULL;
863 inp->control = control;
866 if ((inp->pkt) &&
867 (inp->pkt->m_flags & M_PKTHDR)) {
876 inp->pkt->m_pkthdr.len += c_len;
879 if (inp->pkt) {
880 inp->pkt_last->m_next = m;
881 inp->pkt_last = m;
883 inp->pkt_last = inp->pkt = m;
894 ret = sctp_output(inp, inp->pkt , nam, inp->control, l, 0);
895 inp->pkt = NULL;
896 inp->control = NULL;
918 struct sctp_inpcb *inp;
927 inp = (struct sctp_inpcb *)so->so_pcb;
928 if (inp == 0) {
932 SCTP_ASOC_CREATE_LOCK(inp);
933 SCTP_INP_RLOCK(inp);
934 if ((inp->sctp_flags & SCTP_PCB_FLAGS_UNBOUND) ==
937 SCTP_INP_RUNLOCK(inp);
940 SCTP_ASOC_CREATE_UNLOCK(inp);
944 SCTP_INP_RLOCK(inp);
947 if ((inp->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) &&
948 (inp->sctp_flags & SCTP_PCB_FLAGS_CONNECTED)) {
950 SCTP_INP_RUNLOCK(inp);
951 SCTP_ASOC_CREATE_UNLOCK(inp);
968 SCTP_INP_RUNLOCK(inp);
969 SCTP_ASOC_CREATE_UNLOCK(inp);
973 SCTP_INP_RUNLOCK(inp);
974 SCTP_ASOC_CREATE_UNLOCK(inp);
986 SCTP_INP_RUNLOCK(inp);
987 SCTP_ASOC_CREATE_UNLOCK(inp);
994 if (inp->sctp_flags & SCTP_PCB_FLAGS_CONNECTED) {
995 stcb = LIST_FIRST(&inp->sctp_asoc_list);
999 SCTP_INP_RUNLOCK(inp);
1001 SCTP_INP_RUNLOCK(inp);
1002 SCTP_INP_WLOCK(inp);
1003 SCTP_INP_INCR_REF(inp);
1004 SCTP_INP_WUNLOCK(inp);
1005 stcb = sctp_findassociation_ep_addr(&inp, nam, NULL, NULL, NULL);
1007 SCTP_INP_WLOCK(inp);
1008 SCTP_INP_DECR_REF(inp);
1009 SCTP_INP_WUNLOCK(inp);
1015 SCTP_ASOC_CREATE_UNLOCK(inp);
1020 stcb = sctp_aloc_assoc(inp, nam, 1, &error, 0);
1021 SCTP_ASOC_CREATE_UNLOCK(inp);
1033 sctp_send_initiate(inp, stcb);
1050 struct sctp_inpcb *inp;
1060 inp = (struct sctp_inpcb *)so->so_pcb;
1061 if (inp == NULL) {
1065 sin6->sin6_port = inp->sctp_lport;
1066 if (inp->sctp_flags & SCTP_PCB_FLAGS_BOUNDALL) {
1068 if (inp->sctp_flags & SCTP_PCB_FLAGS_CONNECTED) {
1074 stcb = LIST_FIRST(&inp->sctp_asoc_list);
1092 inp, stcb, &net->ro, net, 0);
1103 LIST_FOREACH(laddr, &inp->sctp_addr_list, sctp_nxt_addr) {
1129 struct sctp_inpcb *inp;
1135 inp = (struct sctp_inpcb *)so->so_pcb;
1136 if ((inp->sctp_flags & SCTP_PCB_FLAGS_CONNECTED) == 0) {
1145 inp = (struct sctp_inpcb *)so->so_pcb;
1146 if (inp == NULL) {
1149 stcb = LIST_FIRST(&inp->sctp_asoc_list);