ethernet: sun: Free the coherent when failing in probing
authorZheyu Ma <zheyuma97@gmail.com>
Sat, 5 Mar 2022 14:55:04 +0000 (14:55 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 12:22:47 +0000 (14:22 +0200)
commitcd3121310e33a2584d7695206a656295d7d893d3
treeb3daba1a1792f0c4e35b17bcc6bff77bd5ba689c
parentafffb79a2dd520eae2659c848d0f62a5ce4edfcf
ethernet: sun: Free the coherent when failing in probing

[ Upstream commit bb77bd31c281f70ec77c9c4f584950a779e05cf8 ]

When the driver fails to register net device, it should free the DMA
region first, and then do other cleanup.

Signed-off-by: Zheyu Ma <zheyuma97@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/sun/sunhme.c