netvsp: handle guest-triggered WorkerErrors instead of tearing down#3549
Open
erfrimod wants to merge 2 commits into
Open
netvsp: handle guest-triggered WorkerErrors instead of tearing down#3549erfrimod 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 hardens the netvsp worker against malformed or unexpected guest inputs by converting several previously-fatal WorkerError paths into “trace + skip” handling, preventing the VMM from tearing down the network channel due to guest-triggered protocol issues.
Changes:
- Skip malformed packets during ring draining with rate-limited logging instead of failing the worker.
- Treat invalid/duplicate RNDIS packet completions and unexpected packet types as non-fatal (rate-limited) events.
- When send/receive buffer setup fails during initialization, send FAILURE completions to the guest and continue to allow retries; adjust RNDIS control message error handling to free buffers where appropriate.
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.
Several error paths in the netvsp worker would propagate errors up as
WorkerError, causing the VMM to tear down the network adapter connection when a guest sent malformed or unexpected data. These are guest inputs that cause netvsp to stop processing packets.