net: bcmgenet: return correct value 'ret' from bcmgenet_power_down
authorYueHaibing <yuehaibing@huawei.com>
Thu, 8 Nov 2018 02:08:43 +0000 (02:08 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 28 Nov 2019 17:29:01 +0000 (18:29 +0100)
commit23fd22e304fe26c3ea0ebc47f7a8bf19b1eb858d
tree8ec90f145efc705270525530da7b110f22508bb7
parentf1f9cb4f6bc219fb572c2debc029f7d4600deb63
net: bcmgenet: return correct value 'ret' from bcmgenet_power_down

[ Upstream commit 0db55093b56618088b9a1d445eb6e43b311bea33 ]

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/net/ethernet/broadcom/genet/bcmgenet.c: In function 'bcmgenet_power_down':
drivers/net/ethernet/broadcom/genet/bcmgenet.c:1136:6: warning:
 variable 'ret' set but not used [-Wunused-but-set-variable]

bcmgenet_power_down should return 'ret' instead of 0.

Fixes: ca8cf341903f ("net: bcmgenet: propagate errors from bcmgenet_power_down")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/broadcom/genet/bcmgenet.c