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

Function sctp_delete_ifn

freebsd/netinet/sctp_pcb.c:282–304  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

280}
281
282static void
283sctp_delete_ifn(struct sctp_ifn *sctp_ifnp, int hold_addr_lock)
284{
285 struct sctp_ifn *found;
286
287 found = sctp_find_ifn(sctp_ifnp->ifn_p, sctp_ifnp->ifn_index);
288 if (found == NULL) {
289 /* Not in the list.. sorry */
290 return;
291 }
292 if (hold_addr_lock == 0) {
293 SCTP_IPI_ADDR_WLOCK();
294 } else {
295 SCTP_IPI_ADDR_WLOCK_ASSERT();
296 }
297 LIST_REMOVE(sctp_ifnp, next_bucket);
298 LIST_REMOVE(sctp_ifnp, next_ifn);
299 if (hold_addr_lock == 0) {
300 SCTP_IPI_ADDR_WUNLOCK();
301 }
302 /* Take away the reference, and possibly free it */
303 sctp_free_ifn(sctp_ifnp);
304}
305
306void
307sctp_mark_ifa_addr_down(uint32_t vrf_id, struct sockaddr *addr,

Callers 2

sctp_remove_ifa_from_ifnFunction · 0.85
sctp_add_addr_to_vrfFunction · 0.85

Calls 2

sctp_find_ifnFunction · 0.85
sctp_free_ifnFunction · 0.85

Tested by

no test coverage detected