kvm: selftests: aarch64: pass vgic_irq guest args as a pointer
authorRicardo Koller <ricarkol@google.com>
Thu, 27 Jan 2022 03:08:55 +0000 (19:08 -0800)
committerMarc Zyngier <maz@kernel.org>
Tue, 8 Feb 2022 15:18:58 +0000 (15:18 +0000)
commit11024a7a0ac26dd31ddfa0f6590e158bdf9ab858
tree3e8f12c7955c237f069ff5edf42dcadd4426e6f4
parentcc94d47ce16d4147d546e47c8248e8bd12ba5fe5
kvm: selftests: aarch64: pass vgic_irq guest args as a pointer

The guest in vgic_irq gets its arguments in a struct. This struct used
to fit nicely in a single register so vcpu_args_set() was able to pass
it by value by setting x0 with it. Unfortunately, this args struct grew
after some commits and some guest args became random (specically
kvm_supports_irqfd).

Fix this by passing the guest args as a pointer (after allocating some
guest memory for it).

Signed-off-by: Ricardo Koller <ricarkol@google.com>
Reported-by: Reiji Watanabe <reijiw@google.com>
Cc: Andrew Jones <drjones@redhat.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220127030858.3269036-3-ricarkol@google.com
tools/testing/selftests/kvm/aarch64/vgic_irq.c