Commit a4dae7c
committed
KVM: x86: Allow vendor code to disable quirks
In some cases, the handling of quirks is split between platform-specific
code and generic code, or it is done entirely in generic code, but the
relevant bug does not trigger on some platforms; for example,
this will be the case for "ignore guest PAT". Allow unaffected vendor
modules to disable handling of a quirk for all VMs via a new entry in
kvm_caps.
Such quirks remain available in KVM_CAP_DISABLE_QUIRKS2, because that API
tells userspace that KVM *knows* that some of its past behavior was bogus
or just undesirable. In other words, it's plausible for userspace to
refuse to run if a quirk is not listed by KVM_CAP_DISABLE_QUIRKS2, so
preserve that and make it part of the API.
As an example, mark KVM_X86_QUIRK_CD_NW_CLEARED as auto-disabled on
Intel systems.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>1 parent 9966b78 commit a4dae7c
4 files changed
+7
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2422 | 2422 | | |
2423 | 2423 | | |
2424 | 2424 | | |
| 2425 | + | |
| 2426 | + | |
| 2427 | + | |
2425 | 2428 | | |
2426 | 2429 | | |
2427 | 2430 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5472 | 5472 | | |
5473 | 5473 | | |
5474 | 5474 | | |
| 5475 | + | |
5475 | 5476 | | |
5476 | 5477 | | |
5477 | 5478 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9783 | 9783 | | |
9784 | 9784 | | |
9785 | 9785 | | |
| 9786 | + | |
9786 | 9787 | | |
9787 | 9788 | | |
9788 | 9789 | | |
| |||
12733 | 12734 | | |
12734 | 12735 | | |
12735 | 12736 | | |
| 12737 | + | |
12736 | 12738 | | |
12737 | 12739 | | |
12738 | 12740 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
0 commit comments