summaryrefslogtreecommitdiffstats
path: root/target-ppc
diff options
context:
space:
mode:
authorEric Auger <eric.auger@linaro.org>2015-06-02 14:56:23 +0100
committerPeter Maydell <peter.maydell@linaro.org>2015-06-02 14:56:25 +0100
commit1850b6b7d027bb4b45010a7d1da919267fff2cd4 (patch)
tree3b09b37bef4e6553dca6c55a1d01f603c1058f35 /target-ppc
parent0b2ff2ceb8a45cbe51ca13a1a32fc5bdeec71815 (diff)
downloadhqemu-1850b6b7d027bb4b45010a7d1da919267fff2cd4.zip
hqemu-1850b6b7d027bb4b45010a7d1da919267fff2cd4.tar.gz
kvm: introduce kvm_arch_msi_data_to_gsi
On ARM the MSI data corresponds to the shared peripheral interrupt (SPI) ID. This latter equals to the SPI index + 32. to retrieve the SPI index, matching the gsi, an architecture specific function is introduced. Signed-off-by: Eric Auger <eric.auger@linaro.org> Acked-by: Christoffer Dall <christoffer.dall@linaro.org> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target-ppc')
-rw-r--r--target-ppc/kvm.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/target-ppc/kvm.c b/target-ppc/kvm.c
index 1da9ea8..8f7cee5 100644
--- a/target-ppc/kvm.c
+++ b/target-ppc/kvm.c
@@ -2410,3 +2410,8 @@ int kvm_arch_fixup_msi_route(struct kvm_irq_routing_entry *route,
{
return 0;
}
+
+int kvm_arch_msi_data_to_gsi(uint32_t data)
+{
+ return data & 0xffff;
+}
OpenPOWER on IntegriCloud