From f997df3164c53be1519ba87b769fc3a87a50fc34 Mon Sep 17 00:00:00 2001 From: Michael Tuexen Date: Sat, 4 Jun 2022 07:35:54 +0200 Subject: sctp: improve handling of sctp inpcb flags Use an atomic operation when the inp is not write locked. Reported by: syzbot+bf27083e9a3f8fde8b4d@syzkaller.appspotmail.com (cherry picked from commit a5c2009dd8ab562435fb7cc2ac0922668f9511a8) --- sys/netinet/sctp_pcb.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'sys/netinet/sctp_pcb.h') diff --git a/sys/netinet/sctp_pcb.h b/sys/netinet/sctp_pcb.h index 736b0f9d54e9..687ccf6a1c50 100644 --- a/sys/netinet/sctp_pcb.h +++ b/sys/netinet/sctp_pcb.h @@ -619,6 +619,9 @@ int sctp_swap_inpcb_for_listen(struct sctp_inpcb *inp); void sctp_clean_up_stream(struct sctp_tcb *stcb, struct sctp_readhead *rh); +void + sctp_pcb_add_flags(struct sctp_inpcb *, uint32_t); + /*- * Null in last arg inpcb indicate run on ALL ep's. Specific inp in last arg * indicates run on ONLY assoc's of the specified endpoint. -- cgit v1.2.3