Bug 252359 - em(4) does not support 1G transport for intel I218-LM device=0x15a2
Summary: em(4) does not support 1G transport for intel I218-LM device=0x15a2
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Mark Linimon
Keywords: IntelNetworking
Depends on:
Reported: 2021-01-02 20:12 UTC by metaqwe
Modified: 2021-01-06 17:15 UTC (History)
1 user (show)

See Also:

dmesg for em0 (306 bytes, text/plain)
2021-01-02 20:12 UTC, metaqwe
no flags Details
ifconfig em0 (389 bytes, text/plain)
2021-01-02 20:12 UTC, metaqwe
no flags Details
pciconf -lv em0 (252 bytes, text/plain)
2021-01-02 20:13 UTC, metaqwe
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description metaqwe 2021-01-02 20:12:12 UTC
Created attachment 221204 [details]
dmesg for em0

em(4) in 13-CURRENT does not support 1000baseTX for Intel I218-LM.
Comment 1 metaqwe 2021-01-02 20:12:53 UTC
Created attachment 221205 [details]
ifconfig em0
Comment 2 metaqwe 2021-01-02 20:13:32 UTC
Created attachment 221206 [details]
pciconf -lv em0
Comment 3 metaqwe 2021-01-02 20:17:21 UTC
I see the same behavior if net/intel-em-kmod is used.
Comment 4 VVD 2021-01-03 04:10:49 UTC
Several stupid questions:
1. Did you tried different cables/switches? 1m patch cord and switch near this host.
2. Did you tried force set media "ifconfig em0 media 1000baseT mediaopt full-duplex"?
3. Did you tried different versions of the FreeBSD (10/11/12)?
Comment 5 metaqwe 2021-01-03 12:28:33 UTC
Thanks for your good troubleshooting questions.

1. I swapped 1m cables, and ports on the Cisco SG300 switch with no improvement. 
2. ifconfig em0 media 1000baseTX mediaopt full-duplex gives "no carrier"
3. I have had this issue for about 10 months running 13-CURRENT.  I reported it now because I moved the switch and boxes to another rack this weekend.  This gave me a chance to swap cables and ports on the switch.  I did not try downgrading to older RELEASES.  I did try net/intel-em-kmod.  pciconf -lv em0 shows device=0x15a2.
Comment 6 metaqwe 2021-01-03 12:33:23 UTC
Another FreeBSD box running 13-CURRENT connects to the same Cisco SG300 switch at 1G with the re(4) driver, so I do not think it is an iflib issue.
Comment 7 VVD 2021-01-03 12:38:26 UTC
(In reply to metaqwe from comment #5)
1. Do you have other switches for test?
3. Try this one LiveUSB image: https://download.freebsd.org/ftp/releases/ISO-IMAGES/12.2/FreeBSD-12.2-RELEASE-amd64-memstick.img.xz
Other versions you can find here: https://download.freebsd.org/ftp/releases/ISO-IMAGES/
Comment 8 metaqwe 2021-01-03 18:09:07 UTC
(in reply to VVD comment 7)

Where does I218-LM device=0x15a2 appear in the em(4) sources?  I looked and could find several references to I218-LM, but not a test for device=0x15a2.  Is it better to look in the 13-CURRENT source tree, or the source tree for net/intel-em-kmod?
Comment 9 VVD 2021-01-03 18:14:39 UTC
(In reply to metaqwe from comment #8)
$ grep -Ri 0x15a2 /usr/src/sys/dev/e1000/
/usr/src/sys/dev/e1000/e1000_hw.h:#define E1000_DEV_ID_PCH_I218_LM3             0x15A2 /* Wildcat Point PCH */
Comment 10 metaqwe 2021-01-03 21:58:13 UTC
(In reply to VVD from comment #7)

1. No 1000baseTX when connected to another cisco SG300 switch.  No 1000baseTX when connected to a telco access router.
2. I booted 12.1-RELEASE DVD and no 1000baseTX.
Comment 11 metaqwe 2021-01-03 21:59:02 UTC
(In reply to VVD from comment #9)

Thanks for this information.
Comment 12 VVD 2021-01-04 01:17:00 UTC
(In reply to metaqwe from comment #10)
1. Do you have other switches - not Cisco?
3. Other versions? 10/11?
4. 1000BASE-TX or 1000BASE-T?
Interfaces Supported 1000Base-T
5. Try these drivers too: https://downloadcenter.intel.com/download/29706/Intel-Ethernet-Product-Software-Release-Notes
Comment 13 metaqwe 2021-01-04 02:58:40 UTC
(In reply to VVD from comment #12)
Thanks for your comment.

1. Yes, as I mentioned the telco access router's 1G ports still connected as 100baseTX.
3. 12.1-RELEASE had the same failure as 13-CURRENT so why bother with old releases?  Am I missing your point?
4. The em(4) driver only gives 1000baseTX, not 1000baseT.  When I set ifconfig em0 media 1000baseT mediaopt full-duplex the response is "no carrier"
5. Thanks for pointing me to an Intel site to download a driver which might work.  

For more troubleshooting, I 

1. turned off all net.inet.xxxx settings in sysctl.conf with no change. 
2. turned off ipfw with no change in behavior for 1000baseTX
Comment 14 VVD 2021-01-04 03:09:13 UTC
(In reply to metaqwe from comment #13)
1000BaseTX or 100BaseTX or 1000BaseT???
1000BaseTX is not supported by this network controller.

3. There was some changes, for example: em+igb => em.
Comment 15 metaqwe 2021-01-04 03:20:22 UTC
(In reply to VVD from comment #14)
Thanks for this information.  Closely reading man 4 em, I see that problems are to be reported directly to freebsd@intel.com.  So did I make a mistake reporting to bugzilla.freebsd.org?  I can understand that the manual page documentation may not keep up with updated drivers at downloadcenter.intel.com.
Comment 16 metaqwe 2021-01-04 03:21:41 UTC
(In reply to VVD from comment #14)
I thought em + igb -> em came from the creation of the iflib framework, but I don't know the details.
Comment 17 Mark Linimon freebsd_committer freebsd_triage 2021-01-06 17:15:15 UTC
^Triage: submitter notes that this should be submitted upstream to Intel.  Closing by request.