Bug 136168 - [em] em driver initialization fails on Intel 5000PSL motherboard
Summary: [em] em driver initialization fails on Intel 5000PSL motherboard
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: Eric Joyner
Keywords: IntelNetworking
Depends on:
Reported: 2009-06-29 21:40 UTC by Stephen Sanders
Modified: 2018-05-28 19:41 UTC (History)
2 users (show)

See Also:

file.diff (5.74 KB, patch)
2009-06-29 21:40 UTC, Stephen Sanders
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stephen Sanders 2009-06-29 21:40:04 UTC
For roughly 1 in 30 reboot cycles, the em driver attempts to initialize the 82563EB PHY and the attempt fails.  The code looks ok but the chip returns a funny value.

Putting the hardware initialization routine in a loop in if_em.c fixes the issue.  (see attached patch).

I'm pretty sure that is will be a problem in all releases of FreeBSD 6.x-8.x.

Fix: Attached Patch.

Alternatively, check return code of e1000_init_hw in if_em.c:em_hardware_init().  If if fails, loop up to three times.  The loop should encompass e1000_reset_hw().

Patch attached with submission follows:
How-To-Repeat: Reboot a Intel 5000PSL based machine 30 plus times.   Look for "Hardware Initialization Failed" in the message log.  The em device may not appear in an ifconfig -a listing or the networking will not function.  Try "host www.cnn.com" as a quick check.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2009-06-29 21:47:00 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-net

Over to maintainer(s).
Comment 2 mburgett 2010-02-03 00:49:22 UTC
I am experiencing this error on the SuperMicro X8SIE-F motherboard on
8.0-Stable, as of about a week ago.   The patch also works for me,
but since I've only ever seen this on em0, never em1, I suspect there
is a timing component when the hardware is first accessed during boot.

It occurs far, far more frequently than 1 in 30 boots. (more like 1 in
3 or 1 in 2)

Mike Burgett
Comment 3 Andre Oppermann freebsd_committer 2010-08-23 18:51:04 UTC
Responsible Changed
From-To: freebsd-net->jfv

Over to maintainer.
Comment 4 Sean Bruno freebsd_committer 2015-07-25 22:47:26 UTC
(In reply to ssanders from comment #0)
This patch should be uneeded in 10.1 and 10.2r

Any chance after all these years your machines are still accessible and useable?
Comment 5 Mark Linimon freebsd_committer freebsd_triage 2015-11-12 07:44:06 UTC
Reassign to erj@ for triage.  To submitter: is this issue still relevant?
Comment 6 Eitan Adler freebsd_committer freebsd_triage 2018-05-28 19:41:44 UTC
batch change:

For bugs that match the following
-  Status Is In progress 
- Untouched since 2018-01-01.
- Affects Base System OR Documentation


Reset to open status.

I did a quick pass but if you are getting this email it might be worthwhile to double check to see if this bug ought to be closed.