]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net:fec: Add fec_enet_deinit()
authorXiaolei Wang <xiaolei.wang@windriver.com>
Fri, 24 May 2024 05:05:28 +0000 (13:05 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Jun 2024 11:39:50 +0000 (13:39 +0200)
commitb02c55e47e9419bf770d3356a66761284f0369cf
treec07903c07b2c222029a2a0d061b4bc1659be205b
parent11e8ecc5b86037fec43d07b1c162e233e131b1d9
net:fec: Add fec_enet_deinit()

[ Upstream commit bf0497f53c8535f99b72041529d3f7708a6e2c0d ]

When fec_probe() fails or fec_drv_remove() needs to release the
fec queue and remove a NAPI context, therefore add a function
corresponding to fec_enet_init() and call fec_enet_deinit() which
does the opposite to release memory and remove a NAPI context.

Fixes: 59d0f7465644 ("net: fec: init multi queue date structure")
Signed-off-by: Xiaolei Wang <xiaolei.wang@windriver.com>
Reviewed-by: Wei Fang <wei.fang@nxp.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20240524050528.4115581-1-xiaolei.wang@windriver.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/freescale/fec_main.c