KVM: arm64: selftests: Add support for cpu_relax
authorRaghavendra Rao Ananta <rananta@google.com>
Thu, 7 Oct 2021 23:34:29 +0000 (23:34 +0000)
committerMarc Zyngier <maz@kernel.org>
Sun, 17 Oct 2021 10:17:20 +0000 (11:17 +0100)
commit740826ec02a65a5b25335fddfe8bce4ac99c7a11
tree86689176540dd7f22ec708abb1b985d150e7ff24
parentb3c79c6130bcfdb0ff3819077deaddce981a0718
KVM: arm64: selftests: Add support for cpu_relax

Implement the guest helper routine, cpu_relax(), to yield
the processor to other tasks.

The function was derived from
arch/arm64/include/asm/vdso/processor.h.

Signed-off-by: Raghavendra Rao Ananta <rananta@google.com>
Reviewed-by: Oliver Upton <oupton@google.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20211007233439.1826892-6-rananta@google.com
tools/testing/selftests/kvm/include/aarch64/processor.h