From 257b9a5faab5849fa61f1a523b429dc279d33cc3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= Date: Fri, 22 May 2015 18:45:11 +0200 Subject: [PATCH] KVM: x86: use correct APIC ID on x2APIC transition MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit SDM April 2015, 10.12.5 State Changes From xAPIC Mode to x2APIC Mode • Any APIC ID value written to the memory-mapped local APIC ID register is not preserved. Fix it by sourcing vcpu_id (= initial APIC ID) instead of memory-mapped APIC ID. Proper use of apic functions would result in two calls to recalculate_apic_map(), so this patch makes a new helper. Signed-off-by: Radim Krčmář Signed-off-by: Paolo Bonzini --- Reading git-format-patch failed