diff options
author | Emanuele Giuseppe Esposito <eesposit@redhat.com> | 2021-11-03 17:05:25 +0300 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2021-12-08 12:24:40 +0300 |
commit | 355d0473b1a11d7cf526fbd43c3908224e08a909 (patch) | |
tree | 2b8685a8223b553e86509189035e5e956ccff649 /LICENSES/preferred | |
parent | b7a3d8b6f433d293e9033b9d63651b6d17bf5654 (diff) | |
download | linux-355d0473b1a11d7cf526fbd43c3908224e08a909.tar.xz |
KVM: nSVM: use svm->nested.save to load vmcb12 registers and avoid TOC/TOU races
Use the already checked svm->nested.save cached fields
(EFER, CR0, CR4, ...) instead of vmcb12's in
nested_vmcb02_prepare_save().
This prevents from creating TOC/TOU races, since the
guest could modify the vmcb12 fields.
This also avoids the need of force-setting EFER_SVME in
nested_vmcb02_prepare_save.
Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
Message-Id: <20211103140527.752797-6-eesposit@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'LICENSES/preferred')
0 files changed, 0 insertions, 0 deletions