Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8c97ea87 authored by Alok Chauhan's avatar Alok Chauhan
Browse files

msm: emac: move init adapter to post phase2 clocks enablement



EMAC driver maintain some of the field in its internal structure
after reading it from EMAC HW core.  So move init adapter to
post enablement of phase2 clocks to avoid any unclock access.

Change-Id: I8f5a226197f6227fccb9fc7eb6fb6a55dd0d4f85
Signed-off-by: default avatarAlok Chauhan <alokc@codeaurora.org>
parent cdf7d521
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -3093,8 +3093,6 @@ static int emac_probe(struct platform_device *pdev)
	if (ret)
		goto err_clk_init;

	hw_ver = emac_reg_r32(hw, EMAC, EMAC_CORE_HW_VERSION);

	netdev->watchdog_timeo = EMAC_WATCHDOG_TIME;
	netdev->irq = adpt->irq[0].irq;

@@ -3114,9 +3112,6 @@ static int emac_probe(struct platform_device *pdev)

	emac_set_ethtool_ops(netdev);

	/* init adapter */
	emac_init_adapter(adpt);

	/* init internal phy */
	ret = emac_phy_config_internal(pdev, adpt);
	if (ret)
@@ -3127,6 +3122,11 @@ static int emac_probe(struct platform_device *pdev)
	if (ret)
		goto err_clk_init;

	hw_ver = emac_reg_r32(hw, EMAC, EMAC_CORE_HW_VERSION);

	/* init adapter */
	emac_init_adapter(adpt);

	/* Configure MDIO lines */
	ret = adpt->gpio_on(adpt, true, true);
	if (ret)