Page MenuHomeFreeBSD

ixgbe: Warn once for unsupported SFPs
ClosedPublic

Authored by kbowling on Apr 25 2023, 12:41 AM.
Tags
None
Referenced Files
Unknown Object (File)
Feb 10 2024, 2:03 AM
Unknown Object (File)
Dec 23 2023, 2:35 AM
Unknown Object (File)
Dec 5 2023, 5:11 PM
Unknown Object (File)
Nov 28 2023, 6:51 PM
Unknown Object (File)
Nov 25 2023, 8:01 PM
Unknown Object (File)
Nov 22 2023, 2:33 PM
Unknown Object (File)
Nov 22 2023, 2:30 PM
Unknown Object (File)
Nov 14 2023, 10:11 AM
Subscribers

Details

Summary

The driver belabors the point about unsupported SFPs, printing multiple times on link up. Limit it to once.

Test Plan

Before:
ix0: link state changed to DOWN

WARNING: Intel (R) Network Connections are quality tested using Intel (R) Ethernet Optics. Using untested modules is not supported and may cause unstable operation or damage to the module or the adapter. Intel Corporation is not responsible for any harm caused by using untested modules. WARNING: Intel (R) Network Connections are quality tested using Intel (R) Ethernet Optics. Using untested modules is not supported and may cause unstable operation or damage to the module or the adapter. Intel Corporation is not responsible for any harm caused by using untested modules. WARNING: Intel (R) Network Connections are quality tested using Intel (R) Ethernet Optics. Using untested modules is not supported and may cause unstable operation or damage to the module or the adapter. Intel Corporation is not responsible for any harm caused by using untested modules. ix0: link state changed to UP

After:
ix0: <Intel(R) X520 82599ES (SFI/SFP+)> port 0x8000-0x801f mem 0xd2100000-0xd217ffff,0xd2180000-0xd2183fff irq 27 at device 0.0 numa-domain 0 on pci2

WARNING: Intel (R) Network Connections are quality tested using Intel (R) Ethernet Optics. Using untested modules is not supported and may cause unstable operation or damage to the module or the adapter. Intel Corporation is not responsible for any harm caused by using untested modules.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Owners added a reviewer: Restricted Owners Package.Apr 25 2023, 12:41 AM

Seems ok to me.

sys/dev/ixgbe/ixgbe_phy.c
1305

You could move this into the block where it's used.

1654

Ditto.

Any updates? This looks like an ok-enough hack to me. I think my concern when I last looked at this was that this code could change in the future, but I don't think it will; still, it could be safer to avoid changing it directly here.

sys/dev/ixgbe/ixgbe_phy.c
1541

EWARN() seems to only be used for these two unsupported SFP link up messages -- you could add something to the hw struct (or add something to the ixgbe driver struct and look at it via hw->back) and have the EWARN macro check that.

That way, you wouldn't run into a code conflict if this code gets updated later in the future (though I doubt it will).

This revision was not accepted when it landed; it landed in state Needs Review.Aug 3 2023, 6:01 AM
This revision was automatically updated to reflect the committed changes.