runtime: 0079-kata-runtime-fix-qemu-SCSIBus-info-not-saved-into-pe.patch 0080-kata-runtime-fix-the-block-device-not-removed-in-dev.patch 0081-kata-runtime-cut-too-long-message-in-grpc-log.patch 0082-kata-runtime-change-sandbox-state-to-unhealthy-when-.patch 0083-kata-runtime-add-removeMountBlockDevices-for-contain.patch 0084-kata-runtime-fix-validInterface-func-cause-crash-pro.patch 0085-kata-runtime-fix-kata-netmon-does-not-exit-when-cont.patch 0086-kata-runtime-add-checkCPUSet-before-create-container.patch 0087-kata-runtime-force-delete-the-sandbox-and-container.patch 0088-kata-runtime-check-sandbox-healthy-state-before-call.patch 0089-kata-add-support-for-update-iface.patch 0090-kata-set-sandbox-or-container-status-to-unhealthy.patch 0091-kata-runtime-add-sandbox-file-lock-while-call-GetSan.patch 0092-qemu-add-arm64-to-support-list-of-dimm.patch 0093-kata-runtime-add-timeout-for-grpcWaitProcessRequest.patch 0094-kata-runtime-fix-update-iface-clean-NIC-cause-route-.patch 0095-kata-runtime-fix-qemu-process-resource-resi.patch 0096-kata-containers-Move-from-query-cpus-to-query-cpus-f.patch agent: 0021-kata-agent-fix-sync-clock-not-work-problem.patch 0022-kata-agent-delete-container-id-from-sandbox-struct.patch 0023-kata-agent-modify-log-level.patch 0024-kata-agent-fix-agent.debug_console-not-work-when-bui.patch Signed-off-by: Vanient <xiadanni1@huawei.com> (cherry picked from commit f2d936028666741658157472b8de9d02187c6d55)
55 lines
2.2 KiB
Diff
55 lines
2.2 KiB
Diff
From 3f47ddd1b793b6fe92cba13737cd7b0c14a19edc Mon Sep 17 00:00:00 2001
|
|
From: holyfei <yangfeiyu2@huawei.com>
|
|
Date: Sun, 15 Nov 2020 21:48:14 +0800
|
|
Subject: [PATCH 2/3] kata-runtime: fix qemu SCSIBus info not saved into
|
|
persist.json
|
|
|
|
reason: SCSIBus has a map object to save the slots info which
|
|
indicates which slot is useful. However, the SCSIBus object is
|
|
not saved into persist.json file, which causes fetchSandbox will
|
|
create a new one instead of restoring it from persist.json file.
|
|
|
|
Conflict: NA
|
|
Reference:https://gitee.com/src-openeuler/kata-containers
|
|
Signed-off-by: holyfei <yangfeiyu2@huawei.com>
|
|
---
|
|
virtcontainers/persist/api/hypervisor.go | 1 +
|
|
virtcontainers/qemu.go | 2 ++
|
|
2 files changed, 3 insertions(+)
|
|
|
|
diff --git a/virtcontainers/persist/api/hypervisor.go b/virtcontainers/persist/api/hypervisor.go
|
|
index fd61b3c2..213453ac 100644
|
|
--- a/virtcontainers/persist/api/hypervisor.go
|
|
+++ b/virtcontainers/persist/api/hypervisor.go
|
|
@@ -39,6 +39,7 @@ type HypervisorState struct {
|
|
// Refs: virtcontainers/qemu.go:QemuState
|
|
Bridges []Bridge
|
|
PCIeRootPortsPool *types.PCIeRootPortPool
|
|
+ ScsiBus *types.SCSIBus
|
|
// HotpluggedCPUs is the list of CPUs that were hot-added
|
|
HotpluggedVCPUs []CPUDevice
|
|
HotpluggedMemory int
|
|
diff --git a/virtcontainers/qemu.go b/virtcontainers/qemu.go
|
|
index be6e33b9..e5610e89 100644
|
|
--- a/virtcontainers/qemu.go
|
|
+++ b/virtcontainers/qemu.go
|
|
@@ -2342,6 +2342,7 @@ func (q *qemu) save() (s persistapi.HypervisorState) {
|
|
s.HotplugVFIOOnRootBus = q.state.HotplugVFIOOnRootBus
|
|
s.PCIeRootPort = q.state.PCIeRootPort
|
|
s.PCIeRootPortsPool = q.state.PCIeRootPortsPool
|
|
+ s.ScsiBus = q.state.ScsiBus
|
|
|
|
for _, bridge := range q.arch.getBridges() {
|
|
s.Bridges = append(s.Bridges, persistapi.Bridge{
|
|
@@ -2367,6 +2368,7 @@ func (q *qemu) load(s persistapi.HypervisorState) {
|
|
q.state.VirtiofsdPid = s.VirtiofsdPid
|
|
q.state.PCIeRootPort = s.PCIeRootPort
|
|
q.state.PCIeRootPortsPool = s.PCIeRootPortsPool
|
|
+ q.state.ScsiBus = s.ScsiBus
|
|
|
|
for _, bridge := range s.Bridges {
|
|
q.state.Bridges = append(q.state.Bridges, types.NewBridge(types.Type(bridge.Type), bridge.ID, bridge.DeviceAddr, bridge.Addr))
|
|
--
|
|
2.23.0
|
|
|