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=1796229294; b=uNsD25SuCAEbVbl8GDbNCTbLyI+CvZxhTnQVoqFy0f2CvGCvrL0KvdA/WuBoVyHhsMDR Kave5q9C7dzOfhJQqiLKxszqFdmE+milwo02qRYRvOuv00ZOmRXwxUrID6n1ClfpWd2rC LVF0++os6N2L+mi0Y7Y++MjkStiPb+hHfBdjeZqfDyMpON6ZQGISEBQ6hnt4KFpFxYP5f sTT5aUAKLnxF6JuiGbrN4fhTS05LcZmD5eGYs+6wjBi1+2ejK9ui8i95zZwclxFw+MQ7U m14iR77a18ttbB9D/A6CrYvdaKrcPPDMPEsYZQ2onTGwT+sDrLHndQooTvnf/NmSyZg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796229294; h=Received:DKIM-Signature:Subject:To:Cc:From:Date:Message-ID: MIME-Version:Content-Type:Content-Transfer-Encoding; bh=+3gB+LfO/DiEuxo7SApTQ4mAWImDe7bs4JC2k4eqSjc=; b=rfQ2xOF67hKOhZNiIhb8qOEbUgzO5RNLtnq2t1H+AfnFXFbia0V5/Lp3wa6TrV7XDYZf Y47aHBZRAnEQQUJuvQzD95mzLGbNwe+aM4nZwh5el8umHVs4y6tEKoKCFtS2RTcL30yci H+0a6Qlex2LRcNID40M3bElb0JVfQuHtNYuJ+U+lg2Eu+9BRBnvm4E4h83roj8d+v3E01 NtjnQ1T+GAOpgI4lbCjUdfX1b0qPWOuZb4JdRzAYZi/BJKYXs9jvHAhU3rB0F0bXEZXND jmpUlP79EgSybkLborRYwdeh6pnw3aeLFLBp8kW3KaSWnbbELUaKY3vpUss6QlS6M6Q== 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=HYPmSGwU; 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 AC399606A31A for ; Wed, 2 Dec 2026 16:34:54 +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=HYPmSGwU Received: by smtp.kernel.org (Postfix) with ESMTPSA id C1D151F0089B; Wed, 2 Dec 2026 16:34:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796229294; bh=+3gB+LfO/DiEuxo7SApTQ4mAWImDe7bs4JC2k4eqSjc=; h=Subject:To:Cc:From:Date; b=HYPmSGwU31E0UA8txp7PO63oNtoqGkFQajPUV4s9kFsvQwk/XwIGWx5g3pBZQHSpD DVYfpsfwPfybiwaOnPToC4iDxFuDRcdAYbCXHLCRj+1BG8dNG1GXUIeNW+urwXZ/70 gHRFHiJdtwWTxjO+Sm3Z7k4wCXENpmlcccMj17Eo= Subject: FAILED: patch "[PATCH] net: stmmac: drop the rest of the frame when napi_build_skb()" failed to apply to 6.1-stable tree To: aiyengar1990@gmail.com,kuba@kernel.org,maxime.chevallier@bootlin.com Cc: From: Date: Wed, 02 Dec 2026 17:07:13 +0100 Message-ID: <2026120213-ocean-armchair-22c4@gregkh> X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.1-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.1.y git checkout FETCH_HEAD git cherry-pick -x ece404eac250fc4be7aa4cec82e8c248cca83c28 # git commit -s git send-email --to '' --in-reply-to '2026120213-ocean-armchair-22c4@gregkh' --subject-prefix 'PATCH 6.1.y' 'HEAD^..' Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From ece404eac250fc4be7aa4cec82e8c248cca83c28 Mon Sep 17 00:00:00 2001 From: Arun Iyengar Date: Fri, 13 Nov 2026 17:13:40 +0000 Subject: [PATCH] net: stmmac: drop the rest of the frame when napi_build_skb() fails If napi_build_skb() fails on the first buffer of a frame that spans several descriptors, stmmac_rx() drops that buffer but goes on with the next descriptor of the same frame as if a new frame started there. The rest of the frame is then passed up the stack as a frame of its own. A frame spans several descriptors when it does not fit in the RX buffers of one descriptor. Mark the frame as errored instead, so that its remaining descriptors are discarded like those of a frame with a receive error. The frame is counted once in rx_dropped and once against the NAPI budget. Found while working on the sun8i EMAC jumbo frame series, where frames over 2032 bytes span several descriptors. Tested on an Orange Pi Zero2 (dwmac-sun8i, MTU 4070), w/ jumbo series and error injection. Fixes: ec222003bd94 ("net: stmmac: Prepare to add Split Header support") Cc: stable@vger.kernel.org Signed-off-by: Arun Iyengar Reviewed-by: Maxime Chevallier Link: https://patch.msgid.link/20261113-stmmac-rx-skb-fail-v1-1-fcaae89f2d2c@gmail.com Signed-off-by: Jakub Kicinski diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index ee63f5ecf570..9a9c44aab2e4 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c @@ -6045,7 +6045,7 @@ static int stmmac_rx(struct stmmac_priv *priv, int limit, u32 queue) buf->page); buf->page = NULL; rx_dropped++; - count++; + error = 1; goto drain_data; } @@ -6081,7 +6081,7 @@ static int stmmac_rx(struct stmmac_priv *priv, int limit, u32 queue) if (likely(status & rx_not_ls)) goto read_again; if (!skb) - continue; + goto next; /* Got entire packet into SKB. Finish it. */