aboutsummaryrefslogtreecommitdiff
path: root/target/i386/machine.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2022-01-13 13:59:56 +0000
committerPeter Maydell <peter.maydell@linaro.org>2022-01-13 13:59:56 +0000
commit67b6526cf042f22521feff5ea521a05d3dd2bf8f (patch)
tree943c53c772902f6ec4ee9287fbb7223b7aadb921 /target/i386/machine.c
parentf8d75e10d3e0033a0a29a7a7e4777a4fbc17a016 (diff)
parent9d30c78c7d3b994825cbe63fa277279ae3ef4248 (diff)
Merge remote-tracking branch 'remotes/bonzini-gitlab/tags/for-upstream' into staging
* configure and meson cleanups * KVM_GET/SET_SREGS2 support for x86 # gpg: Signature made Wed 12 Jan 2022 13:09:19 GMT # gpg: using RSA key F13338574B662389866C7682BFFBD25F78C7AE83 # gpg: issuer "pbonzini@redhat.com" # gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org>" [full] # gpg: aka "Paolo Bonzini <pbonzini@redhat.com>" [full] # Primary key fingerprint: 46F5 9FBD 57D6 12E7 BFD4 E2F7 7E15 100C CD36 69B1 # Subkey fingerprint: F133 3857 4B66 2389 866C 7682 BFFB D25F 78C7 AE83 * remotes/bonzini-gitlab/tags/for-upstream: meson: reenable filemonitor-inotify compilation meson: build all modules by default configure: do not create roms/seabios/config.mak if SeaBIOS not present tests/tcg: Fix target-specific Makefile variables path for user-mode KVM: x86: ignore interrupt_bitmap field of KVM_GET/SET_SREGS KVM: use KVM_{GET|SET}_SREGS2 when supported. meson: add comments in the target-specific flags section configure, meson: move config-poison.h to meson meson: build contrib/ executables after generated headers configure: move non-command-line variables away from command-line parsing section configure: parse --enable/--disable-strip automatically, flip default configure, makefile: remove traces of really old files configure: do not set bsd_user/linux_user early configure: simplify creation of plugin symbol list block/file-posix: Simplify the XFS_IOC_DIOINFO handling meson: cleanup common-user/ build user: move common-user includes to a subdirectory of {bsd,linux}-user/ meson: reuse common_user_inc when building files specific to user-mode emulators Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/i386/machine.c')
-rw-r--r--target/i386/machine.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/target/i386/machine.c b/target/i386/machine.c
index 83c2b91529..6202f47793 100644
--- a/target/i386/machine.c
+++ b/target/i386/machine.c
@@ -1451,6 +1451,34 @@ static const VMStateDescription vmstate_msr_intel_sgx = {
.needed = intel_sgx_msrs_needed,
.fields = (VMStateField[]) {
VMSTATE_UINT64_ARRAY(env.msr_ia32_sgxlepubkeyhash, X86CPU, 4),
+ VMSTATE_END_OF_LIST()
+ }
+ };
+
+static bool pdptrs_needed(void *opaque)
+{
+ X86CPU *cpu = opaque;
+ CPUX86State *env = &cpu->env;
+ return env->pdptrs_valid;
+}
+
+static int pdptrs_post_load(void *opaque, int version_id)
+{
+ X86CPU *cpu = opaque;
+ CPUX86State *env = &cpu->env;
+ env->pdptrs_valid = true;
+ return 0;
+}
+
+
+static const VMStateDescription vmstate_pdptrs = {
+ .name = "cpu/pdptrs",
+ .version_id = 1,
+ .minimum_version_id = 1,
+ .needed = pdptrs_needed,
+ .post_load = pdptrs_post_load,
+ .fields = (VMStateField[]) {
+ VMSTATE_UINT64_ARRAY(env.pdptrs, X86CPU, 4),
VMSTATE_END_OF_LIST()
}
};
@@ -1593,6 +1621,7 @@ const VMStateDescription vmstate_x86_cpu = {
#endif
&vmstate_msr_tsx_ctrl,
&vmstate_msr_intel_sgx,
+ &vmstate_pdptrs,
NULL
}
};