Re: Updated ASIX.LIB with improved link recovery for Dynamic C 9

"Tom Collins tom-lnEA/wrDJtNWk0Htik3J/[email protected] [rabbit-semi]" <[email protected]> Wed, 25 May 2016 14:02:28 -0700
Newsgroups gmane.comp.hardware.rabbit-semiconductor
Message-ID <[email protected]>
I've now ported the ASIX fix to Dynamic C 10.  If you're using RCM42xx or RCM43xx boards, I would highly recommend using this version of ASIX.LIB instead of what shipped with Dynamic C 10.72 and 10.72A.  Barring any new discoveries, this will ship out in Dynamic C 10.72B (currently unscheduled).

https://github.com/digidotcom/DCRabbit_10/commit/740114c8e0c1f988f121fccd50ff0079da6634b2

-Tom


On May 20, 2016, at 1:16 PM, Tom Collins tom-lnEA/wrDJtNWk0Htik3J/[email protected] [rabbit-semi] wrote:

> 
> I believe I've finally resolved the multiple link recovery errors people have seen with ASIX.LIB in Dynamic C 9.  I will be porting my changes to Dynamic C 10 soon, but would appreciate hearing feedback from DC 9 users.
> 
> You can see the changes here, and download just ASIX.LIB if you want to do any testing:
> https://github.com/digidotcom/DCRabbit_9/commit/16126a371635a7c70b0587958e0873ee05cfca6b
> 
> The gist of the fix is as follows:
> 
> The ASIX chip has a PHY bug that requires resetting the PHY to re-initiate link recovery.  The ASIX library in Dynamic C would check link every two seconds, and if link was down it would power the PHY off, wait two seconds, and power it back on.
> 
> The problem is that it would check link again after just two seconds and repeat the cycle.  There are likely many situations where the PHY would require more than 2 seconds to negotiate a link.
> 
> So the updated code adds a third state to the link recovery process where it skips the link checks for some period of time (currently 8 seconds) after the PHY has been turned back on.  It also configures the driver to be in that state at startup, to avoid power cycling the PHY immediately after startup.
> 
> Complicating matters is that there were various patches to DC 9 that broke the link recovery behavior in different ways, such that it would work for some but not others.  In addition, I didn't clearly follow commits in Digi's internal revision control system, and reverted a bug-fixing change that I mistook to be an unintended code change during a wider documentation/code cleanup.
> 
> One customer has tested this version of ASIX.LIB and it's worked in all of their link-recovery scenarios.  Please let me know if there are situations where it fails for you so I can re-review the functionality.  I'll make a followup announcement once I've ported the changes to Dynamic C 10.
> 
> -Tom
> 
>  
> 
>