From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37862) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b9vot-00006H-Cc for qemu-devel@nongnu.org; Mon, 06 Jun 2016 10:48:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b9voq-0000Tf-Ty for qemu-devel@nongnu.org; Mon, 06 Jun 2016 10:47:58 -0400 Received: from orth.archaic.org.uk ([2001:8b0:1d0::2]:57504) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b9voq-0000QW-M8 for qemu-devel@nongnu.org; Mon, 06 Jun 2016 10:47:56 -0400 Received: from pm215 by orth.archaic.org.uk with local (Exim 4.84_2) (envelope-from ) id 1b9voj-0008Cq-Rh for qemu-devel@nongnu.org; Mon, 06 Jun 2016 15:47:49 +0100 From: Peter Maydell Date: Mon, 6 Jun 2016 15:47:25 +0100 Message-Id: <1465224465-21998-9-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1465224465-21998-1-git-send-email-peter.maydell@linaro.org> References: <1465224465-21998-1-git-send-email-peter.maydell@linaro.org> Subject: [Qemu-devel] [PULL 08/28] hw/arm/virt-acpi-build: Add PMU IRQ number in ACPI table List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org From: Shannon Zhao Add PMU IRQ number in ACPI table, then we can use PMU in guest through ACPI. Signed-off-by: Shannon Zhao Reviewed-by: Andrew Jones Message-id: 1461670846-13196-4-git-send-email-zhaoshenglong@huawei.com [PMM: added braces] Signed-off-by: Peter Maydell --- hw/arm/virt-acpi-build.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index 83a5420..2586769 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -539,6 +539,10 @@ build_madt(GArray *table_data, GArray *linker, VirtGuestInfo *guest_info) gicc->arm_mpidr = armcpu->mp_affinity; gicc->uid = i; gicc->flags = cpu_to_le32(ACPI_GICC_ENABLED); + + if (armcpu->has_pmu) { + gicc->performance_interrupt = cpu_to_le32(PPI(VIRTUAL_PMU_IRQ)); + } } if (guest_info->gic_version == 3) { -- 1.9.1