Changelog: https://cdn.kernel.org/pub/linux/kernel/v5.x/ChangeLog-5.15.132 Removed upstreamed: bcm53xx/patches-5.15/037-v6.6-0006-ARM-dts-BCM53573-Add-cells-sizes-to-PCIe-node.patch[1] bcm53xx/patches-5.15/037-v6.6-0007-ARM-dts-BCM53573-Use-updated-spi-gpio-binding-proper.patch[2] bcm53xx/patches-5.15/037-v6.6-0008-ARM-dts-BCM5301X-Extend-RAM-to-full-256MB-for-Linksy.patch[3] All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.132&id=b35f3ca1877e024887df205ede952863d65dad36 2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.132&id=2840d9b9c8750be270fb1153ccd5b983cbb5d592 3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.132&id=f086e859ddc252c32f0438edff241859c0f022ce Build system: x86_64 Build-tested: ramips/tplink_archer-a6-v3 Run-tested: ramips/tplink_archer-a6-v3 Signed-off-by: John Audia <therealgraysky@proton.me>
36 lines
1.2 KiB
Diff
36 lines
1.2 KiB
Diff
From 8110437e59616293228cd781c486d8495a61e36a Mon Sep 17 00:00:00 2001
|
|
From: Yan Cangang <nalanzeyu@gmail.com>
|
|
Date: Sun, 20 Nov 2022 13:52:58 +0800
|
|
Subject: [PATCH] net: ethernet: mtk_eth_soc: fix resource leak in error path
|
|
|
|
In mtk_probe(), when mtk_ppe_init() or mtk_eth_offload_init() failed,
|
|
mtk_mdio_cleanup() isn't called. Fix it.
|
|
|
|
Fixes: ba37b7caf1ed ("net: ethernet: mtk_eth_soc: add support for initializing the PPE")
|
|
Fixes: 502e84e2382d ("net: ethernet: mtk_eth_soc: add flow offloading support")
|
|
Signed-off-by: Yan Cangang <nalanzeyu@gmail.com>
|
|
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
|
|
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
|
---
|
|
drivers/net/ethernet/mediatek/mtk_eth_soc.c | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
|
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
|
|
@@ -4090,13 +4090,13 @@ static int mtk_probe(struct platform_dev
|
|
eth->soc->offload_version, i);
|
|
if (!eth->ppe[i]) {
|
|
err = -ENOMEM;
|
|
- goto err_free_dev;
|
|
+ goto err_deinit_mdio;
|
|
}
|
|
}
|
|
|
|
err = mtk_eth_offload_init(eth);
|
|
if (err)
|
|
- goto err_free_dev;
|
|
+ goto err_deinit_mdio;
|
|
}
|
|
|
|
for (i = 0; i < MTK_MAX_DEVS; i++) {
|