From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 2263426CE32; Mon, 13 Apr 2026 16:29:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776097785; cv=none; b=bDRrAn5yb10z9pQAswQjyKr92F/1bEcw8WKqaBAS25lZ2GmhL5H+iLM/Bqe77coC7I9n/q9/0WpgyBqrKWRl7O3afqQlkhChbBeso2cbjx2ZCasIrNfk8NqxiylwQ2hRACYFMZX07gMrtUUG7zDZW6ZE7cMz1AUgFMhp0hHob4g= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776097785; c=relaxed/simple; bh=WukobODCcQuDw/UlPH84T90czZ5RaK+QYaRibIYuGbE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=MN2Sxv7QcReQq7udlrqLJ1r8baAUzFVb0sdnFHNaYrqDWCrk6jMPxT7657Aeqv/c70sf41WXnuStrAlERihSnqmxmM/KBws1fKwaVeFzJVqcuUIF39JURw8piFGU/0okdhUre3HymlR9NGYZM55avhebKqfbWSg9IFNaWkoYf+k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=sWyNr1gO; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="sWyNr1gO" Received: by smtp.kernel.org (Postfix) with ESMTPSA id ACBA5C2BCAF; Mon, 13 Apr 2026 16:29:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1776097785; bh=WukobODCcQuDw/UlPH84T90czZ5RaK+QYaRibIYuGbE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=sWyNr1gOJ1vs/U6afoGTP9tG7vF4oOMTWciDcCpObbHW5d+Mt3IoQnOclACNAAEHs f+LE9o+SFPlvEID7BglmwP89QyXn3A7vhMHKM+ZPD27mEbRYkDMKplliUFkRmO6h7p U2BwdJv5P8biHKegdcrnfcIiXDTOgtZNMPQ6/oP4= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Kohei Enju , Simon Horman , Paul Menzel , Avigail Dahan , Tony Nguyen , Sasha Levin Subject: [PATCH 5.15 272/570] igc: fix missing update of skb->tail in igc_xmit_frame() Date: Mon, 13 Apr 2026 17:56:43 +0200 Message-ID: <20260413155840.671872055@linuxfoundation.org> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260413155830.386096114@linuxfoundation.org> References: <20260413155830.386096114@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 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Kohei Enju [ Upstream commit 0ffba246652faf4a36aedc66059c2f94e4c83ea5 ] igc_xmit_frame() misses updating skb->tail when the packet size is shorter than the minimum one. Use skb_put_padto() in alignment with other Intel Ethernet drivers. Fixes: 0507ef8a0372 ("igc: Add transmit and receive fastpath and interrupt handlers") Signed-off-by: Kohei Enju Reviewed-by: Simon Horman Reviewed-by: Paul Menzel Tested-by: Avigail Dahan Signed-off-by: Tony Nguyen Signed-off-by: Sasha Levin --- drivers/net/ethernet/intel/igc/igc_main.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/intel/igc/igc_main.c b/drivers/net/ethernet/intel/igc/igc_main.c index 6a9ad4231b0c2..d2825170c1e1d 100644 --- a/drivers/net/ethernet/intel/igc/igc_main.c +++ b/drivers/net/ethernet/intel/igc/igc_main.c @@ -1666,11 +1666,8 @@ static netdev_tx_t igc_xmit_frame(struct sk_buff *skb, /* The minimum packet size with TCTL.PSP set is 17 so pad the skb * in order to meet this minimum size requirement. */ - if (skb->len < 17) { - if (skb_padto(skb, 17)) - return NETDEV_TX_OK; - skb->len = 17; - } + if (skb_put_padto(skb, 17)) + return NETDEV_TX_OK; return igc_xmit_frame_ring(skb, igc_tx_queue_mapping(adapter, skb)); } -- 2.51.0