]> git.baikalelectronics.ru Git - kernel.git/commit
x86/hyperv: Avoid erroneously sending IPI to 'self'
authorVitaly Kuznetsov <vkuznets@redhat.com>
Wed, 6 Oct 2021 12:50:16 +0000 (14:50 +0200)
committerWei Liu <wei.liu@kernel.org>
Wed, 6 Oct 2021 15:56:45 +0000 (15:56 +0000)
commit78b1e4700b7dec2d5133c5706e31677860429b46
tree5b01533cb990142e691163da364cb5a50e26b3d9
parentb2bd17e1f53c1a245c5919694d02b9d9ec3fbbba
x86/hyperv: Avoid erroneously sending IPI to 'self'

__send_ipi_mask_ex() uses an optimization: when the target CPU mask is
equal to 'cpu_present_mask' it uses 'HV_GENERIC_SET_ALL' format to avoid
converting the specified cpumask to VP_SET. This case was overlooked when
'exclude_self' parameter was added. As the result, a spurious IPI to
'self' can be send.

Reported-by: Thomas Gleixner <tglx@linutronix.de>
Fixes: 3185df40ade1 ("x86/hyperv: remove on-stack cpumask from hv_send_ipi_mask_allbutself")
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20211006125016.941616-1-vkuznets@redhat.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>
arch/x86/hyperv/hv_apic.c