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 246182EE262; Sun, 1 Mar 2026 02:05:49 +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=1772330749; cv=none; b=HMok06aVE0/bgi3hCMBNskjpMW5HrfJ+qswaibxapNLvG2469982FQ2X7xM1KA2Y4UnPNMRmBdQb4YqVuv2zKSgrRB+wG5w3AVjBEgIJNm6dwjQkF1RjWYOJPd06pUAYVDDwnuba5s8vcdCJ0r2oyucxVWx/s6iBeYvnPwahv/8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772330749; c=relaxed/simple; bh=KAoL1cx2EuRA7/IhGFw6mkGmsTeE2YWJNJJwGTPnKfs=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=J756BEfEnSS/BysOCGtPaxSTNykJJ1koo0LyqIJV/va7E9NmmHQ/cl8AmmQ9acgsbZQuBP78Nhi1ah8ItepVyIm+RA4NR7SVLqZLQQOwcoRJ99Iv4u+QW5azcDmk/4rnLRJjv8QMUpn0V7GbdUADqr1/mABNK1bim6D7VTxvPhc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=m2Xhzpi1; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="m2Xhzpi1" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 88D25C19421; Sun, 1 Mar 2026 02:05:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1772330749; bh=KAoL1cx2EuRA7/IhGFw6mkGmsTeE2YWJNJJwGTPnKfs=; h=From:To:Cc:Subject:Date:From; b=m2Xhzpi1CAJEZRtOXh0NyZ/UgSnI5ttuMyn0h1oFF9LE6bBC9k1RUO14rohleKBkH ERa5mIxDYj5aF+EONvIVZm22EdDcK1cpZUrX+ZGqvNgyb+Z2TUJW6OJKNXRfOF7iqZ ErJCrckA2OV6PuKE7wGz8+GkLFvaif/P8RNmv51KbIS9ZJj1/KWUVKrdVS0BjHvIX7 /8dsJvLlv89rS1BmMza4dFuFeGAWTRJRnvUkUhiEGWTlEGr+xyehV+P7MFr4rhhc+4 r0ejSe0bTuIYzvCozI/zFHWywkRz3XvQwTmY2M0zPjLW5uuLlnMI9CeqfEzKrzZJI5 bZcUNalITWzyg== From: Sasha Levin To: stable@vger.kernel.org, fourier.thomas@gmail.com Cc: Jakub Kicinski , netdev@vger.kernel.org Subject: FAILED: Patch "net: ethernet: ec_bhf: Fix dma_free_coherent() dma handle" failed to apply to 5.10-stable tree Date: Sat, 28 Feb 2026 21:05:47 -0500 Message-ID: <20260301020547.1734617-1-sashal@kernel.org> X-Mailer: git-send-email 2.51.0 Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Hint: ignore X-stable: review Content-Transfer-Encoding: 8bit The patch below does not apply to the 5.10-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 . Thanks, Sasha ------------------ original commit in Linus's tree ------------------ >From ffe68c3766997d82e9ccaf1cdbd47eba269c4aa2 Mon Sep 17 00:00:00 2001 From: Thomas Fourier Date: Fri, 13 Feb 2026 17:43:39 +0100 Subject: [PATCH] net: ethernet: ec_bhf: Fix dma_free_coherent() dma handle dma_free_coherent() in error path takes priv->rx_buf.alloc_len as the dma handle. This would lead to improper unmapping of the buffer. Change the dma handle to priv->rx_buf.alloc_phys. Fixes: 6af55ff52b02 ("Driver for Beckhoff CX5020 EtherCAT master module.") Cc: Signed-off-by: Thomas Fourier Link: https://patch.msgid.link/20260213164340.77272-2-fourier.thomas@gmail.com Signed-off-by: Jakub Kicinski --- drivers/net/ethernet/ec_bhf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ec_bhf.c b/drivers/net/ethernet/ec_bhf.c index 67275aa4f65b2..0c86cbb0313c3 100644 --- a/drivers/net/ethernet/ec_bhf.c +++ b/drivers/net/ethernet/ec_bhf.c @@ -423,7 +423,7 @@ static int ec_bhf_open(struct net_device *net_dev) error_rx_free: dma_free_coherent(dev, priv->rx_buf.alloc_len, priv->rx_buf.alloc, - priv->rx_buf.alloc_len); + priv->rx_buf.alloc_phys); out: return err; } -- 2.51.0