x86/hyper-v: Fix the circular dependency in IPI enlightenment
authorK. Y. Srinivasan <kys@microsoft.com>
Tue, 3 Jul 2018 23:01:55 +0000 (16:01 -0700)
committerThomas Gleixner <tglx@linutronix.de>
Fri, 6 Jul 2018 10:32:59 +0000 (12:32 +0200)
commit1268ed0c474a5c8f165ef386f3310521b5e00e27
tree6d652266f95cb7b09229ffe476a1572adf95a1f8
parentd0a8d9378d16eb3c69bd8e6d23779fbdbee3a8c7
x86/hyper-v: Fix the circular dependency in IPI enlightenment

The IPI hypercalls depend on being able to map the Linux notion of CPU ID
to the hypervisor's notion of the CPU ID. The array hv_vp_index[] provides
this mapping. Code for populating this array depends on the IPI functionality.
Break this circular dependency.

[ tglx: Use a proper define instead of '-1' with a u32 variable as pointed
   out by Vitaly ]

Fixes: 68bb7bfb7985 ("X86/Hyper-V: Enable IPI enlightenments")
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Michael Kelley <mikelley@microsoft.com>
Cc: gregkh@linuxfoundation.org
Cc: devel@linuxdriverproject.org
Cc: olaf@aepfle.de
Cc: apw@canonical.com
Cc: jasowang@redhat.com
Cc: hpa@zytor.com
Cc: sthemmin@microsoft.com
Cc: Michael.H.Kelley@microsoft.com
Cc: vkuznets@redhat.com
Link: https://lkml.kernel.org/r/20180703230155.15160-1-kys@linuxonhyperv.com
arch/x86/hyperv/hv_apic.c
arch/x86/hyperv/hv_init.c
arch/x86/include/asm/mshyperv.h