MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sctp_timer_validation

Function sctp_timer_validation

freebsd/netinet/sctp_output.c:9906–9929  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9904}
9905
9906static void
9907sctp_timer_validation(struct sctp_inpcb *inp,
9908 struct sctp_tcb *stcb,
9909 struct sctp_association *asoc)
9910{
9911 struct sctp_nets *net;
9912
9913 /* Validate that a timer is running somewhere */
9914 TAILQ_FOREACH(net, &asoc->nets, sctp_next) {
9915 if (SCTP_OS_TIMER_PENDING(&net->rxt_timer.timer)) {
9916 /* Here is a timer */
9917 return;
9918 }
9919 }
9920 SCTP_TCB_LOCK_ASSERT(stcb);
9921 /* Gak, we did not have a timer somewhere */
9922 SCTPDBG(SCTP_DEBUG_OUTPUT3, "Deadlock avoided starting timer on a dest at retran\n");
9923 if (asoc->alternate) {
9924 sctp_timer_start(SCTP_TIMER_TYPE_SEND, inp, stcb, asoc->alternate);
9925 } else {
9926 sctp_timer_start(SCTP_TIMER_TYPE_SEND, inp, stcb, asoc->primary_destination);
9927 }
9928 return;
9929}
9930
9931void
9932sctp_chunk_output(struct sctp_inpcb *inp,

Callers 1

sctp_chunk_outputFunction · 0.85

Calls 1

sctp_timer_startFunction · 0.85

Tested by

no test coverage detected