Question about GPIO bitbang MII

Juli Mallett jmallett at FreeBSD.org
Fri Oct 7 09:58:33 UTC 2011


On Thu, Oct 6, 2011 at 19:34, dave jones <s.dave.jones at gmail.com> wrote:
> Hi,
>
> Does FreeBSD have gpio bitbang api for MII? If not, any driver in tree using
> gpio-bitbang mii that I can refer to? Thanks.
> It seems like OpenBSD, NetBSD and Linux have added support to gpio bitbang mii,
> and it's useful for porting embedded devices.

FreeBSD has a GPIO API and MACs can use whatever mechanism they like
to attach MII (or similar, as in the case of devices like switches
that sort of use MDIO but aren't exactly like Ethernet PHYs on an MII
bus.)

Or do you not want to do this within a driver for a particular MAC,
but just make the MII bus available for poking and prodding to
userland, backed by GPIO?

Can you give an example of an OpenBSD driver that uses the API you're
talking about?  I've worked with some drivers for FreeBSD which have
used GPIO bit-banging to expose an MII bus, but adding the abstraction
of the GPIO layer hasn't typically been worthwhile for those as
they're an SoC with dedicated GPIO for networking devices or similar.

Thanks,
Juli.


More information about the freebsd-net mailing list