net: stmmac: simplify the return dwmac5_rxp_disable()

Simplify the return expression.

Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Zheng Yongjun 2020-12-09 17:23:25 +08:00 committed by David S. Miller
parent f75e594458
commit 6f2d5cf975

View File

@ -305,17 +305,13 @@ int dwmac5_safety_feat_dump(struct stmmac_safety_stats *stats,
static int dwmac5_rxp_disable(void __iomem *ioaddr)
{
u32 val;
int ret;
val = readl(ioaddr + MTL_OPERATION_MODE);
val &= ~MTL_FRPE;
writel(val, ioaddr + MTL_OPERATION_MODE);
ret = readl_poll_timeout(ioaddr + MTL_RXP_CONTROL_STATUS, val,
return readl_poll_timeout(ioaddr + MTL_RXP_CONTROL_STATUS, val,
val & RXPI, 1, 10000);
if (ret)
return ret;
return 0;
}
static void dwmac5_rxp_enable(void __iomem *ioaddr)