Page MenuHomeFreeBSD

ice: Roll back Tx queues after scheduler setup failures
Needs ReviewPublic

Authored by kbowling on Tue, Aug 18, 10:41 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Aug 26, 10:10 AM
Unknown Object (File)
Wed, Aug 26, 8:59 AM
Unknown Object (File)
Wed, Aug 26, 6:01 AM
Unknown Object (File)
Tue, Aug 25, 8:34 PM
Unknown Object (File)
Tue, Aug 25, 6:10 AM
Unknown Object (File)
Tue, Aug 25, 3:04 AM
Unknown Object (File)
Tue, Aug 25, 2:28 AM
Unknown Object (File)
Mon, Aug 24, 5:17 PM
Subscribers

Details

Reviewers
kgalazka
Group Reviewers
Intel Networking
Restricted Owners Package(Owns No Changed Paths)
Summary
Add Tx LAN Queues commits the PQM queue and PSM leaf before returning
success.  ice_ena_vsi_txq() can subsequently fail to create the software
scheduler node or replay its saved bandwidth configuration.  Returning
at that point leaves an allocated queue that the caller does not record.
Later queue setup can fail until a function or PF reset removes it.

Issue Disable Tx LAN Queues directly from the completed Add response
before returning a post-add error.  Keep the rollback buffer on the
stack so the allocation failure being recovered cannot also prevent
cleanup.  Remove any software node and invalidate its queue context only
after firmware accepts the disable.  Preserve the queue context and any
software node when rollback fails so active hardware state is not
hidden.

This follows the Add and Disable command lifecycle documented in the
Intel E810 Datasheet, document 613875-003, section 10.5.5.8.

MFC after:      2 weeks
Test Plan

Note this is a shared code change. It was noticed during code and datasheet review, I did not attempt a reproducer.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped