fix(vmbus_relay): enable interrupt relay by default for message redirection#3747
Open
moor-coding wants to merge 1 commit into
Open
fix(vmbus_relay): enable interrupt relay by default for message redirection#3747moor-coding wants to merge 1 commit into
moor-coding wants to merge 1 commit into
Conversation
…ection When VMBus message redirection is active, host-to-guest interrupts target VTL2 instead of VTL0. The relay must forward these interrupts to VTL0, but use_interrupt_relay defaulted to false and was only set to true when the guest sent a ModifyConnection with use_interrupt_page=true. Modern guests (VMBus Copper version) negotiate with all feature flags false, so the interrupt page is never set, leaving relay channels without interrupt forwarding. This caused RNDIS timeout failures on the NIC: the host wrote data to the ring buffer and signaled the guest, but the signal went to VTL2 and was never forwarded to VTL0. Default use_interrupt_relay to true since the relay only exists when message redirection is active, making interrupt forwarding always required.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the VMBus relay (used under VMBus message redirection) to ensure host-to-guest interrupts targeting VTL2 are forwarded to VTL0 by default, addressing failures seen with modern (Copper) guests that negotiate with feature flags disabled.
Changes:
- Updates the relay’s open-channel logic comment to reflect that interrupts must be relayed under message redirection.
- Changes the relay task’s
use_interrupt_relaydefault fromfalsetotrue.
Comment on lines
+274
to
276
| // With VMBus message redirection, host interrupts target VTL2 and must | ||
| // be relayed to VTL0. This is always the case when a relay is active. | ||
| let redirect_interrupt = self.channel.use_interrupt_relay.load(Ordering::SeqCst); |
| channel_workers: FuturesUnordered::new(), | ||
| intercept_channels: HashMap::new(), | ||
| use_interrupt_relay: Arc::new(AtomicBool::new(false)), | ||
| use_interrupt_relay: Arc::new(AtomicBool::new(true)), |
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 VMBus message redirection is active, host-to-guest interrupts target VTL2 instead of VTL0. The relay must forward these interrupts to VTL0, but use_interrupt_relay defaulted to false and was only set to true when the guest sent a ModifyConnection with use_interrupt_page=true.
Modern guests (VMBus Copper version) negotiate with all feature flags false, so the interrupt page is never set, leaving relay channels without interrupt forwarding.
This caused RNDIS timeout failures on the NIC: the host wrote data to the ring buffer and signaled the guest, but the signal went to VTL2 and was never forwarded to VTL0.
The relay only exists when message redirection is active, so interrupt forwarding is always required. Default use_interrupt_relay to true.