Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
clh: Clear the "PCIAddr" field while blk device hotplug
Browse files Browse the repository at this point in the history
We explicitly set "PCIAddr" to NULL, so that the "VirtPath" field can be
used by the agent to create the container.

Fixes: #2720

Signed-off-by: Bo Chen <[email protected]>
  • Loading branch information
likebreath committed Jun 2, 2020
1 parent 50c1dce commit 5b96e01
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions virtcontainers/clh.go
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,9 @@ func (clh *cloudHypervisor) hotplugBlockDevice(drive *config.BlockDrive) error {
return openAPIClientError(err)
}

//Explicitly set PCIAddr to NULL, so that VirtPath can be used
drive.PCIAddr = ""

if drive.Pmem {
err = fmt.Errorf("pmem device hotplug not supported")
} else {
Expand Down

0 comments on commit 5b96e01

Please sign in to comment.