Commit 0fbd290
KVM: x86: Snapshot the host's DEBUGCTL after disabling IRQs
commit 189ecdb upstream.
Snapshot the host's DEBUGCTL after disabling IRQs, as perf can toggle
debugctl bits from IRQ context, e.g. when enabling/disabling events via
smp_call_function_single(). Taking the snapshot (long) before IRQs are
disabled could result in KVM effectively clobbering DEBUGCTL due to using
a stale snapshot.
Cc: stable@vger.kernel.org
Reviewed-and-tested-by: Ravi Bangoria <ravi.bangoria@amd.com>
Link: https://lore.kernel.org/r/20250227222411.3490595-6-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 5e1b0b0 commit 0fbd290
1 file changed
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4976 | 4976 | | |
4977 | 4977 | | |
4978 | 4978 | | |
4979 | | - | |
4980 | 4979 | | |
4981 | 4980 | | |
4982 | 4981 | | |
| |||
10961 | 10960 | | |
10962 | 10961 | | |
10963 | 10962 | | |
| 10963 | + | |
| 10964 | + | |
10964 | 10965 | | |
10965 | 10966 | | |
10966 | 10967 | | |
| |||
0 commit comments