From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796388342; b=si1usio6dWldKdOynsSIPvGHlbXI+ul5ldyMGdsg2FbY+aYfWZhOmh4W4raF4+fj8k3Z jQYAhkL61JBfcz41qcjvQd5lm/6QWGB7DebRXN2pZnY24DnSpZeVvQNpvjxv1qccLb2x5 h9u6NbYihtWDC5kBObxEzdk/zlYTuCNcrNaSuJ20FHsjEFq4B+RvT/WFNKcxbuADUS/dC +HIC5jT8deu0Caug71sot+zxLXSna4D97MY/4VkJP/Qh8wMoudNkE4Nm0NzWjyuYZp+PA fSw8uaZG1IIfX9dBTBj6hVZLwNXpA0TahL9gGnRrjS+Bxe0q8toizLIBoN13PY/l3yg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796388342; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=F2UtphIYvLsp/erAwB1co4taKpOUFDKNkLavzV1HM8M=; b=eWcKCGb46RGM/Vx2Eh/1jVc41dsMCS3mrHrECqhLQ/NI6T2E3CmofF86nKoJTXZrKUdW UxvDoAVCek0fkdvh+VoVjD6uBKs+Wkla+cVApuG/Zch9rSM9Mjog3LTDGVj7qe12r/Nvm JyRcQccP0+Jl7LXTx7y7Tc0DMI5eU3FT7hlwJ8cYCbmvH5OsYrrpuyNlmBkSQH/jmKsLv /MLTnPr9HgWziMLVdkiNfPj9DnApEtzy6dfQicCWUMsiUZdGiiVhMZkRo6yQcDcmJEmBJ fBWMvcaL2rYaNcm28NdOg6jd15Ky6vm9+zaf4Pr4GIEXmTGT7sYvDczctq9Ig0hEy2Q== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=u5f58dGs; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9AFA2606A339; Fri, 4 Dec 2026 12:45:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=u5f58dGs Received: by smtp.kernel.org (Postfix) with ESMTPSA id A4E201F00897; Fri, 4 Dec 2026 12:45:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796388342; bh=F2UtphIYvLsp/erAwB1co4taKpOUFDKNkLavzV1HM8M=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=u5f58dGsfpnFwIUPH2BB4JsEX20A9YYAo/aSWAcnMjJZnZVnndKrQKWl9uheK8wkK BaY/zscxG5SG4cOAdyzXxGJW+lT0TcaNZsIJh4AT5h8Twm0oPM1WRZDHiFBRDhso3A uY24JQ1dqcHwi+iAmNBIfPHy07Dm2lfODOU2LabM= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Sashiko , Tim Budding , Xin Long , Jakub Kicinski Subject: [PATCH 6.1 0540/1059] sctp: report the partially delivered MID in PARTIAL_DELIVERY_ABORTED Date: Fri, 4 Dec 2026 19:01:11 +0900 Message-ID: <20261204100658.192910061@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100643.980430235@linuxfoundation.org> References: <20261204100643.980430235@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: patches@lists.linux.dev List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Tim Budding commit 3097fba868019924e92b8786ebd473992565f015 upstream. When an I-FORWARD-TSN skips the message being partially delivered on a stream, sctp_intl_skip() passes the MID from the I-FORWARD-TSN to the PARTIAL_DELIVERY_ABORTED notification as pdapi_seq. That MID is the highest one skipped on the stream, so when more than one message is skipped, the notification names a later message instead of the one whose partial delivery was aborted. Report the MID being partially delivered, sin->mid_uo or sin->mid, instead. Reproduced on an unmodified kernel with the pdapi and pdapi_uo tests of the sctp_ifwdtsn.sh selftest added later in this series, which pass with this fix. Reproduction and fix done with AI assistance. Fixes: de60fe910543 ("sctp: implement handle_ftsn for sctp_stream_interleave") Reported-by: Sashiko Closes: https://lore.kernel.org/all/179293012867.3134.16497481637722705271@kernel.org/ Cc: stable@vger.kernel.org Signed-off-by: Tim Budding Acked-by: Xin Long Link: https://patch.msgid.link/20261105050225.49292-3-tim.budding@gmail.com Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- net/sctp/stream_interleave.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/net/sctp/stream_interleave.c +++ b/net/sctp/stream_interleave.c @@ -1251,7 +1251,7 @@ static void sctp_intl_skip(struct sctp_u if (flags & SCTP_FTSN_U_BIT) { if (sin->pd_mode_uo && !MID_lt(mid, sin->mid_uo)) { sin->pd_mode_uo = 0; - sctp_intl_stream_abort_pd(ulpq, sid, mid, 0x1, + sctp_intl_stream_abort_pd(ulpq, sid, sin->mid_uo, 0x1, GFP_ATOMIC); } sctp_intl_reasm_flush_mid(&ulpq->reasm_uo, sid, mid); @@ -1263,7 +1263,7 @@ static void sctp_intl_skip(struct sctp_u if (sin->pd_mode) { sin->pd_mode = 0; - sctp_intl_stream_abort_pd(ulpq, sid, mid, 0x0, GFP_ATOMIC); + sctp_intl_stream_abort_pd(ulpq, sid, sin->mid, 0x0, GFP_ATOMIC); } sctp_intl_reasm_flush_mid(&ulpq->reasm, sid, mid);