* For the shutdown and shutdown-ack, we do not keep one around on the * control queue. This means we must generate a new one and call the general * chunk output routine, AFTER having done threshold management. * It is assumed that net is non-NULL. */
| 1298 | * It is assumed that net is non-NULL. |
| 1299 | */ |
| 1300 | int |
| 1301 | sctp_shutdown_timer(struct sctp_inpcb *inp, struct sctp_tcb *stcb, |
| 1302 | struct sctp_nets *net) |
| 1303 | { |
| 1304 | struct sctp_nets *alt; |
| 1305 | |
| 1306 | /* first threshold management */ |
| 1307 | if (sctp_threshold_management(inp, stcb, net, stcb->asoc.max_send_times)) { |
| 1308 | /* Assoc is over */ |
| 1309 | return (1); |
| 1310 | } |
| 1311 | sctp_backoff_on_timeout(stcb, net, 1, 0, 0); |
| 1312 | /* second select an alternative */ |
| 1313 | alt = sctp_find_alternate_net(stcb, net, 0); |
| 1314 | |
| 1315 | /* third generate a shutdown into the queue for out net */ |
| 1316 | sctp_send_shutdown(stcb, alt); |
| 1317 | |
| 1318 | /* fourth restart timer */ |
| 1319 | sctp_timer_start(SCTP_TIMER_TYPE_SHUTDOWN, inp, stcb, alt); |
| 1320 | return (0); |
| 1321 | } |
| 1322 | |
| 1323 | int |
| 1324 | sctp_shutdownack_timer(struct sctp_inpcb *inp, struct sctp_tcb *stcb, |
no test coverage detected