summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin Schneider <vschneid@redhat.com>2024-03-13 21:01:05 +0300
committerIngo Molnar <mingo@kernel.org>2024-03-22 13:18:19 +0300
commitddd8afacc4f65a01204d7a36b8fd96c908e9b72c (patch)
tree38770f99655d69d22347630ab1299278a51d7ba4
parent4eab44a8ae98df53e59f6af3c860142177235507 (diff)
downloadlinux-ddd8afacc4f65a01204d7a36b8fd96c908e9b72c.tar.xz
x86/kvm: Make kvm_async_pf_enabled __ro_after_init
kvm_async_pf_enabled is only ever enabled in __init kvm_guest_init(), so mark it as __ro_after_init. Signed-off-by: Valentin Schneider <vschneid@redhat.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Sean Christopherson <seanjc@google.com> Acked-by: Josh Poimboeuf <jpoimboe@kernel.org> Link: https://lore.kernel.org/r/20240313180106.2917308-4-vschneid@redhat.com
-rw-r--r--arch/x86/kernel/kvm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c
index 4cadfd606e8e..31a48bae2392 100644
--- a/arch/x86/kernel/kvm.c
+++ b/arch/x86/kernel/kvm.c
@@ -44,7 +44,7 @@
#include <asm/svm.h>
#include <asm/e820/api.h>
-DEFINE_STATIC_KEY_FALSE(kvm_async_pf_enabled);
+DEFINE_STATIC_KEY_FALSE_RO(kvm_async_pf_enabled);
static int kvmapf = 1;