Page MenuHomeFreeBSD

ice: Make VF VLAN requests idempotent
Needs ReviewPublic

Authored by kbowling on Tue, Aug 18, 11:08 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Aug 18, 12:48 PM
Unknown Object (File)
Tue, Aug 18, 12:34 PM
Unknown Object (File)
Tue, Aug 18, 12:05 PM
Subscribers

Details

Reviewers
kgalazka
Group Reviewers
Intel Networking
Restricted Owners Package(Owns No Changed Paths)
Summary
VF drivers replay their VLAN filters after a reset and may retry a
request whose reply was lost.  The PF tracked only a count and sent
every requested ID back to the switch.  After PF reset replay had
already restored the filters, duplicate VID 0 failed with
ICE_ERR_ALREADY_EXISTS and NACKed the entire VF batch.

Track exact VLAN membership for each VF.  Compact requests to unique
IDs whose membership changes, enforce the configured limit against
those IDs, and update membership after each hardware operation so
partial failures cannot undercount filters.  Treat already-present
adds and already-absent deletes as successful reconciliation and
suppress their misleading low-level error dump.

Validated on an E810-XXV with a host-attached iavf VF.  A three-filter
limit was filled with VIDs 0, 1, and 4094.  PF and CORE resets replayed
all three without a duplicate warning or ADD_VLAN NACK, and DTrace
confirmed a three-VID replay reached the PF.  A fourth unique VID was
rejected without changing the count; deleting an absent VID was a
no-op; deleting and replacing a present VID updated the count exactly.
A 128 four-queue VF create/destroy cycle also completed cleanly, and a
newly recreated VF started with an empty membership map.

MFC after:      2 weeks

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped