instead of discrete function pointers, and extend this to include
a "reset" entry point. Make sure any PHY-specific reset routine is
always used, and provide one for the LXT-970 which disables MII
interrupts (as is done for a few other PHYs we have drivers for).
mii_softc (generic phy goo), and just switch all of the PHY drivers
(except tlphy, which really does have special stuff) to use an mii_softc
instead of a private one.
current ifmedia_entry, not from the user-supplied media word. The
user supplied media word may not necessarily match e.g. instance (if
the parent MAC driver is intentionally ignoring instance if its expecting
multiple PHYs with non-overlapping media, e.g. TI ThunderLAN) the media
word we are actually switching to.
Since PHY drivers use `instance' to determine if they should isolate
themselves, the ThunderLAN PHY was sometimes being incorrectly isolated
when in fact the user attempted to select that PHY (for e.g. BNC operation).
properly! Work around this by determing current active media by taking
the highest-order common bit of our advertised capabilites and the link
partner's.
If the link partner doens't do autonegotiation, then parallel detection will
pick up the media type, which will never be full-duplex, so reading the PAR
is ok in this case.
Bug pointed out by Matthias Drochner, work-around inspired by reading
the dp83840 manual, section 3.9 (IEEE 802.3u auto-negotiation).
adapters, and provide media-selections and status to the parent.
This includes drivers for the Thunderland integrated PHY, and
National Semiconductor's DP83840A.
Note: The interface betweeen network controller and mii is not complete yet,
and will need some minors tweaks to support media auto-selection.