[PATCH 5.10.y-cip 54/61] ravb: Optimize ravb_emac_init_gbeth function


Lad Prabhakar
 

From: Biju Das <biju.das.jz@...>

commit 030634f37db996f5b8cc82f43ed6e3b6b009d56c upstream.

Optimize CXR31 register initialization on ravb_emac_init_gbeth
function.

Signed-off-by: Biju Das <biju.das.jz@...>
Suggested-by: Sergey Shtylyov <s.shtylyov@...>
Reviewed-by: Sergey Shtylyov <s.shtylyov@...>
Signed-off-by: Jakub Kicinski <kuba@...>
Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@...>
---
drivers/net/ethernet/renesas/ravb_main.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/renesas/ravb_main.c b/drivers/net/ethernet/renesas/ravb_main.c
index ab57b72ea1cc..9de47566feef 100644
--- a/drivers/net/ethernet/renesas/ravb_main.c
+++ b/drivers/net/ethernet/renesas/ravb_main.c
@@ -536,8 +536,7 @@ static void ravb_emac_init_gbeth(struct net_device *ndev)
/* E-MAC interrupt enable register */
ravb_write(ndev, ECSIPR_ICDIP, ECSIPR);

- ravb_modify(ndev, CXR31, CXR31_SEL_LINK1, 0);
- ravb_modify(ndev, CXR31, CXR31_SEL_LINK0, CXR31_SEL_LINK0);
+ ravb_modify(ndev, CXR31, CXR31_SEL_LINK0 | CXR31_SEL_LINK1, CXR31_SEL_LINK0);
}

static void ravb_emac_init_rcar(struct net_device *ndev)
--
2.17.1

Join cip-dev@lists.cip-project.org to automatically receive all group messages.