mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-08-28 12:31:04 +00:00
Merge pull request #35 from rbradford/rtc-valid-tweak
qemu: Do not try and generate invalid RTC parameters
This commit is contained in:
commit
f3ab90f21b
@ -1064,17 +1064,13 @@ type RTC struct {
|
||||
|
||||
// Valid returns true if the RTC structure is valid and complete.
|
||||
func (rtc RTC) Valid() bool {
|
||||
if rtc.Clock != "" {
|
||||
if rtc.Clock != Host && rtc.Clock != VM {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
if rtc.DriftFix != "" {
|
||||
if rtc.DriftFix != Slew && rtc.DriftFix != NoDriftFix {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user