]> git.baikalelectronics.ru Git - kernel.git/commit
net: ethernet: arc: Fix a potential memory leak if an optional regulator is deferred
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 18 Mar 2018 22:59:36 +0000 (23:59 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 20 Mar 2018 16:06:23 +0000 (12:06 -0400)
commitfe5c53c74f10c33d2c5be8691235ab882adcb952
tree397b53fe9c74e5bacde0e5a9030dbb70a80f6356
parent2351d4ed22b6321e1f57fc6b6b8abe2f78b6c164
net: ethernet: arc: Fix a potential memory leak if an optional regulator is deferred

If the optional regulator is deferred, we must release some resources.
They will be re-allocated when the probe function will be called again.

Fixes: 167e45e9ef60 ("ethernet: arc: Add support for Rockchip SoC layer device tree bindings")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/arc/emac_rockchip.c