Page MenuHomeFreeBSD

hyperv/stor: handle the host's response's status properly
ClosedPublic

Authored by decui_microsoft.com on Jul 11 2016, 11:24 AM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 20 2023, 1:17 AM
Unknown Object (File)
Nov 9 2023, 3:45 AM
Unknown Object (File)
Sep 30 2023, 6:41 AM
Unknown Object (File)
Sep 28 2023, 6:38 AM
Unknown Object (File)
Sep 24 2023, 3:43 PM
Unknown Object (File)
May 27 2023, 12:41 AM
Unknown Object (File)
Mar 23 2023, 6:42 AM
Unknown Object (File)
Mar 6 2023, 4:12 AM
Subscribers

Details

Summary

Hyper-V has a feature called Online VHDX Resize: the disk capacity can be
changed by the host when the VM is running. Note: the host doesn't notify
the VM of the capacity change proactively; when the VM sends the next I/O
request to the host, the host will report an error (SCSI_STATUS_CHECK_COND)
with sense data supplied (the sense data indicates a disk capacity change)
and the VM is supposed to check and handle the capacity change properly,
and retry the I/O request.

However, the current I/O response handling in the VM has a bug: the host's
response's status is lost unintentionally, so the upper SCSI layer in the VM
always thinks the I/O request is completed successfully while it's not (this
causes undefined behaviors), and ignores the sense data.

The patch fixes the issue and makes Online VHDX Resize work properly.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

decui_microsoft.com retitled this revision from to hyperv/stor: handle the host's response's status properly.
decui_microsoft.com updated this object.
decui_microsoft.com edited the test plan for this revision. (Show Details)
This revision is now accepted and ready to land.Jul 12 2016, 1:40 AM
This revision was automatically updated to reflect the committed changes.