]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Remove a hack requiring dtsec0 to always be enabled for mdio.
authorjhibbits <jhibbits@FreeBSD.org>
Fri, 21 Oct 2016 02:16:11 +0000 (02:16 +0000)
committerjhibbits <jhibbits@FreeBSD.org>
Fri, 21 Oct 2016 02:16:11 +0000 (02:16 +0000)
commita1f45cd59d7e4933f99ee1b030c9adc370eb70d3
tree3334a78d1923e3817ec9817ccf8811d2856f487a
parentb16902f0f9a3dd2bf00983ce8bb211f3a1aa477d
Remove a hack requiring dtsec0 to always be enabled for mdio.

Instead replace it with a different hack, that turns fman into a simplebus
subclass, and maps its children within its address space.

Since all PHY communication is done through dtsec0's mdio space, the FDT
contains a reference to the dtsec0 mdio handle in all nodes that need it.
Instead of using Freescale's implementation for MII access, use our own (copied
loosely from the eTSEC driver, and could possibly be merged eventually).  This
lets us access the registers directly rather than needing a full dtsec interface
just to access the registers.

Future directions will include turning fman into more of a simplebus, and not
mapping the region and playing games.  This will require changes to the dtsec
driver to make it a child of fman, and possibly other drivers as well.
sys/dev/dpaa/fman.c
sys/dev/dpaa/fman.h
sys/dev/dpaa/fman_fdt.c
sys/dev/dpaa/fman_mdio.c [new file with mode: 0644]
sys/dev/dpaa/if_dtsec.c
sys/dev/dpaa/if_dtsec.h
sys/dev/dpaa/if_dtsec_fdt.c
sys/powerpc/conf/dpaa/files.dpaa