From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AAFA236212F; Thu, 20 Aug 2026 15:24:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787239469; cv=none; b=n/r1236LZmvwBEx6YEDJ08cizFzCC6XR8YUp9f6F0dd74o237xTYlPDZaHi9yEbHYI5ZgK6ost98hi0Ifo9X1fx0yEpDGd66uA3i7rpGAZs003lqX0J+eno+dpNL3JIsDXV4g+NtFPwZjO+bhZZ9DhUHTrfmvA3eJ/hsXvVxrMU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787239469; c=relaxed/simple; bh=V0Vor1cjcPGyjFfUaoZyjPjmxfEepoOKnIVCSwIVF0E=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=TyQAY5MjOiJNBVgjyOpV9xacO7dsNRCVNxT9ZrpI9w3Zf2kCwYgoO/HB4GdyuuLkXFP7qb9uMFBqVau45zZilnzcWUXEtL1flGdekan+Yd6KRfDr7x2fmev2UeeZZcokq1GUPHc3pEtRawc2rK8aUJU1X97fybt/fYnhgvBqa6s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=dhC2Rk+K; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="dhC2Rk+K" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 113461F000E9; Thu, 20 Aug 2026 15:24:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1787239468; bh=vzXJK9LHx+SYGz5uczDjKbFmun08IhklvbHQ+0nNJqw=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=dhC2Rk+Kb2VZDHhRwm4dUMFYjv+x1WYjClxr8Oo4AfnUqNupt4vmZxK7WH2/SNX1/ /NmOuH8nY2DCfB5lRTi4LmCODt/b3BpAl4pyNVG6jzBnvsU+4BBQZAkRTDIVkf9sUo xPpewQSNGNwJXgxaulYPb6W/oN7uDjt8sMn0qOpY= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Gang Yan , "Matthieu Baerts (NGI0)" , Jakub Kicinski Subject: [PATCH 6.12 020/220] selftests: mptcp: join: mark tests with data corruption as failed Date: Thu, 20 Aug 2026 16:53:30 +0200 Message-ID: <20260820145224.113437378@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260820145223.480031205@linuxfoundation.org> References: <20260820145223.480031205@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.12-stable review patch. If anyone has any objections, please let me know. ------------------ From: Gang Yan commit ca318e7bbb7723f57bcd9e69a2873b5884435552 upstream. check_transfer() compares the input and output files byte-by-byte using `cmp -l "$in" "$out" | while read ...`. Because the while-loop body runs in a subshell (the script sets neither lastpipe nor pipefail), the fail_test call inside it -- which sets the global ret/last_test_failed -- and the `return 1` both act on the subshell, not on check_transfer(). check_transfer() thus always falls through to `return 0`, and any data corruption affecting only the payload (leaving the subflow/PM counters untouched) is silently reported as PASS. Fixes: 8117dac3e7c3 ("selftests: mptcp: add invert check in check_transfer") Cc: stable@vger.kernel.org Signed-off-by: Gang Yan Reviewed-by: Matthieu Baerts (NGI0) Signed-off-by: Matthieu Baerts (NGI0) Link: https://patch.msgid.link/20260803-net-mptcp-misc-fixes-7-2-rc6-v2-5-b8f496d71664@kernel.org Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- tools/testing/selftests/net/mptcp/mptcp_join.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh @@ -552,7 +552,7 @@ check_transfer() mv "$tmpfile" "$out" tmpfile="" fi - cmp -l "$in" "$out" | while read -r i a b; do + while read -r i a b; do local sum=$((0${a} + 0${b})) if [ $check_invert -eq 0 ] || [ $sum -ne $((0xff)) ]; then fail_test "$what does not match (in, out):" @@ -563,7 +563,7 @@ check_transfer() else print_info "$what has inverted byte at ${i}" fi - done + done < <(cmp -l "$in" "$out") return 0 }