icsphy(4) for nfe(4) - better Microsoft Xbox support

Ed Schouten ed at fxq.nl
Tue Feb 6 21:12:57 UTC 2007


Hello,

When we (Rink and I) ported FreeBSD to the Xbox, Rink patched the kernel
to allow the nve(4) driver to attach properly. I recently removed the
dust from my Xbox and installed FreeBSD on it. This time I started using
the nfe(4) driver.

When compared to the nve(4) driver, the nfe(4) seems a lot faster (and
not as interrupt-hungry). I did have some issues with it, however. When
the machine boots, I often have to plug out/in the network cable before
I get a link. My switch, a HP2626, sometimes temporarily shuts down the
port with the message:

	FFI: port 9-Excessive CRC/alignment errors. See help.

Because the issues seemed more link-related, I tried looking at the phy
code. After booting my machine with bootverbose, it seems I had an
ICS1893 PHY, using the ukphy(4) driver. NetBSD has a driver for it,
called icsphy(4). I decided to port it to FreeBSD.

Porting was quite easy. Just smack the C file in the tree and edit it
until it compiles. I had some problems at first, because even with the
icsphy(4) driver I didn't get a link. I discovered that the BMSR
register kept returning BMSR_ISO, until I unplugged the cable. I added
MIIF_NOISOLATE to the mii_flags and voila: it works.

I can now boot my Xbox without plugging around all the time. The
CRC/alignment errors have also vanished.

	http://g-rave.nl/junk/freebsd-icsphy.diff

Yours,
-- 
 Ed Schouten <ed at fxq.nl>
 WWW: http://g-rave.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-net/attachments/20070206/7aed8101/attachment.pgp


More information about the freebsd-net mailing list