diff options
author | Paul Gortmaker <paul.gortmaker@windriver.com> | 2011-04-13 16:37:18 -0400 |
---|---|---|
committer | Paul Gortmaker <paul.gortmaker@windriver.com> | 2011-04-13 16:38:47 -0400 |
commit | 95fd2cb3c365eb14341e9ba2a2472a37336725ee (patch) | |
tree | 325994f09f999a9bde832f39e65de91c5e921d0f | |
parent | 174b00c873df7b85810069f22ebe3b4b7064c903 (diff) | |
download | longterm-queue-2.6.34-95fd2cb3c365eb14341e9ba2a2472a37336725ee.tar.gz |
give KVM patch the git format-patch default name
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-rw-r--r-- | queue/KVM-x86-fix-information-leak-to-userland.patch (renamed from queue/KVM-x86-fix-information-leak-to-userland2.patch) | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/queue/KVM-x86-fix-information-leak-to-userland2.patch b/queue/KVM-x86-fix-information-leak-to-userland.patch index 8c8e7a7..4e2111c 100644 --- a/queue/KVM-x86-fix-information-leak-to-userland2.patch +++ b/queue/KVM-x86-fix-information-leak-to-userland.patch @@ -1,4 +1,4 @@ -From bfb6654d88eb83757765adc1752a257725c44a04 Mon Sep 17 00:00:00 2001 +From 37db2fe3f1f51b1ccd1b032e3c6180a46220fabe Mon Sep 17 00:00:00 2001 From: Vasiliy Kulikov <segooon@gmail.com> Date: Sat, 30 Oct 2010 22:54:47 +0400 Subject: [PATCH] KVM: x86: fix information leak to userland @@ -14,14 +14,15 @@ In patch v1 Jan Kiszka suggested to fill reserved fields with zeros instead of memset'ting the whole struct. It makes sense as these fields are explicitly marked as padding. No more fields need zeroing. -[PG: 34 doesn't have the dbgregs->reserved or user_ns.pad cases.] +[PG: 34 doesn't have the dbgregs section to be memset, so drop that bit] +KVM-Stable-Tag. Signed-off-by: Vasiliy Kulikov <segooon@gmail.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c -index 1781a0f..88af53c 100644 +index 7ea2888..8ced130 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -2115,6 +2115,7 @@ static void kvm_vcpu_ioctl_x86_get_vcpu_events(struct kvm_vcpu *vcpu, @@ -32,7 +33,7 @@ index 1781a0f..88af53c 100644 events->exception.error_code = vcpu->arch.exception.error_code; events->interrupt.injected = vcpu->arch.interrupt.pending; -@@ -2124,6 +2125,7 @@ static void kvm_vcpu_ioctl_x86_get_vcpu_events(struct kvm_vcpu *vcpu, +@@ -2124,11 +2125,13 @@ static void kvm_vcpu_ioctl_x86_get_vcpu_events(struct kvm_vcpu *vcpu, events->nmi.injected = vcpu->arch.nmi_injected; events->nmi.pending = vcpu->arch.nmi_pending; events->nmi.masked = kvm_x86_ops->get_nmi_mask(vcpu); @@ -40,29 +41,21 @@ index 1781a0f..88af53c 100644 events->sipi_vector = vcpu->arch.sipi_vector; -@@ -2131,6 +2133,7 @@ static void kvm_vcpu_ioctl_x86_get_vcpu_events(struct kvm_vcpu *vcpu, + events->flags = (KVM_VCPUEVENT_VALID_NMI_PENDING | KVM_VCPUEVENT_VALID_SIPI_VECTOR); ++ memset(&events->reserved, 0, sizeof(events->reserved)); vcpu_put(vcpu); -+ memset(&events->reserved, 0, sizeof(events->reserved)); } - - static int kvm_vcpu_ioctl_x86_set_vcpu_events(struct kvm_vcpu *vcpu, -@@ -2589,6 +2589,7 @@ static int kvm_vm_ioctl_get_pit2(struct kvm *kvm, struct kvm_pit_state2 *ps) +@@ -2589,6 +2592,7 @@ static int kvm_vm_ioctl_get_pit2(struct kvm *kvm, struct kvm_pit_state2 *ps) sizeof(ps->channels)); ps->flags = kvm->arch.vpit->pit_state.flags; mutex_unlock(&kvm->arch.vpit->pit_state.lock); + memset(&ps->reserved, 0, sizeof(ps->reserved)); return r; } -@@ -2607,6 +2610,7 @@ static int kvm_vm_ioctl_set_pit2(struct kvm *kvm, struct kvm_pit_state2 *ps) - kvm->arch.vpit->pit_state.flags = ps->flags; - kvm_pit_load_count(kvm, 0, kvm->arch.vpit->pit_state.channels[0].count, start); - mutex_unlock(&kvm->arch.vpit->pit_state.lock); -+ memset(&ps->reserved, 0, sizeof(ps->reserved)); - return r; - } -@@ -2983,6 +2984,7 @@ long kvm_arch_vm_ioctl(struct file *filp, + +@@ -2983,6 +2987,7 @@ long kvm_arch_vm_ioctl(struct file *filp, now_ns = timespec_to_ns(&now); user_ns.clock = kvm->arch.kvmclock_offset + now_ns; user_ns.flags = 0; |