aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/kvm/svm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
index 31be4a557447..611c72875fb9 100644
--- a/arch/x86/kvm/svm.c
+++ b/arch/x86/kvm/svm.c
@@ -163,7 +163,7 @@ static DEFINE_PER_CPU(u64, current_tsc_ratio);
163 163
164#define MSR_INVALID 0xffffffffU 164#define MSR_INVALID 0xffffffffU
165 165
166static struct svm_direct_access_msrs { 166static const struct svm_direct_access_msrs {
167 u32 index; /* Index of the MSR */ 167 u32 index; /* Index of the MSR */
168 bool always; /* True if intercept is always on */ 168 bool always; /* True if intercept is always on */
169} direct_access_msrs[] = { 169} direct_access_msrs[] = {
@@ -400,7 +400,7 @@ struct svm_init_data {
400 int r; 400 int r;
401}; 401};
402 402
403static u32 msrpm_ranges[] = {0, 0xc0000000, 0xc0010000}; 403static const u32 msrpm_ranges[] = {0, 0xc0000000, 0xc0010000};
404 404
405#define NUM_MSR_MAPS ARRAY_SIZE(msrpm_ranges) 405#define NUM_MSR_MAPS ARRAY_SIZE(msrpm_ranges)
406#define MSRS_RANGE_SIZE 2048 406#define MSRS_RANGE_SIZE 2048
@@ -3267,7 +3267,7 @@ static int pause_interception(struct vcpu_svm *svm)
3267 return 1; 3267 return 1;
3268} 3268}
3269 3269
3270static int (*svm_exit_handlers[])(struct vcpu_svm *svm) = { 3270static int (*const svm_exit_handlers[])(struct vcpu_svm *svm) = {
3271 [SVM_EXIT_READ_CR0] = cr_interception, 3271 [SVM_EXIT_READ_CR0] = cr_interception,
3272 [SVM_EXIT_READ_CR3] = cr_interception, 3272 [SVM_EXIT_READ_CR3] = cr_interception,
3273 [SVM_EXIT_READ_CR4] = cr_interception, 3273 [SVM_EXIT_READ_CR4] = cr_interception,
@@ -4068,7 +4068,7 @@ static void svm_fpu_deactivate(struct kvm_vcpu *vcpu)
4068#define POST_MEM(exit) { .exit_code = (exit), \ 4068#define POST_MEM(exit) { .exit_code = (exit), \
4069 .stage = X86_ICPT_POST_MEMACCESS, } 4069 .stage = X86_ICPT_POST_MEMACCESS, }
4070 4070
4071static struct __x86_intercept { 4071static const struct __x86_intercept {
4072 u32 exit_code; 4072 u32 exit_code;
4073 enum x86_intercept_stage stage; 4073 enum x86_intercept_stage stage;
4074} x86_intercept_map[] = { 4074} x86_intercept_map[] = {