mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2026-03-21 12:19:30 -04:00
Bc-bocun Chen of MediaTek has discovered a memory leak in the error path in our downstream patch for mtk_eth_soc which adds support for the 10G PCS and PHY paths of the MT7988 SoC. Fix this by freeing the at this point already allocated netdev resources before returning the error. Fixes:4cb6bd9a6d("mediatek: switch to pending XFI 10G Ethernet drivers") Reported-by: Bc-bocun Chen <bc-bocun.chen@mediatek.com> Signed-off-by: Daniel Golle <daniel@makrotopia.org> (cherry picked from commit4d71c767c4)