net: stmmac: dwmac-meson8b: Fix signedness bug in probe
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 25 Sep 2019 10:58:22 +0000 (13:58 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Jan 2020 13:51:15 +0000 (14:51 +0100)
commit39c421cb2721d7bb4af3291e4b209b11bd1db4d6
tree644f01fd2924aec72bc4a2f3175e72ffea671768
parent9724794c961c89b177dfce860c5ad76c33457e97
net: stmmac: dwmac-meson8b: Fix signedness bug in probe

[ Upstream commit f10210517a2f37feea2edf85eb34c98977265c16 ]

The "dwmac->phy_mode" is an enum and in this context GCC treats it as
an unsigned int so the error handling is never triggered.

Fixes: 566e82516253 ("net: stmmac: add a glue driver for the Amlogic Meson 8b / GXBB DWMAC")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/stmicro/stmmac/dwmac-meson8b.c