Some bug fixes for Zynq Ethernet

Ian Lepore ian at FreeBSD.org
Mon Jul 14 21:11:13 UTC 2014


On Tue, 2014-06-24 at 12:44 -0700, Thomas Skibo wrote:
> Hello, all.
> 
> I have some bug fixes for the Zynq/Zedboard Ethernet driver that have 
> been laying around for a while and that I'm hoping to get committed. 
> The main bug is that the driver doesn't handle media speed changes 
> correctly so it can only connect to 1G switches.
> 
> To fix this bug, the driver needs to be able to change the frequency of 
> the ethernet core's reference clock.  Because I am trying to keep 
> if_cgem.c platform-independent, I've created a function called 
> cgem_set_ref_clk() that a platform can override with a platform-specific 
> function for changing the clock.  This should make it easier if the 
> Cadence GEM block shows up in other SoCs.
> 
> Where it is a bit ugly is that the driver doesn't know which of two 
> ethernet cores it controls so I created a device-tree property called 
> "ref-clock-num" so that the platform-specific code knows which reference 
> clock to change.  I am open to other ideas on how to do this.
> 
> Comments?
> 
> I have a few other minor fixes and enhancements that I'll put in a 
> different patch.
> 
> Thanks,
> 

Committed as r268633.  Sorry it took so long, $work got crazy last month
and I'm way behind.

BTW, the weak-reference function and need for ref-clock-num property are
fine for now... there's not much else we can do until we get a proper
device/soc-independent clock API that can read and handle the standard
clock=<...> properties in dts files.

-- Ian




More information about the freebsd-arm mailing list