Skip to content

1.8: hyperv_ic: implement SaveRestore for KVP & timesync (#4081) - #4127

Merged
Steven Malis (smalis-msft) merged 1 commit into
microsoft:release/1.8.2607from
smalis-msft:backport-1.8-pr4081
Aug 4, 2026
Merged

1.8: hyperv_ic: implement SaveRestore for KVP & timesync (#4081)#4127
Steven Malis (smalis-msft) merged 1 commit into
microsoft:release/1.8.2607from
smalis-msft:backport-1.8-pr4081

Conversation

@smalis-msft

Copy link
Copy Markdown
Contributor

Backport of #4081 to release/1.8.2607.

The cherry-pick of 788419a applied cleanly onto release/1.8.2607 with no conflicts and no manual edits.

Original PR: #4081


This backport PR was created by an AI agent (GitHub Copilot) on behalf of Steven Malis (@smalis-msft).

We've discovered a Linux kernel bug that results in crashes when vmbus
channels are rapidly offered and rescinded, a pattern we exercise in our
vmm_tests. Work around this by implementing SaveRestore for the last two
relevant devices that didn't already support it. Mimic Hyper-V's
behavior by regenerating the devices on restore, rather than actually
saving state.

A future change may make SaveRestore support non-optional, that's still
under discussion.

This doesn't restabilize the broken tests yet, I'll let this bake for a
bit first.

(cherry picked from commit 788419a)
Copilot AI review requested due to automatic review settings July 31, 2026 17:18
@smalis-msft
Steven Malis (smalis-msft) requested a review from a team as a code owner July 31, 2026 17:18
@smalis-msft Steven Malis (smalis-msft) added the release_1.8.2607 Targets the release/1.8.2607 branch. label Jul 31, 2026
@smalis-msft
Steven Malis (smalis-msft) enabled auto-merge (squash) July 31, 2026 17:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Backports upstream work to release/1.8.2607 to make the Hyper-V IC KVP and timesync devices participate in VMBus save/restore without rescinding/reoffering channels, as a workaround for a Linux kernel crash triggered by rapid offer/rescind cycles.

Changes:

  • Implement SaveRestoreSimpleVmbusDevice for KvpIc and TimesyncIc, using NoSavedState and restarting negotiation on restore.
  • Update IcPipe to be ring-memory-generic and harden version negotiation by dropping unexpected (stale) transaction responses; add unit tests for this behavior.
  • Add required dependencies (vmbus_ring, test_with_tracing for async tests).

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
vm/devices/hyperv_ic/src/timesync.rs Enables save/restore support by restarting channel negotiation on restore (no persisted state).
vm/devices/hyperv_ic/src/kvp.rs Enables save/restore support by restarting channel negotiation on restore (no persisted state).
vm/devices/hyperv_ic/src/common.rs Makes IcPipe generic over ring memory and drops stale responses during negotiation; adds focused async tests.
vm/devices/hyperv_ic/Cargo.toml Adds vmbus_ring dependency and test_with_tracing dev-dependency for the new tests.
Cargo.lock Updates lockfile for the added dependencies.

@github-actions

Copy link
Copy Markdown

@smalis-msft
Steven Malis (smalis-msft) merged commit dde8718 into microsoft:release/1.8.2607 Aug 4, 2026
154 of 158 checks passed
@smalis-msft
Steven Malis (smalis-msft) deleted the backport-1.8-pr4081 branch August 4, 2026 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release_1.8.2607 Targets the release/1.8.2607 branch.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants