[ Sasha's backport helper bot ]
Hi,
✅ All tests passed successfully. No issues detected. No action required from the submitter.
The upstream commit SHA1 provided is correct: 10206302af856791fbcc27a33ed3c3eb09b2793d
WARNING: Author mismatch between patch and upstream commit: Backport author: jianqi.ren.cn@windriver.com Commit author: Eric Dumazetedumazet@google.com
Status in newer kernel trees: 6.14.y | Present (different SHA1: d3d7675d7762) 6.12.y | Present (different SHA1: e5178bfc55b3) 6.6.y | Not found
Note: The patch differs from the upstream commit: --- 1: 10206302af856 ! 1: 0ac13fbad61fe sctp: add mutual exclusion in proc_sctp_do_udp_port() @@ Metadata ## Commit message ## sctp: add mutual exclusion in proc_sctp_do_udp_port()
+ [ Upstream commit 10206302af856791fbcc27a33ed3c3eb09b2793d ] + We must serialize calls to sctp_udp_sock_stop() and sctp_udp_sock_start() or risk a crash as syzbot reported:
@@ Commit message Acked-by: Xin Long lucien.xin@gmail.com Link: https://patch.msgid.link/20250331091532.224982-1-edumazet@google.com Signed-off-by: Jakub Kicinski kuba@kernel.org + [Minor conflict resolved due to code context change.] + Signed-off-by: Jianqi Ren jianqi.ren.cn@windriver.com + Signed-off-by: He Zhe zhe.he@windriver.com
## net/sctp/sysctl.c ## -@@ net/sctp/sysctl.c: static int proc_sctp_do_auth(const struct ctl_table *ctl, int write, +@@ net/sctp/sysctl.c: static int proc_sctp_do_auth(struct ctl_table *ctl, int write, return ret; }
+static DEFINE_MUTEX(sctp_sysctl_mutex); + - static int proc_sctp_do_udp_port(const struct ctl_table *ctl, int write, + static int proc_sctp_do_udp_port(struct ctl_table *ctl, int write, void *buffer, size_t *lenp, loff_t *ppos) { -@@ net/sctp/sysctl.c: static int proc_sctp_do_udp_port(const struct ctl_table *ctl, int write, +@@ net/sctp/sysctl.c: static int proc_sctp_do_udp_port(struct ctl_table *ctl, int write, if (new_value > max || new_value < min) return -EINVAL;
@@ net/sctp/sysctl.c: static int proc_sctp_do_udp_port(const struct ctl_table *ctl, net->sctp.udp_port = new_value; sctp_udp_sock_stop(net); if (new_value) { -@@ net/sctp/sysctl.c: static int proc_sctp_do_udp_port(const struct ctl_table *ctl, int write, +@@ net/sctp/sysctl.c: static int proc_sctp_do_udp_port(struct ctl_table *ctl, int write, lock_sock(sk); sctp_sk(sk)->udp_port = htons(net->sctp.udp_port); release_sock(sk); ---
Results of testing on various branches:
| Branch | Patch Apply | Build Test | |---------------------------|-------------|------------| | stable/linux-6.1.y | Success | Success |