Page MenuHomeFreeBSD

ixgbe: Disable EEE for backplane X550EM_X

Authored by on Sep 16 2019, 1:18 PM.
Referenced Files
Unknown Object (File)
Sat, May 25, 9:25 PM
Unknown Object (File)
Sat, May 25, 9:13 PM
Unknown Object (File)
Sat, May 25, 9:12 PM
Unknown Object (File)
Sat, May 25, 3:18 PM
Unknown Object (File)
Thu, May 23, 6:49 PM
Unknown Object (File)
Tue, May 21, 10:43 AM
Unknown Object (File)
Thu, May 9, 2:21 AM
Unknown Object (File)
Thu, May 9, 2:20 AM



Intel documentation indicates that backplane X550EM_X KR devices do not
support Energy Efficient Ethernet.

Signed-off-by: Zach Vargas <>

Test Plan

Prior to this patch X552 devices (device ID 0x15AB) will crash the system when transitioning EEE state via sysctl.

Running 12.0 RELEASE FreeBSD from, attempting to change the EEE state of an ix adapter:

root@bsd:~ # uname -r
root@bsd:~ # sysctl dev.ix.1.eee_state
dev.ix.1.eee_state: 1
root@bsd:~ # sysctl dev.ix.1.eee_state=0

Fatal trap 12: page fault while in kernel mode
cpuid = 5; apic id = 05
fault virtual address  = 0x0
fault code             = supervisor read instruction, page not present
instruction pointer    = 0x20:0x0
stack pointer          = 0x28:0xfffffe008a86d718
frame pointer          = 0x28:0xfffffe008a86d760
code segment           = base 0x0, limit 0xfffff, type 0x1b
                       = DPL 0, pres 1, long 1, def32 0, gran 1
processor eflags       = interrupt enabled, resume, IOPL = 0
current process                = 2424 (sysctl)
trap number            = 12
panic: page fault
cpuid = 5
time = 1563820937
KDB: stack backtrace:
#0 0xffffffff80bdcbc7 at kdb_backtrace+0x67
#1 0xffffffff80b907b3 at vpanic+0x1a3
#2 0xffffffff80b90603 at panic+0x43
#3 0xffffffff8106996f at trap_fatal+0x35f
#4 0xffffffff810699c9 at trap_pfault+0x49
#5 0xffffffff81068fee at trap+0x29e
#6 0xffffffff81044425 at calltrap+0x8
#7 0xffffffff80b9f56b at sysctl_root_handler_locked+0x8b
#8 0xffffffff80b9ec27 at sysctl_root+0x257
#9 0xffffffff80b9f29a at userland_sysctl+0x17a
#10 0xffffffff80b9f0df at sys___sysctl+0x5f
#11 0xffffffff8106a449 at amd64_syscall+0x369
#12 0xffffffff81044d0d at fast_syscall_common+0x101
Uptime: 36m40s
Dumping 736 out of 16329 MB:..3%..11%..22%..31%..42%..53%..61%..72%..81%..92%
Dump complete

Testing with this patch applied:

root@bsd:~/freebsd-ixgbe # sysctl dev.ix.1.eee_state
sysctl: unknown oid 'dev.ix.1.eee_state'
root@bsd:~/freebsd-ixgbe #

Diff Detail

rS FreeBSD src repository - subversion
Lint Not Applicable
Tests Not Applicable

Event Timeline

erj added inline comments.
4418 ↗(On Diff #62034)

If you replace this call with "ixgbe_setup_eee", that would also help prevent a kernel panic if this sysctl somehow gets called without adapter->hw.mac.ops.setup_eee() from being set.

erj requested changes to this revision.Sep 30 2019, 6:26 PM
This revision now requires changes to proceed.Sep 30 2019, 6:26 PM

Thank you for the feedback. After applying (only) the suggested change, testing a EEE state change with my hardware looks like the following:

root@freebsd:/usr/src # sysctl dev.ix.1.eee_state
dev.ix.1.eee_state: 1
root@freebsd:/usr/src # sysctl dev.ix.1.eee_state=0
dev.ix.1.eee_staix1: Error in EEE setup: 0x7FFFFFFF
te: 1
sysctl: dev.ix.1.eee_state=0: Invalid argument
root@freebsd:/usr/src #

With the full patch, testing remains unchanged because EEE will be disabled for my X550EM_X KR device.

This revision is now accepted and ready to land.Oct 8 2019, 5:53 PM
This revision was automatically updated to reflect the committed changes.