diff options
author | Peter Maydell | 2017-01-09 12:56:49 +0100 |
---|---|---|
committer | Peter Maydell | 2017-01-09 12:56:49 +0100 |
commit | 8305f9bdf7ca41ee5cabe018fb37b73472c1162d (patch) | |
tree | 72a6405226f7e5dfe46e6ceaec16b4eeb61c9169 /include/hw/arm | |
parent | Merge remote-tracking branch 'remotes/gonglei/tags/cryptodev-next-20161224' i... (diff) | |
parent | hw/ssi/imx_spi.c: Remove MSGDATA register support (diff) | |
download | qemu-8305f9bdf7ca41ee5cabe018fb37b73472c1162d.tar.gz qemu-8305f9bdf7ca41ee5cabe018fb37b73472c1162d.tar.xz qemu-8305f9bdf7ca41ee5cabe018fb37b73472c1162d.zip |
Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20170109' into staging
target-arm queue:
* i2c: Allow I2C devices to NAK start events
* hw/char: QOM'ify exynos4210_uart.c
* clean up and refactor virt-acpi-build.c
* virt-acpi-build: Don't incorrectly claim architectural timer
to be edge-triggered
* m25p80: Don't let rogue SPI controllers cause buffer overruns
* imx_spi: Remove broken MSGDATA register support
# gpg: Signature made Mon 09 Jan 2017 11:52:49 GMT
# gpg: using RSA key 0x3C2525ED14360CDE
# gpg: Good signature from "Peter Maydell <peter.maydell@linaro.org>"
# gpg: aka "Peter Maydell <pmaydell@gmail.com>"
# gpg: aka "Peter Maydell <pmaydell@chiark.greenend.org.uk>"
# Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83 15CF 3C25 25ED 1436 0CDE
* remotes/pmaydell/tags/pull-target-arm-20170109: (21 commits)
hw/ssi/imx_spi.c: Remove MSGDATA register support
m25p80: don't let rogue SPI controllers cause buffer overruns
hw/arm/virt-acpi-build: Don't incorrectly claim architectural timer to be edge-triggered
hw/arm/virt: remove VirtGuestInfo
hw/arm/virt-acpi-build: don't save VirtGuestInfo on AcpiBuildState
hw/arm/virt-acpi-build: remove redundant members from VirtGuestInfo
hw/arm/virt: pass VirtMachineState instead of VirtGuestInfo
hw/arm/virt: move VirtMachineState/Class to virt.h
hw/arm/virt: remove include/hw/arm/virt-acpi-build.h
hw/arm/virt: eliminate struct VirtGuestInfoState
hw/arm/virt: use VirtMachineState.gic_version
hw/arm/virt: parameter passing cleanups
hw/arm/virt-acpi-build: fadt: improve flag naming
hw/arm/virt-acpi-build: gtdt: improve flag naming
hw/arm/virt-acpi-build: name GIC CPU Interface Structure appropriately
hw/arm/virt-acpi-build: add all missing cpu_to_le's
hw/arm/virt: Don't incorrectly claim architectural timer to be edge-triggered
hw/arm/virt: Rename 'vbi' variables to 'vms'
hw/arm/virt: Merge VirtBoardInfo and VirtMachineState
hw/char: QOM'ify exynos4210_uart.c
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include/hw/arm')
-rw-r--r-- | include/hw/arm/virt-acpi-build.h | 47 | ||||
-rw-r--r-- | include/hw/arm/virt.h | 41 |
2 files changed, 40 insertions, 48 deletions
diff --git a/include/hw/arm/virt-acpi-build.h b/include/hw/arm/virt-acpi-build.h deleted file mode 100644 index f5ec749b8f..0000000000 --- a/include/hw/arm/virt-acpi-build.h +++ /dev/null @@ -1,47 +0,0 @@ -/* - * - * Copyright (c) 2015 HUAWEI TECHNOLOGIES CO.,LTD. - * - * Author: Shannon Zhao <zhaoshenglong@huawei.com> - * - * This program is free software; you can redistribute it and/or modify it - * under the terms and conditions of the GNU General Public License, - * version 2 or later, as published by the Free Software Foundation. - * - * This program is distributed in the hope it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along with - * this program. If not, see <http://www.gnu.org/licenses/>. - */ - -#ifndef QEMU_VIRT_ACPI_BUILD_H -#define QEMU_VIRT_ACPI_BUILD_H - -#include "qemu-common.h" -#include "hw/arm/virt.h" -#include "qemu/notify.h" - -#define ACPI_GICC_ENABLED 1 - -typedef struct VirtGuestInfo { - int smp_cpus; - FWCfgState *fw_cfg; - const MemMapEntry *memmap; - const int *irqmap; - bool use_highmem; - int gic_version; - bool no_its; -} VirtGuestInfo; - - -typedef struct VirtGuestInfoState { - VirtGuestInfo info; - Notifier machine_done; -} VirtGuestInfoState; - -void virt_acpi_setup(VirtGuestInfo *guest_info); - -#endif diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index 9650193253..eb1c63d688 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -32,6 +32,9 @@ #include "qemu-common.h" #include "exec/hwaddr.h" +#include "qemu/notify.h" +#include "hw/boards.h" +#include "hw/arm/arm.h" #define NUM_GICV2M_SPIS 64 #define NUM_VIRTIO_TRANSPORTS 32 @@ -74,5 +77,41 @@ typedef struct MemMapEntry { hwaddr size; } MemMapEntry; +typedef struct { + MachineClass parent; + bool disallow_affinity_adjustment; + bool no_its; + bool no_pmu; + bool claim_edge_triggered_timers; +} VirtMachineClass; -#endif +typedef struct { + MachineState parent; + Notifier machine_done; + FWCfgState *fw_cfg; + bool secure; + bool highmem; + int32_t gic_version; + struct arm_boot_info bootinfo; + const MemMapEntry *memmap; + const int *irqmap; + int smp_cpus; + void *fdt; + int fdt_size; + uint32_t clock_phandle; + uint32_t gic_phandle; + uint32_t msi_phandle; + bool using_psci; +} VirtMachineState; + +#define TYPE_VIRT_MACHINE MACHINE_TYPE_NAME("virt") +#define VIRT_MACHINE(obj) \ + OBJECT_CHECK(VirtMachineState, (obj), TYPE_VIRT_MACHINE) +#define VIRT_MACHINE_GET_CLASS(obj) \ + OBJECT_GET_CLASS(VirtMachineClass, obj, TYPE_VIRT_MACHINE) +#define VIRT_MACHINE_CLASS(klass) \ + OBJECT_CLASS_CHECK(VirtMachineClass, klass, TYPE_VIRT_MACHINE) + +void virt_acpi_setup(VirtMachineState *vms); + +#endif /* QEMU_ARM_VIRT_H */ |