Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,6 @@ linters:
- common-false-positives
- legacy
- std-error-handling
settings:
revive:
rules:
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#var-naming
# Disable due to use of ALL_CAPS consts.
- name: var-naming
disabled: true
formatters:
exclusions:
generated: lax
18 changes: 9 additions & 9 deletions client_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -323,9 +323,9 @@ func (fec FEC) encode(ae *netlink.AttributeEncoder) {
// Supported returns the supported/configured FEC modes. Some drivers report
// supported, others configured. See
// https://kernel.googlesource.com/pub/scm/network/ethtool/ethtool/+/2b3ddcb35357ae34ed0a6ae2bb006dcdaec353a9
func (f *FEC) Supported() FECModes {
result := f.Modes
if f.Auto {
func (fec *FEC) Supported() FECModes {
result := fec.Modes
if fec.Auto {
result |= unix.ETHTOOL_FEC_AUTO
}
return result
Expand Down Expand Up @@ -822,12 +822,12 @@ func parseLinkState(msgs []genetlink.Message) ([]*LinkState, error) {

// TODO: get these into x/sys/unix
const (
_ETHTOOL_A_FEC_UNSPEC = iota
_ETHTOOL_A_FEC_HEADER
_ETHTOOL_A_FEC_MODES
_ETHTOOL_A_FEC_AUTO
_ETHTOOL_A_FEC_ACTIVE
_ETHTOOL_A_FEC_STATS
_ETHTOOL_A_FEC_UNSPEC = iota //nolint:revive
_ETHTOOL_A_FEC_HEADER //nolint:revive
_ETHTOOL_A_FEC_MODES //nolint:revive
_ETHTOOL_A_FEC_AUTO //nolint:revive
_ETHTOOL_A_FEC_ACTIVE //nolint:revive
_ETHTOOL_A_FEC_STATS //nolint:revive
)

// parseFEC parses FEC structures from a slice of generic netlink
Expand Down
Loading