mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-08-31 16:36:38 +00:00
CCv0: Remove qemu paramter 'policy' for SNP container
Removed the qemu paramter 'policy' (and also dh-cert-file, session-file, kernel-hashes=on) for SNP container. Fixes: #5795 Signed-off-by: Niteesh Dubey <niteesh@linux.ibm.com>
This commit is contained in:
@@ -274,11 +274,11 @@ type Object struct {
|
||||
FirmwareVolume string
|
||||
|
||||
// CBitPos is the location of the C-bit in a guest page table entry
|
||||
// This is only relevant for sev-guest objects
|
||||
// This is only relevant for sev-guest and sev-snp-guest objects
|
||||
CBitPos uint32
|
||||
|
||||
// ReducedPhysBits is the reduction in the guest physical address space
|
||||
// This is only relevant for sev-guest objects
|
||||
// This is only relevant for sev-guest and sev-snp-guest objects
|
||||
ReducedPhysBits uint32
|
||||
|
||||
// ReadOnly specifies whether `MemPath` is opened read-only or read/write (default)
|
||||
@@ -370,8 +370,6 @@ func (object Object) QemuParams(config *Config) []string {
|
||||
deviceParams = append(deviceParams, fmt.Sprintf("config-firmware-volume=%s", object.FirmwareVolume))
|
||||
}
|
||||
case SEVGuest:
|
||||
fallthrough
|
||||
case SNPGuest:
|
||||
objectParams = append(objectParams, string(object.Type))
|
||||
objectParams = append(objectParams, fmt.Sprintf("id=%s", object.ID))
|
||||
objectParams = append(objectParams, fmt.Sprintf("cbitpos=%d", object.CBitPos))
|
||||
@@ -389,6 +387,14 @@ func (object Object) QemuParams(config *Config) []string {
|
||||
// Add OVMF firmware as pflash drive
|
||||
driveParams = append(driveParams, "if=pflash,format=raw,readonly=on")
|
||||
driveParams = append(driveParams, fmt.Sprintf("file=%s", object.File))
|
||||
case SNPGuest:
|
||||
objectParams = append(objectParams, string(object.Type))
|
||||
objectParams = append(objectParams, fmt.Sprintf("id=%s", object.ID))
|
||||
objectParams = append(objectParams, fmt.Sprintf("cbitpos=%d", object.CBitPos))
|
||||
objectParams = append(objectParams, fmt.Sprintf("reduced-phys-bits=%d", object.ReducedPhysBits))
|
||||
// Add OVMF firmware as pflash drive
|
||||
driveParams = append(driveParams, "if=pflash,format=raw,readonly=on")
|
||||
driveParams = append(driveParams, fmt.Sprintf("file=%s", object.File))
|
||||
case SecExecGuest:
|
||||
objectParams = append(objectParams, string(object.Type))
|
||||
objectParams = append(objectParams, fmt.Sprintf("id=%s", object.ID))
|
||||
|
Reference in New Issue
Block a user