Author: kevans
Date: Mon Apr  8 17:59:42 2019
New Revision: 346036
URL: https://svnweb.freebsd.org/changeset/base/346036

Log:
  MFC r343255: awg: fix soft reset failure with no link
  
  U-Boot will leave the ephy reset de-asserted and the MAC soft reset will
  fail on these boards with internal PHY and no link established. Toggle reset
  again before proceeding to attach/init.

Modified:
  stable/12/sys/arm/allwinner/if_awg.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/arm/allwinner/if_awg.c
==============================================================================
--- stable/12/sys/arm/allwinner/if_awg.c        Mon Apr  8 17:55:04 2019        
(r346035)
+++ stable/12/sys/arm/allwinner/if_awg.c        Mon Apr  8 17:59:42 2019        
(r346036)
@@ -1466,6 +1466,12 @@ awg_setup_extres(device_t dev)
                goto fail;
        }
        if (rst_ephy != NULL) {
+               /*
+                * The ephy reset is left de-asserted by U-Boot.  Assert it
+                * here to make sure that we're in a known good state going
+                * into the PHY reset.
+                */
+               hwreset_assert(rst_ephy);
                error = hwreset_deassert(rst_ephy);
                if (error != 0) {
                        device_printf(dev, "cannot de-assert ephy reset\n");


_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to