mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-09-19 15:58:25 +00:00
Merge pull request #2507 from likebreath/fix-persist-clh
clh: add 'APIsocket' to persist HypervisorState
This commit is contained in:
@@ -435,12 +435,14 @@ func (clh *cloudHypervisor) save() (s persistapi.HypervisorState) {
|
||||
s.Pid = clh.state.PID
|
||||
s.Type = string(ClhHypervisor)
|
||||
s.VirtiofsdPid = clh.state.VirtiofsdPID
|
||||
s.APISocket = clh.state.apiSocket
|
||||
return
|
||||
}
|
||||
|
||||
func (clh *cloudHypervisor) load(s persistapi.HypervisorState) {
|
||||
clh.state.PID = s.Pid
|
||||
clh.state.VirtiofsdPID = s.VirtiofsdPid
|
||||
clh.state.apiSocket = s.APISocket
|
||||
}
|
||||
|
||||
func (clh *cloudHypervisor) check() error {
|
||||
|
@@ -42,4 +42,7 @@ type HypervisorState struct {
|
||||
VirtiofsdPid int
|
||||
HotplugVFIOOnRootBus bool
|
||||
PCIeRootPort int
|
||||
|
||||
// clh sepcific: refer to 'virtcontainers/clh.go:CloudHypervisorState'
|
||||
APISocket string
|
||||
}
|
||||
|
Reference in New Issue
Block a user