[PATCH -next] phy: cadence: simplify the return expression of cdns_torrent_phy_configure_multilink()

From: Zheng Yongjun
Date: Thu Dec 10 2020 - 08:54:17 EST


Simplify the return expression.

Signed-off-by: Zheng Yongjun <zhengyongjun3@xxxxxxxxxx>
---
drivers/phy/cadence/phy-cadence-torrent.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/phy/cadence/phy-cadence-torrent.c b/drivers/phy/cadence/phy-cadence-torrent.c
index f310e15d94cb..2c60ac58f207 100644
--- a/drivers/phy/cadence/phy-cadence-torrent.c
+++ b/drivers/phy/cadence/phy-cadence-torrent.c
@@ -1939,7 +1939,7 @@ int cdns_torrent_phy_configure_multilink(struct cdns_torrent_phy *cdns_phy)
struct cdns_torrent_vals *link_cmn_vals, *xcvr_diag_vals;
enum cdns_torrent_phy_type phy_t1, phy_t2, tmp_phy_type;
struct cdns_torrent_vals *pcs_cmn_vals;
- int i, j, node, mlane, num_lanes, ret;
+ int i, j, node, mlane, num_lanes;
struct cdns_reg_pairs *reg_pairs;
enum cdns_torrent_ssc_mode ssc;
struct regmap *regmap;
@@ -2064,11 +2064,7 @@ int cdns_torrent_phy_configure_multilink(struct cdns_torrent_phy *cdns_phy)
}

/* Take the PHY out of reset */
- ret = reset_control_deassert(cdns_phy->phy_rst);
- if (ret)
- return ret;
-
- return 0;
+ return reset_control_deassert(cdns_phy->phy_rst);
}

static int cdns_torrent_phy_probe(struct platform_device *pdev)
--
2.22.0