mana_driver: return None from save() when VF reconfiguration is pending#3849
Open
erfrimod wants to merge 2 commits into
Open
mana_driver: return None from save() when VF reconfiguration is pending#3849erfrimod wants to merge 2 commits into
erfrimod wants to merge 2 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adjusts the MANA/GDMA save path to treat “VF reconfiguration pending” (EQE 135) as an expected “no saved state” outcome instead of an error, preventing the netvsp servicing flow from scheduling an FLR and allowing restore to reinitialize the device from scratch.
Changes:
- Change
GdmaDriver::save()to returnOk(None)whenreset_request_pendingis set. - Propagate the optional saved-state behavior through
ManaDevice::save()and the underhill netvsp VF manager via a newVfManagerSaveResult::NoSavedStatevariant. - Add a unit test to verify
save()returnsOk(None)after EQE 135.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| vm/devices/net/mana_driver/src/gdma_driver.rs | Return Ok(None) from save() when VF reset/reconfiguration is pending instead of erroring. |
| vm/devices/net/mana_driver/src/mana.rs | Propagate optional GDMA saved state through ManaDevice::save() and improve error logging. |
| openhcl/underhill_core/src/emuplat/netvsp.rs | Recognize Ok(None) via VfManagerSaveResult::NoSavedState to avoid triggering FLR and return no saved state. |
| vm/devices/net/mana_driver/src/tests.rs | Update existing save/restore test for Option and add new test covering the reset-pending save behavior. |
0e3707d to
f19d26a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When the GDMA driver receives EQE 135 (VF reconfiguration request), it sets reset_request_pending. Calling save() in this state will return an Err(...), which causes the netvsp save path to treat it as a genuine driver failure and schedule an FLR.
VfManagerSaveResult::NoSavedStatevariant and returns no saved state without triggering FLR.test_gdma_save_vf_reset_pendingverifies that save() returns Ok(None) after EQE 135 is fired. The existingtest_gdma_save_restoretest is updated to unwrap the Option.