Commit 2ed4867
committed
vmx: inherit default capability bits from the hypervisor
There have been some observed initialisation failures on new hypervisors
/ hardware, caused by us not recognising a new hypervisor feature.
Previously the code would print an error and exit if it encountered an
unknown feature.
However the hypervisor is able to provide a safe default, so we should
use that instead. Setting the features we want is a VMCS write and
querying the default fields is a VMCS read.
Therefore this patch
- moves the capability probing into the vCPU setup where a VMCS read is possible
- initialises the feature bits with a VMCS read (previously these were all 0)
- removes the failure case when we encounter an unknown feature bit (since the default will be safe)
Signed-off-by: David Scott <dave@recoil.org>1 parent 67ca664 commit 2ed4867
2 files changed
+9
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
596 | 596 | | |
597 | 597 | | |
598 | 598 | | |
| 599 | + | |
599 | 600 | | |
600 | 601 | | |
601 | 602 | | |
| |||
609 | 610 | | |
610 | 611 | | |
611 | 612 | | |
| 613 | + | |
612 | 614 | | |
613 | 615 | | |
614 | 616 | | |
| |||
619 | 621 | | |
620 | 622 | | |
621 | 623 | | |
| 624 | + | |
622 | 625 | | |
623 | 626 | | |
624 | 627 | | |
| |||
629 | 632 | | |
630 | 633 | | |
631 | 634 | | |
| 635 | + | |
632 | 636 | | |
633 | 637 | | |
634 | 638 | | |
| |||
640 | 644 | | |
641 | 645 | | |
642 | 646 | | |
| 647 | + | |
643 | 648 | | |
644 | 649 | | |
645 | 650 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
99 | | - | |
| 99 | + | |
100 | 100 | | |
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
105 | | - | |
| 105 | + | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
109 | | - | |
| 108 | + | |
| 109 | + | |
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
| |||
0 commit comments