mirror of https://github.com/dynup/kpatch
25 lines
661 B
Diff
25 lines
661 B
Diff
diff -Nupr src.orig/arch/x86/kvm/x86.c src/arch/x86/kvm/x86.c
|
|
--- src.orig/arch/x86/kvm/x86.c 2016-11-30 19:51:01.978178250 +0000
|
|
+++ src/arch/x86/kvm/x86.c 2016-11-30 19:53:25.926178250 +0000
|
|
@@ -2189,12 +2189,20 @@ static void record_steal_time(struct kvm
|
|
&vcpu->arch.st.steal, sizeof(struct kvm_steal_time));
|
|
}
|
|
|
|
+void kpatch_kvm_x86_foo(void)
|
|
+{
|
|
+ if (!jiffies)
|
|
+ printk("kpatch kvm x86 foo\n");
|
|
+}
|
|
+
|
|
int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
|
|
{
|
|
bool pr = false;
|
|
u32 msr = msr_info->index;
|
|
u64 data = msr_info->data;
|
|
|
|
+ kpatch_kvm_x86_foo();
|
|
+
|
|
switch (msr) {
|
|
case MSR_AMD64_NB_CFG:
|
|
case MSR_IA32_UCODE_REV:
|