From e81096b1c84cc5f8bcf6189f7758a0643fd75107 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 4 Dec 2015 11:03:51 +0100 Subject: explicitly include linux/kvm.h Signed-off-by: Paolo Bonzini --- hw/intc/xics_kvm.c | 1 + 1 file changed, 1 insertion(+) (limited to 'hw/intc') diff --git a/hw/intc/xics_kvm.c b/hw/intc/xics_kvm.c index 9029d9ee0b..b40292d050 100644 --- a/hw/intc/xics_kvm.c +++ b/hw/intc/xics_kvm.c @@ -31,6 +31,7 @@ #include "cpu.h" #include "hw/hw.h" #include "trace.h" +#include "linux/kvm.h" #include "hw/ppc/spapr.h" #include "hw/ppc/xics.h" #include "kvm_ppc.h" -- cgit 1.4.1 From d613f8cc336ffc81cad4898c50e7ac1997a6eef1 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Fri, 4 Dec 2015 11:04:13 +0100 Subject: apic: move target-dependent definitions to cpu.h Signed-off-by: Paolo Bonzini --- hw/intc/ioapic.c | 1 + include/hw/i386/apic.h | 5 ----- target-i386/cpu.h | 7 +++++++ 3 files changed, 8 insertions(+), 5 deletions(-) (limited to 'hw/intc') diff --git a/hw/intc/ioapic.c b/hw/intc/ioapic.c index 378e663f65..4f42b911a2 100644 --- a/hw/intc/ioapic.c +++ b/hw/intc/ioapic.c @@ -24,6 +24,7 @@ #include "monitor/monitor.h" #include "hw/hw.h" #include "hw/i386/pc.h" +#include "hw/i386/apic.h" #include "hw/i386/ioapic.h" #include "hw/i386/ioapic_internal.h" #include "include/hw/pci/msi.h" diff --git a/include/hw/i386/apic.h b/include/hw/i386/apic.h index 51eb6d3884..ea48ea9389 100644 --- a/include/hw/i386/apic.h +++ b/include/hw/i386/apic.h @@ -18,15 +18,10 @@ void cpu_set_apic_tpr(DeviceState *s, uint8_t val); uint8_t cpu_get_apic_tpr(DeviceState *s); void apic_init_reset(DeviceState *s); void apic_sipi(DeviceState *s); -void apic_handle_tpr_access_report(DeviceState *d, target_ulong ip, - TPRAccess access); void apic_poll_irq(DeviceState *d); void apic_designate_bsp(DeviceState *d, bool bsp); /* pc.c */ DeviceState *cpu_get_current_apic(void); -/* cpu.c */ -bool cpu_is_bsp(X86CPU *cpu); - #endif diff --git a/target-i386/cpu.h b/target-i386/cpu.h index 93b5cd0e05..bc8c3fbcbf 100644 --- a/target-i386/cpu.h +++ b/target-i386/cpu.h @@ -1455,7 +1455,11 @@ void do_interrupt_x86_hardirq(CPUX86State *env, int intno, int is_hw); void do_smm_enter(X86CPU *cpu); void cpu_smm_update(X86CPU *cpu); +/* apic.c */ void cpu_report_tpr_access(CPUX86State *env, TPRAccess access); +void apic_handle_tpr_access_report(DeviceState *d, target_ulong ip, + TPRAccess access); + /* Change the value of a KVM-specific default * @@ -1481,4 +1485,7 @@ void enable_compat_apic_id_mode(void); void x86_cpu_dump_local_apic_state(CPUState *cs, FILE *f, fprintf_function cpu_fprintf, int flags); +/* cpu.c */ +bool cpu_is_bsp(X86CPU *cpu); + #endif /* CPU_I386_H */ -- cgit 1.4.1 From 77ac58ddc6be324abc3451ae78a1799efa7cc3b7 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Wed, 17 Sep 2014 12:21:29 +0200 Subject: dma: do not depend on kvm_enabled() Memory barriers are needed also by Xen and, when the ioeventfd bugs are fixed, by TCG as well. sysemu/kvm.h is not anymore needed in sysemu/dma.h, move it to the actual users. Signed-off-by: Paolo Bonzini --- hw/intc/arm_gicv2m.c | 1 + hw/intc/xics_kvm.c | 2 +- hw/misc/pci-testdev.c | 1 + hw/ppc/e500plat.c | 1 + hw/ppc/spapr_hcall.c | 1 + hw/ppc/spapr_pci.c | 1 + hw/ppc/spapr_rtas.c | 1 + include/sysemu/dma.h | 5 +---- 8 files changed, 8 insertions(+), 5 deletions(-) (limited to 'hw/intc') diff --git a/hw/intc/arm_gicv2m.c b/hw/intc/arm_gicv2m.c index e8b5177dcc..589d315c10 100644 --- a/hw/intc/arm_gicv2m.c +++ b/hw/intc/arm_gicv2m.c @@ -29,6 +29,7 @@ #include "qapi/error.h" #include "hw/sysbus.h" #include "hw/pci/msi.h" +#include "sysemu/kvm.h" #define TYPE_ARM_GICV2M "arm-gicv2m" #define ARM_GICV2M(obj) OBJECT_CHECK(ARMGICv2mState, (obj), TYPE_ARM_GICV2M) diff --git a/hw/intc/xics_kvm.c b/hw/intc/xics_kvm.c index b40292d050..55fd801ffd 100644 --- a/hw/intc/xics_kvm.c +++ b/hw/intc/xics_kvm.c @@ -31,7 +31,7 @@ #include "cpu.h" #include "hw/hw.h" #include "trace.h" -#include "linux/kvm.h" +#include "sysemu/kvm.h" #include "hw/ppc/spapr.h" #include "hw/ppc/xics.h" #include "kvm_ppc.h" diff --git a/hw/misc/pci-testdev.c b/hw/misc/pci-testdev.c index 2f2e989778..7d5990213e 100644 --- a/hw/misc/pci-testdev.c +++ b/hw/misc/pci-testdev.c @@ -21,6 +21,7 @@ #include "hw/hw.h" #include "hw/pci/pci.h" #include "qemu/event_notifier.h" +#include "sysemu/kvm.h" typedef struct PCITestDevHdr { uint8_t test; diff --git a/hw/ppc/e500plat.c b/hw/ppc/e500plat.c index b00565c3d3..94b454551f 100644 --- a/hw/ppc/e500plat.c +++ b/hw/ppc/e500plat.c @@ -14,6 +14,7 @@ #include "e500.h" #include "hw/boards.h" #include "sysemu/device_tree.h" +#include "sysemu/kvm.h" #include "hw/pci/pci.h" #include "hw/ppc/openpic.h" #include "kvm_ppc.h" diff --git a/hw/ppc/spapr_hcall.c b/hw/ppc/spapr_hcall.c index 8f40602a5e..4426a50e04 100644 --- a/hw/ppc/spapr_hcall.c +++ b/hw/ppc/spapr_hcall.c @@ -7,6 +7,7 @@ #include "mmu-hash64.h" #include "cpu-models.h" #include "trace.h" +#include "sysemu/kvm.h" #include "kvm_ppc.h" struct SPRSyncState { diff --git a/hw/ppc/spapr_pci.c b/hw/ppc/spapr_pci.c index 573e635bfb..e55b505c96 100644 --- a/hw/ppc/spapr_pci.c +++ b/hw/ppc/spapr_pci.c @@ -44,6 +44,7 @@ #include "hw/pci/pci_bus.h" #include "hw/ppc/spapr_drc.h" #include "sysemu/device_tree.h" +#include "sysemu/kvm.h" #include "hw/vfio/vfio.h" diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c index f07325831c..580829e2f1 100644 --- a/hw/ppc/spapr_rtas.c +++ b/hw/ppc/spapr_rtas.c @@ -31,6 +31,7 @@ #include "hw/qdev.h" #include "sysemu/device_tree.h" #include "sysemu/cpus.h" +#include "sysemu/kvm.h" #include "hw/ppc/spapr.h" #include "hw/ppc/spapr_vio.h" diff --git a/include/sysemu/dma.h b/include/sysemu/dma.h index 0f7cd4d3ce..d6e96a4298 100644 --- a/include/sysemu/dma.h +++ b/include/sysemu/dma.h @@ -15,7 +15,6 @@ #include "hw/hw.h" #include "block/block.h" #include "block/accounting.h" -#include "sysemu/kvm.h" typedef struct ScatterGatherEntry ScatterGatherEntry; @@ -67,9 +66,7 @@ static inline void dma_barrier(AddressSpace *as, DMADirection dir) * use lighter barriers based on the direction of the * transfer, the DMA context, etc... */ - if (kvm_enabled()) { - smp_mb(); - } + smp_mb(); } /* Checks that the given range of addresses is valid for DMA. This is -- cgit 1.4.1 From 33c11879fd422b759483ed25fef133ea900ea8d7 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Tue, 15 Mar 2016 16:58:45 +0100 Subject: qemu-common: push cpu.h inclusion out of qemu-common.h Signed-off-by: Paolo Bonzini --- arch_init.c | 2 ++ cpus.c | 3 ++- exec.c | 2 +- gdbstub.c | 2 +- hw/arm/nseries.c | 1 + hw/arm/pxa2xx_gpio.c | 1 + hw/core/nmi.c | 5 +++++ hw/display/cg3.c | 1 + hw/i386/kvm/apic.c | 2 ++ hw/i386/kvm/clock.c | 1 + hw/i386/kvmvapic.c | 2 ++ hw/intc/apic.c | 2 ++ hw/intc/apic_common.c | 2 ++ hw/intc/arm_gic_kvm.c | 2 ++ hw/intc/armv7m_nvic.c | 1 + hw/intc/openpic_kvm.c | 2 ++ hw/intc/s390_flic_kvm.c | 2 ++ hw/misc/mips_cpc.c | 1 + hw/misc/mips_itu.c | 1 + hw/ppc/ppc4xx_devs.c | 1 + hw/ppc/prep.c | 1 + hw/ppc/virtex_ml507.c | 1 + hw/xtensa/pic_cpu.c | 1 + include/disas/disas.h | 2 ++ include/exec/gdbstub.h | 2 ++ include/exec/hwaddr.h | 2 ++ include/hw/arm/digic.h | 1 + include/hw/arm/fsl-imx6.h | 1 + include/hw/arm/virt-acpi-build.h | 1 + include/hw/arm/virt.h | 1 + include/hw/hw.h | 1 - include/hw/sd/sd.h | 2 ++ include/hw/xen/xen.h | 7 ++++--- include/qemu-common.h | 5 ----- include/sysemu/kvm.h | 1 + ioport.c | 2 ++ memory.c | 2 ++ migration/ram.c | 2 ++ migration/savevm.c | 1 + monitor.c | 2 ++ qtest.c | 2 ++ scripts/tracetool/format/tcg_helper_c.py | 1 + target-alpha/gdbstub.c | 1 + target-alpha/machine.c | 2 ++ target-arm/gdbstub.c | 1 + target-arm/gdbstub64.c | 1 + target-arm/kvm-stub.c | 1 + target-arm/kvm32.c | 2 +- target-arm/kvm64.c | 2 +- target-arm/machine.c | 2 ++ target-cris/gdbstub.c | 1 + target-cris/machine.c | 2 ++ target-i386/gdbstub.c | 1 + target-i386/kvm-stub.c | 1 + target-i386/kvm.c | 2 +- target-i386/machine.c | 2 ++ target-lm32/gdbstub.c | 1 + target-lm32/machine.c | 2 ++ target-m68k/gdbstub.c | 1 + target-microblaze/gdbstub.c | 1 + target-mips/cpu.h | 18 ++---------------- target-mips/gdbstub.c | 1 + target-mips/helper.c | 17 +++++++++++++++++ target-mips/kvm.c | 2 +- target-mips/machine.c | 2 ++ target-moxie/machine.c | 2 ++ target-openrisc/gdbstub.c | 1 + target-openrisc/machine.c | 2 ++ target-ppc/gdbstub.c | 1 + target-ppc/kvm-stub.c | 1 + target-ppc/kvm.c | 2 +- target-ppc/machine.c | 2 ++ target-s390x/gdbstub.c | 1 + target-s390x/kvm.c | 2 +- target-sh4/gdbstub.c | 1 + target-sparc/gdbstub.c | 1 + target-sparc/machine.c | 2 ++ target-xtensa/gdbstub.c | 1 + tcg/optimize.c | 3 +-- tcg/tcg-op.c | 2 ++ tcg/tcg.h | 1 + xen-hvm.c | 1 + 82 files changed, 133 insertions(+), 36 deletions(-) (limited to 'hw/intc') diff --git a/arch_init.c b/arch_init.c index e3bb1b3ac4..07f047fad4 100644 --- a/arch_init.c +++ b/arch_init.c @@ -22,6 +22,8 @@ * THE SOFTWARE. */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "sysemu/sysemu.h" #include "sysemu/arch_init.h" #include "hw/pci/pci.h" diff --git a/cpus.c b/cpus.c index cbeb1f6139..7b6ebebde7 100644 --- a/cpus.c +++ b/cpus.c @@ -24,7 +24,8 @@ /* Needed early for CONFIG_BSD etc. */ #include "qemu/osdep.h" - +#include "qemu-common.h" +#include "cpu.h" #include "monitor/monitor.h" #include "qapi/qmp/qerror.h" #include "qemu/error-report.h" diff --git a/exec.c b/exec.c index ed10ba1af1..d26df55706 100644 --- a/exec.c +++ b/exec.c @@ -28,10 +28,10 @@ #include "hw/qdev-core.h" #if !defined(CONFIG_USER_ONLY) #include "hw/boards.h" +#include "hw/xen/xen.h" #endif #include "sysemu/kvm.h" #include "sysemu/sysemu.h" -#include "hw/xen/xen.h" #include "qemu/timer.h" #include "qemu/config-file.h" #include "qemu/error-report.h" diff --git a/gdbstub.c b/gdbstub.c index 0e431fd4df..c19ce39bdc 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -19,7 +19,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "qemu/cutils.h" - +#include "cpu.h" #ifdef CONFIG_USER_ONLY #include "qemu.h" #else diff --git a/hw/arm/nseries.c b/hw/arm/nseries.c index f3a9b1a826..6131c345b1 100644 --- a/hw/arm/nseries.c +++ b/hw/arm/nseries.c @@ -20,6 +20,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "cpu.h" #include "qemu/cutils.h" #include "qemu/bswap.h" #include "sysemu/sysemu.h" diff --git a/hw/arm/pxa2xx_gpio.c b/hw/arm/pxa2xx_gpio.c index 67e7e70943..8c9626e9f2 100644 --- a/hw/arm/pxa2xx_gpio.c +++ b/hw/arm/pxa2xx_gpio.c @@ -8,6 +8,7 @@ */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/sysbus.h" #include "hw/arm/pxa.h" diff --git a/hw/core/nmi.c b/hw/core/nmi.c index e8bcc4177b..f616a79312 100644 --- a/hw/core/nmi.c +++ b/hw/core/nmi.c @@ -20,11 +20,16 @@ */ #include "qemu/osdep.h" +#include "qom/cpu.h" #include "hw/nmi.h" #include "qapi/error.h" #include "qapi/qmp/qerror.h" #include "monitor/monitor.h" +#if defined(TARGET_I386) +#include "cpu.h" +#endif + struct do_nmi_s { int cpu_index; Error *err; diff --git a/hw/display/cg3.c b/hw/display/cg3.c index fc0d97fa4b..eb0e71a90a 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -26,6 +26,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "qemu-common.h" +#include "cpu.h" #include "qemu/error-report.h" #include "ui/console.h" #include "hw/sysbus.h" diff --git a/hw/i386/kvm/apic.c b/hw/i386/kvm/apic.c index 3c7c8fa007..c5983c79be 100644 --- a/hw/i386/kvm/apic.c +++ b/hw/i386/kvm/apic.c @@ -10,6 +10,8 @@ * See the COPYING file in the top-level directory. */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/i386/apic_internal.h" #include "hw/pci/msi.h" #include "sysemu/kvm.h" diff --git a/hw/i386/kvm/clock.c b/hw/i386/kvm/clock.c index a3b300cadf..0f75dd385a 100644 --- a/hw/i386/kvm/clock.c +++ b/hw/i386/kvm/clock.c @@ -15,6 +15,7 @@ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "qemu/host-utils.h" #include "sysemu/sysemu.h" #include "sysemu/kvm.h" diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c index f14445d4fb..466c3c4cd7 100644 --- a/hw/i386/kvmvapic.c +++ b/hw/i386/kvmvapic.c @@ -9,6 +9,8 @@ * top-level directory. */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "sysemu/sysemu.h" #include "sysemu/cpus.h" #include "sysemu/kvm.h" diff --git a/hw/intc/apic.c b/hw/intc/apic.c index 28c2ea5406..e1ab9354c6 100644 --- a/hw/intc/apic.c +++ b/hw/intc/apic.c @@ -17,6 +17,8 @@ * License along with this library; if not, see */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "qemu/thread.h" #include "hw/i386/apic_internal.h" #include "hw/i386/apic.h" diff --git a/hw/intc/apic_common.c b/hw/intc/apic_common.c index 4abe145c68..e6eb694de0 100644 --- a/hw/intc/apic_common.c +++ b/hw/intc/apic_common.c @@ -19,6 +19,8 @@ */ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/i386/apic.h" #include "hw/i386/apic_internal.h" #include "trace.h" diff --git a/hw/intc/arm_gic_kvm.c b/hw/intc/arm_gic_kvm.c index bc85ab769f..5593cdb3e4 100644 --- a/hw/intc/arm_gic_kvm.c +++ b/hw/intc/arm_gic_kvm.c @@ -21,6 +21,8 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/sysbus.h" #include "migration/migration.h" #include "sysemu/kvm.h" diff --git a/hw/intc/armv7m_nvic.c b/hw/intc/armv7m_nvic.c index 669e82adfc..4d584ef74c 100644 --- a/hw/intc/armv7m_nvic.c +++ b/hw/intc/armv7m_nvic.c @@ -13,6 +13,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "qemu-common.h" +#include "cpu.h" #include "hw/sysbus.h" #include "qemu/timer.h" #include "hw/arm/arm.h" diff --git a/hw/intc/openpic_kvm.c b/hw/intc/openpic_kvm.c index e47e94f2cf..0518e017c4 100644 --- a/hw/intc/openpic_kvm.c +++ b/hw/intc/openpic_kvm.c @@ -24,6 +24,8 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu-common.h" +#include "cpu.h" #include #include "exec/address-spaces.h" #include "hw/hw.h" diff --git a/hw/intc/s390_flic_kvm.c b/hw/intc/s390_flic_kvm.c index 02449b390e..eed6325cde 100644 --- a/hw/intc/s390_flic_kvm.c +++ b/hw/intc/s390_flic_kvm.c @@ -11,6 +11,8 @@ */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include #include "qemu/error-report.h" #include "hw/sysbus.h" diff --git a/hw/misc/mips_cpc.c b/hw/misc/mips_cpc.c index d2b8e42da7..05688b7c4b 100644 --- a/hw/misc/mips_cpc.c +++ b/hw/misc/mips_cpc.c @@ -19,6 +19,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "cpu.h" #include "hw/sysbus.h" #include "hw/misc/mips_cpc.h" diff --git a/hw/misc/mips_itu.c b/hw/misc/mips_itu.c index da5455062d..c1a44537a3 100644 --- a/hw/misc/mips_itu.c +++ b/hw/misc/mips_itu.c @@ -19,6 +19,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/sysbus.h" #include "sysemu/sysemu.h" diff --git a/hw/ppc/ppc4xx_devs.c b/hw/ppc/ppc4xx_devs.c index 7d59018fc2..e7f413e49d 100644 --- a/hw/ppc/ppc4xx_devs.c +++ b/hw/ppc/ppc4xx_devs.c @@ -22,6 +22,7 @@ * THE SOFTWARE. */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/ppc/ppc.h" #include "hw/ppc/ppc4xx.h" diff --git a/hw/ppc/prep.c b/hw/ppc/prep.c index 3ffb85e601..07ffe72de1 100644 --- a/hw/ppc/prep.c +++ b/hw/ppc/prep.c @@ -22,6 +22,7 @@ * THE SOFTWARE. */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/timer/m48t59.h" #include "hw/i386/pc.h" diff --git a/hw/ppc/virtex_ml507.c b/hw/ppc/virtex_ml507.c index b807a08c28..b97d96685c 100644 --- a/hw/ppc/virtex_ml507.c +++ b/hw/ppc/virtex_ml507.c @@ -23,6 +23,7 @@ */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/sysbus.h" #include "hw/hw.h" #include "hw/char/serial.h" diff --git a/hw/xtensa/pic_cpu.c b/hw/xtensa/pic_cpu.c index c835bd0096..ccf65fd8ad 100644 --- a/hw/xtensa/pic_cpu.c +++ b/hw/xtensa/pic_cpu.c @@ -26,6 +26,7 @@ */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/hw.h" #include "qemu/log.h" #include "qemu/timer.h" diff --git a/include/disas/disas.h b/include/disas/disas.h index 2b9293b62a..4930d78ac4 100644 --- a/include/disas/disas.h +++ b/include/disas/disas.h @@ -4,6 +4,8 @@ #include "qemu-common.h" #ifdef NEED_CPU_H +#include "cpu.h" + /* Disassemble this for me please... (debugging). */ void disas(FILE *out, void *code, unsigned long size); void target_disas(FILE *out, CPUState *cpu, target_ulong code, diff --git a/include/exec/gdbstub.h b/include/exec/gdbstub.h index d9e8cf7715..8e3f8d8176 100644 --- a/include/exec/gdbstub.h +++ b/include/exec/gdbstub.h @@ -11,6 +11,8 @@ #define GDB_WATCHPOINT_ACCESS 4 #ifdef NEED_CPU_H +#include "cpu.h" + typedef void (*gdb_syscall_complete_cb)(CPUState *cpu, target_ulong ret, target_ulong err); diff --git a/include/exec/hwaddr.h b/include/exec/hwaddr.h index c9eb78fba1..bb41588b9d 100644 --- a/include/exec/hwaddr.h +++ b/include/exec/hwaddr.h @@ -3,6 +3,8 @@ #ifndef HWADDR_H #define HWADDR_H +#include + #define HWADDR_BITS 64 /* hwaddr is the type of a physical address (its size can be different from 'target_ulong'). */ diff --git a/include/hw/arm/digic.h b/include/hw/arm/digic.h index aaefe0b470..63785baaa8 100644 --- a/include/hw/arm/digic.h +++ b/include/hw/arm/digic.h @@ -18,6 +18,7 @@ #ifndef HW_ARM_DIGIC_H #define HW_ARM_DIGIC_H +#include "cpu.h" #include "hw/timer/digic-timer.h" #include "hw/char/digic-uart.h" diff --git a/include/hw/arm/fsl-imx6.h b/include/hw/arm/fsl-imx6.h index d24aaee1c1..e9157ea4b3 100644 --- a/include/hw/arm/fsl-imx6.h +++ b/include/hw/arm/fsl-imx6.h @@ -29,6 +29,7 @@ #include "hw/sd/sdhci.h" #include "hw/ssi/imx_spi.h" #include "exec/memory.h" +#include "cpu.h" #define TYPE_FSL_IMX6 "fsl,imx6" #define FSL_IMX6(obj) OBJECT_CHECK(FslIMX6State, (obj), TYPE_FSL_IMX6) diff --git a/include/hw/arm/virt-acpi-build.h b/include/hw/arm/virt-acpi-build.h index 7d3700ebf6..e43330ad65 100644 --- a/include/hw/arm/virt-acpi-build.h +++ b/include/hw/arm/virt-acpi-build.h @@ -22,6 +22,7 @@ #include "qemu-common.h" #include "hw/arm/virt.h" +#include "qemu/notify.h" #define ACPI_GICC_ENABLED 1 diff --git a/include/hw/arm/virt.h b/include/hw/arm/virt.h index ecd8589603..82703d2ecd 100644 --- a/include/hw/arm/virt.h +++ b/include/hw/arm/virt.h @@ -31,6 +31,7 @@ #define QEMU_ARM_VIRT_H #include "qemu-common.h" +#include "exec/hwaddr.h" #define NUM_GICV2M_SPIS 64 #define NUM_VIRTIO_TRANSPORTS 32 diff --git a/include/hw/hw.h b/include/hw/hw.h index 29931d1e43..a20321bada 100644 --- a/include/hw/hw.h +++ b/include/hw/hw.h @@ -2,7 +2,6 @@ #ifndef QEMU_HW_H #define QEMU_HW_H - #ifdef CONFIG_USER_ONLY #error Cannot include hw/hw.h from user emulation #endif diff --git a/include/hw/sd/sd.h b/include/hw/sd/sd.h index d5d273a449..c8a4b98d5d 100644 --- a/include/hw/sd/sd.h +++ b/include/hw/sd/sd.h @@ -29,6 +29,8 @@ #ifndef __hw_sd_h #define __hw_sd_h 1 +#include "hw/qdev.h" + #define OUT_OF_RANGE (1 << 31) #define ADDRESS_ERROR (1 << 30) #define BLOCK_LEN_ERROR (1 << 29) diff --git a/include/hw/xen/xen.h b/include/hw/xen/xen.h index 6eb815aace..6365483473 100644 --- a/include/hw/xen/xen.h +++ b/include/hw/xen/xen.h @@ -7,8 +7,10 @@ * /usr/include/xen, so it can be included unconditionally. */ -#include "hw/irq.h" #include "qemu-common.h" +#include "qemu/typedefs.h" +#include "exec/cpu-common.h" +#include "hw/irq.h" /* xen-machine.c */ enum xen_mode { @@ -37,12 +39,11 @@ qemu_irq *xen_interrupt_controller_init(void); void xenstore_store_pv_console_info(int i, struct CharDriverState *chr); -#if defined(NEED_CPU_H) && !defined(CONFIG_USER_ONLY) void xen_hvm_init(PCMachineState *pcms, MemoryRegion **ram_memory); + void xen_ram_alloc(ram_addr_t ram_addr, ram_addr_t size, struct MemoryRegion *mr, Error **errp); void xen_modified_memory(ram_addr_t start, ram_addr_t length); -#endif void xen_register_framebuffer(struct MemoryRegion *mr); diff --git a/include/qemu-common.h b/include/qemu-common.h index cd3139b2df..835cbc68b8 100644 --- a/include/qemu-common.h +++ b/include/qemu-common.h @@ -22,11 +22,6 @@ #include "qemu/option.h" -/* FIXME: Remove NEED_CPU_H. */ -#ifdef NEED_CPU_H -#include "cpu.h" -#endif /* !defined(NEED_CPU_H) */ - /* main function, renamed */ #if defined(CONFIG_COCOA) int qemu_main(int argc, char **argv, char **envp); diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm.h index 0e18f15c94..f9f00e2e56 100644 --- a/include/sysemu/kvm.h +++ b/include/sysemu/kvm.h @@ -218,6 +218,7 @@ int kvm_init_vcpu(CPUState *cpu); int kvm_cpu_exec(CPUState *cpu); #ifdef NEED_CPU_H +#include "cpu.h" void kvm_setup_guest_memory(void *start, size_t size); void kvm_flush_coalesced_mmio_buffer(void); diff --git a/ioport.c b/ioport.c index 7a84d5444e..901a997793 100644 --- a/ioport.c +++ b/ioport.c @@ -26,6 +26,8 @@ */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "exec/ioport.h" #include "trace.h" #include "exec/memory.h" diff --git a/memory.c b/memory.c index f76f85df95..a8ef85261f 100644 --- a/memory.c +++ b/memory.c @@ -15,6 +15,8 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu-common.h" +#include "cpu.h" #include "exec/memory.h" #include "exec/address-spaces.h" #include "exec/ioport.h" diff --git a/migration/ram.c b/migration/ram.c index 88fbffcce4..5e88080faf 100644 --- a/migration/ram.c +++ b/migration/ram.c @@ -26,6 +26,8 @@ * THE SOFTWARE. */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include #include "qapi-event.h" #include "qemu/cutils.h" diff --git a/migration/savevm.c b/migration/savevm.c index 16ba443798..bfb3d9178f 100644 --- a/migration/savevm.c +++ b/migration/savevm.c @@ -27,6 +27,7 @@ */ #include "qemu/osdep.h" +#include "cpu.h" #include "hw/boards.h" #include "hw/hw.h" #include "hw/qdev.h" diff --git a/monitor.c b/monitor.c index d1c193013e..812383ff4d 100644 --- a/monitor.c +++ b/monitor.c @@ -23,6 +23,8 @@ */ #include "qemu/osdep.h" #include +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "monitor/qdev.h" #include "hw/usb.h" diff --git a/qtest.c b/qtest.c index 87575bc0b4..da4826c69f 100644 --- a/qtest.c +++ b/qtest.c @@ -13,6 +13,8 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu-common.h" +#include "cpu.h" #include "sysemu/qtest.h" #include "hw/qdev.h" #include "sysemu/char.h" diff --git a/scripts/tracetool/format/tcg_helper_c.py b/scripts/tracetool/format/tcg_helper_c.py index a089b0bf05..e3485b7f92 100644 --- a/scripts/tracetool/format/tcg_helper_c.py +++ b/scripts/tracetool/format/tcg_helper_c.py @@ -48,6 +48,7 @@ def generate(events, backend): '', '#include "qemu/osdep.h"', '#include "qemu-common.h"', + '#include "cpu.h"', '#include "trace.h"', '#include "exec/helper-proto.h"', '', diff --git a/target-alpha/gdbstub.c b/target-alpha/gdbstub.c index 199f028425..d64bcccfa0 100644 --- a/target-alpha/gdbstub.c +++ b/target-alpha/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int alpha_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-alpha/machine.c b/target-alpha/machine.c index 3f72943ca6..710b7835b4 100644 --- a/target-alpha/machine.c +++ b/target-alpha/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "migration/cpu.h" diff --git a/target-arm/gdbstub.c b/target-arm/gdbstub.c index 3ba9aadd48..04c1208d03 100644 --- a/target-arm/gdbstub.c +++ b/target-arm/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" /* Old gdb always expect FPA registers. Newer (xml-aware) gdb only expect diff --git a/target-arm/gdbstub64.c b/target-arm/gdbstub64.c index 634c6bc6f2..49bc3fc521 100644 --- a/target-arm/gdbstub64.c +++ b/target-arm/gdbstub64.c @@ -18,6 +18,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int aarch64_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-arm/kvm-stub.c b/target-arm/kvm-stub.c index 38bf433876..b2c66df532 100644 --- a/target-arm/kvm-stub.c +++ b/target-arm/kvm-stub.c @@ -11,6 +11,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "kvm_arm.h" bool write_kvmstate_to_list(ARMCPU *cpu) diff --git a/target-arm/kvm32.c b/target-arm/kvm32.c index d44a7f92b6..7f5935ab13 100644 --- a/target-arm/kvm32.c +++ b/target-arm/kvm32.c @@ -15,11 +15,11 @@ #include #include "qemu-common.h" +#include "cpu.h" #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "sysemu/kvm.h" #include "kvm_arm.h" -#include "cpu.h" #include "internals.h" #include "hw/arm/arm.h" diff --git a/target-arm/kvm64.c b/target-arm/kvm64.c index e8527bf0cc..e2a34f67a4 100644 --- a/target-arm/kvm64.c +++ b/target-arm/kvm64.c @@ -18,6 +18,7 @@ #include #include "qemu-common.h" +#include "cpu.h" #include "qemu/timer.h" #include "qemu/error-report.h" #include "qemu/host-utils.h" @@ -25,7 +26,6 @@ #include "sysemu/sysemu.h" #include "sysemu/kvm.h" #include "kvm_arm.h" -#include "cpu.h" #include "internals.h" #include "hw/arm/arm.h" diff --git a/target-arm/machine.c b/target-arm/machine.c index c23feb18d6..2f452603f1 100644 --- a/target-arm/machine.c +++ b/target-arm/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "qemu/error-report.h" diff --git a/target-cris/gdbstub.c b/target-cris/gdbstub.c index 1bbf17b04a..3a72ee2a98 100644 --- a/target-cris/gdbstub.c +++ b/target-cris/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int crisv10_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-cris/machine.c b/target-cris/machine.c index 4c9287f310..6b797e8c1d 100644 --- a/target-cris/machine.c +++ b/target-cris/machine.c @@ -19,6 +19,8 @@ */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "migration/cpu.h" diff --git a/target-i386/gdbstub.c b/target-i386/gdbstub.c index 4b5071398f..c494535df1 100644 --- a/target-i386/gdbstub.c +++ b/target-i386/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" #ifdef TARGET_X86_64 diff --git a/target-i386/kvm-stub.c b/target-i386/kvm-stub.c index 8df9c5953f..cdf1506109 100644 --- a/target-i386/kvm-stub.c +++ b/target-i386/kvm-stub.c @@ -11,6 +11,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "kvm_i386.h" bool kvm_allows_irq0_override(void) diff --git a/target-i386/kvm.c b/target-i386/kvm.c index 799fdfa682..c76e7bbc89 100644 --- a/target-i386/kvm.c +++ b/target-i386/kvm.c @@ -22,10 +22,10 @@ #include #include "qemu-common.h" +#include "cpu.h" #include "sysemu/sysemu.h" #include "sysemu/kvm_int.h" #include "kvm_i386.h" -#include "cpu.h" #include "hyperv.h" #include "exec/gdbstub.h" diff --git a/target-i386/machine.c b/target-i386/machine.c index 57203b2fd3..658b066da0 100644 --- a/target-i386/machine.c +++ b/target-i386/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "hw/i386/pc.h" diff --git a/target-lm32/gdbstub.c b/target-lm32/gdbstub.c index 8ac1288bb6..cf929dd392 100644 --- a/target-lm32/gdbstub.c +++ b/target-lm32/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" #include "hw/lm32/lm32_pic.h" diff --git a/target-lm32/machine.c b/target-lm32/machine.c index 6f562161ce..3c258a4bcc 100644 --- a/target-lm32/machine.c +++ b/target-lm32/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "migration/cpu.h" diff --git a/target-m68k/gdbstub.c b/target-m68k/gdbstub.c index f02bb5caf4..c7f44c9bb3 100644 --- a/target-m68k/gdbstub.c +++ b/target-m68k/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int m68k_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-microblaze/gdbstub.c b/target-microblaze/gdbstub.c index 89d38980bf..7fb076c2e9 100644 --- a/target-microblaze/gdbstub.c +++ b/target-microblaze/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int mb_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-mips/cpu.h b/target-mips/cpu.h index c65f84e948..a7c8660d47 100644 --- a/target-mips/cpu.h +++ b/target-mips/cpu.h @@ -1145,22 +1145,8 @@ static inline void cpu_mips_store_cause(CPUMIPSState *env, target_ulong val) } #endif -static inline void QEMU_NORETURN do_raise_exception_err(CPUMIPSState *env, - uint32_t exception, - int error_code, - uintptr_t pc) -{ - CPUState *cs = CPU(mips_env_get_cpu(env)); - - if (exception < EXCP_SC) { - qemu_log_mask(CPU_LOG_INT, "%s: %d %d\n", - __func__, exception, error_code); - } - cs->exception_index = exception; - env->error_code = error_code; - - cpu_loop_exit_restore(cs, pc); -} +void QEMU_NORETURN do_raise_exception_err(CPUMIPSState *env, uint32_t exception, + int error_code, uintptr_t pc); static inline void QEMU_NORETURN do_raise_exception(CPUMIPSState *env, uint32_t exception, diff --git a/target-mips/gdbstub.c b/target-mips/gdbstub.c index b0b4a32ec0..2707ff5c2b 100644 --- a/target-mips/gdbstub.c +++ b/target-mips/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int mips_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-mips/helper.c b/target-mips/helper.c index cfea177ee5..1f35e7ff87 100644 --- a/target-mips/helper.c +++ b/target-mips/helper.c @@ -840,3 +840,20 @@ void r4k_invalidate_tlb (CPUMIPSState *env, int idx, int use_extra) } } #endif + +void QEMU_NORETURN do_raise_exception_err(CPUMIPSState *env, + uint32_t exception, + int error_code, + uintptr_t pc) +{ + CPUState *cs = CPU(mips_env_get_cpu(env)); + + if (exception < EXCP_SC) { + qemu_log_mask(CPU_LOG_INT, "%s: %d %d\n", + __func__, exception, error_code); + } + cs->exception_index = exception; + env->error_code = error_code; + + cpu_loop_exit_restore(cs, pc); +} diff --git a/target-mips/kvm.c b/target-mips/kvm.c index 950bc05b7c..a854e4de59 100644 --- a/target-mips/kvm.c +++ b/target-mips/kvm.c @@ -16,11 +16,11 @@ #include #include "qemu-common.h" +#include "cpu.h" #include "qemu/error-report.h" #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "sysemu/kvm.h" -#include "cpu.h" #include "sysemu/cpus.h" #include "kvm_mips.h" #include "exec/memattrs.h" diff --git a/target-mips/machine.c b/target-mips/machine.c index eb3d916ef3..7314cfe8c7 100644 --- a/target-mips/machine.c +++ b/target-mips/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "cpu.h" #include "migration/cpu.h" diff --git a/target-moxie/machine.c b/target-moxie/machine.c index 7810e1cd2b..282dcd869f 100644 --- a/target-moxie/machine.c +++ b/target-moxie/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "machine.h" diff --git a/target-openrisc/gdbstub.c b/target-openrisc/gdbstub.c index edc301a7c5..cb16e76358 100644 --- a/target-openrisc/gdbstub.c +++ b/target-openrisc/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int openrisc_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/target-openrisc/machine.c b/target-openrisc/machine.c index bd5d50f338..17b0c77d6c 100644 --- a/target-openrisc/machine.c +++ b/target-openrisc/machine.c @@ -18,6 +18,8 @@ */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "migration/cpu.h" diff --git a/target-ppc/gdbstub.c b/target-ppc/gdbstub.c index 569c380cfa..7a338136a8 100644 --- a/target-ppc/gdbstub.c +++ b/target-ppc/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" static int ppc_gdb_register_len_apple(int n) diff --git a/target-ppc/kvm-stub.c b/target-ppc/kvm-stub.c index 627bcb4322..efeafca1df 100644 --- a/target-ppc/kvm-stub.c +++ b/target-ppc/kvm-stub.c @@ -11,6 +11,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "hw/ppc/openpic.h" int kvm_openpic_connect_vcpu(DeviceState *d, CPUState *cs) diff --git a/target-ppc/kvm.c b/target-ppc/kvm.c index c4c81467e4..24d6032007 100644 --- a/target-ppc/kvm.c +++ b/target-ppc/kvm.c @@ -24,11 +24,11 @@ #include "qemu-common.h" #include "qemu/error-report.h" +#include "cpu.h" #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "sysemu/kvm.h" #include "kvm_ppc.h" -#include "cpu.h" #include "sysemu/cpus.h" #include "sysemu/device_tree.h" #include "mmu-hash64.h" diff --git a/target-ppc/machine.c b/target-ppc/machine.c index c0b91823a9..4911cb7139 100644 --- a/target-ppc/machine.c +++ b/target-ppc/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "sysemu/kvm.h" diff --git a/target-s390x/gdbstub.c b/target-s390x/gdbstub.c index 9fc36cb54e..0992ae722b 100644 --- a/target-s390x/gdbstub.c +++ b/target-s390x/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" #include "qemu/bitops.h" diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c index 55ae6d3304..8f46fd0f10 100644 --- a/target-s390x/kvm.c +++ b/target-s390x/kvm.c @@ -29,12 +29,12 @@ #include #include "qemu-common.h" +#include "cpu.h" #include "qemu/error-report.h" #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "sysemu/kvm.h" #include "hw/hw.h" -#include "cpu.h" #include "sysemu/device_tree.h" #include "qapi/qmp/qjson.h" #include "exec/gdbstub.h" diff --git a/target-sh4/gdbstub.c b/target-sh4/gdbstub.c index 1b59ea8c73..13bea00d7d 100644 --- a/target-sh4/gdbstub.c +++ b/target-sh4/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" /* Hint: Use "set architecture sh4" in GDB to see fpu registers */ diff --git a/target-sparc/gdbstub.c b/target-sparc/gdbstub.c index e530dc52f5..ffc2baa2e7 100644 --- a/target-sparc/gdbstub.c +++ b/target-sparc/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" #ifdef TARGET_ABI32 diff --git a/target-sparc/machine.c b/target-sparc/machine.c index 04806f6728..c8823af951 100644 --- a/target-sparc/machine.c +++ b/target-sparc/machine.c @@ -1,4 +1,6 @@ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "hw/hw.h" #include "hw/boards.h" #include "qemu/timer.h" diff --git a/target-xtensa/gdbstub.c b/target-xtensa/gdbstub.c index 51d4db0836..bfcd591409 100644 --- a/target-xtensa/gdbstub.c +++ b/target-xtensa/gdbstub.c @@ -19,6 +19,7 @@ */ #include "qemu/osdep.h" #include "qemu-common.h" +#include "cpu.h" #include "exec/gdbstub.h" int xtensa_cpu_gdb_read_register(CPUState *cs, uint8_t *mem_buf, int n) diff --git a/tcg/optimize.c b/tcg/optimize.c index f01160815c..def4ba6913 100644 --- a/tcg/optimize.c +++ b/tcg/optimize.c @@ -24,9 +24,8 @@ */ #include "qemu/osdep.h" - - #include "qemu-common.h" +#include "cpu.h" #include "tcg-op.h" #define CASE_OP_32_64(x) \ diff --git a/tcg/tcg-op.c b/tcg/tcg-op.c index f554b86d40..7a159142e6 100644 --- a/tcg/tcg-op.c +++ b/tcg/tcg-op.c @@ -23,6 +23,8 @@ */ #include "qemu/osdep.h" +#include "qemu-common.h" +#include "cpu.h" #include "tcg.h" #include "tcg-op.h" diff --git a/tcg/tcg.h b/tcg/tcg.h index a013d77a33..8abf318343 100644 --- a/tcg/tcg.h +++ b/tcg/tcg.h @@ -26,6 +26,7 @@ #define TCG_H #include "qemu-common.h" +#include "cpu.h" #include "qemu/bitops.h" #include "tcg-target.h" diff --git a/xen-hvm.c b/xen-hvm.c index 039680a6d9..4236f78ad8 100644 --- a/xen-hvm.c +++ b/xen-hvm.c @@ -11,6 +11,7 @@ #include "qemu/osdep.h" #include +#include "cpu.h" #include "hw/pci/pci.h" #include "hw/i386/pc.h" #include "hw/i386/apic-msidef.h" -- cgit 1.4.1 From 03dd024ff57733a55cd2e455f361d053c81b1b29 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Tue, 15 Dec 2015 13:16:16 +0100 Subject: hw: explicitly include qemu/log.h Move the inclusion out of hw/hw.h, most files do not need it. Signed-off-by: Paolo Bonzini --- hw/arm/ast2400.c | 1 + hw/arm/nseries.c | 1 + hw/arm/palmetto-bmc.c | 1 + hw/arm/pxa2xx_gpio.c | 1 + hw/arm/stellaris.c | 1 + hw/arm/strongarm.c | 1 + hw/arm/xlnx-ep108.c | 1 + hw/audio/pl041.c | 1 + hw/block/m25p80.c | 1 + hw/block/pflash_cfi01.c | 1 + hw/char/bcm2835_aux.c | 1 + hw/char/cadence_uart.c | 4 ++++ hw/char/digic-uart.c | 1 + hw/char/imx_serial.c | 1 + hw/char/pl011.c | 1 + hw/char/stm32f2xx_usart.c | 1 + hw/display/bcm2835_fb.c | 1 + hw/display/cg3.c | 1 + hw/display/pl110.c | 1 + hw/display/virtio-gpu.c | 1 + hw/dma/bcm2835_dma.c | 1 + hw/dma/pl080.c | 1 + hw/dma/pl330.c | 1 + hw/dma/rc4030.c | 1 + hw/gpio/imx_gpio.c | 1 + hw/gpio/pl061.c | 1 + hw/i2c/imx_i2c.c | 1 + hw/i2c/versatile_i2c.c | 1 + hw/input/pl050.c | 1 + hw/intc/allwinner-a10-pic.c | 1 + hw/intc/arm_gic.c | 1 + hw/intc/arm_gicv2m.c | 1 + hw/intc/armv7m_nvic.c | 1 + hw/intc/bcm2835_ic.c | 1 + hw/intc/bcm2836_control.c | 1 + hw/intc/i8259.c | 1 + hw/intc/imx_avic.c | 1 + hw/intc/openpic.c | 1 + hw/intc/pl190.c | 1 + hw/misc/arm11scu.c | 1 + hw/misc/arm_integrator_debug.c | 1 + hw/misc/arm_l2x0.c | 1 + hw/misc/arm_sysctl.c | 1 + hw/misc/bcm2835_mbox.c | 1 + hw/misc/bcm2835_property.c | 1 + hw/misc/imx25_ccm.c | 1 + hw/misc/imx31_ccm.c | 1 + hw/misc/imx6_ccm.c | 1 + hw/misc/imx6_src.c | 1 + hw/misc/imx_ccm.c | 1 + hw/misc/macio/cuda.c | 1 + hw/misc/macio/mac_dbdma.c | 1 + hw/misc/mips_cmgcr.c | 1 + hw/misc/mips_cpc.c | 1 + hw/misc/mips_itu.c | 1 + hw/misc/stm32f2xx_syscfg.c | 1 + hw/misc/zynq-xadc.c | 1 + hw/misc/zynq_slcr.c | 1 + hw/net/allwinner_emac.c | 1 + hw/net/fsl_etsec/etsec.c | 1 + hw/net/fsl_etsec/rings.c | 2 +- hw/net/imx_fec.c | 1 + hw/net/lan9118.c | 1 + hw/net/spapr_llan.c | 1 + hw/pci-host/apb.c | 1 + hw/pci-host/versatile.c | 1 + hw/ppc/spapr.c | 1 + hw/ppc/spapr_hcall.c | 1 + hw/ppc/spapr_iommu.c | 1 + hw/ppc/spapr_rtas.c | 1 + hw/ppc/spapr_vio.c | 1 + hw/sd/pl181.c | 1 + hw/sd/sd.c | 1 + hw/sd/sdhci.c | 1 + hw/ssi/imx_spi.c | 1 + hw/ssi/pl022.c | 1 + hw/timer/allwinner-a10-pit.c | 1 + hw/timer/arm_timer.c | 1 + hw/timer/digic-timer.c | 1 + hw/timer/imx_epit.c | 1 + hw/timer/imx_gpt.c | 1 + hw/timer/pl031.c | 1 + hw/timer/stm32f2xx_timer.c | 1 + hw/watchdog/wdt_diag288.c | 1 + include/hw/hw.h | 1 - monitor.c | 1 + target-arm/arm-powerctl.c | 1 + target-arm/kvm.c | 1 + target-arm/kvm32.c | 1 + vl.c | 1 + 90 files changed, 92 insertions(+), 2 deletions(-) (limited to 'hw/intc') diff --git a/hw/arm/ast2400.c b/hw/arm/ast2400.c index 03f993863b..5510a8a374 100644 --- a/hw/arm/ast2400.c +++ b/hw/arm/ast2400.c @@ -17,6 +17,7 @@ #include "exec/address-spaces.h" #include "hw/arm/ast2400.h" #include "hw/char/serial.h" +#include "qemu/log.h" #define AST2400_UART_5_BASE 0x00184000 #define AST2400_IOMEM_SIZE 0x00200000 diff --git a/hw/arm/nseries.c b/hw/arm/nseries.c index 6131c345b1..d4eb141764 100644 --- a/hw/arm/nseries.c +++ b/hw/arm/nseries.c @@ -37,6 +37,7 @@ #include "hw/loader.h" #include "sysemu/block-backend.h" #include "hw/sysbus.h" +#include "qemu/log.h" #include "exec/address-spaces.h" /* Nokia N8x0 support */ diff --git a/hw/arm/palmetto-bmc.c b/hw/arm/palmetto-bmc.c index 89ebd92b93..a51d960510 100644 --- a/hw/arm/palmetto-bmc.c +++ b/hw/arm/palmetto-bmc.c @@ -17,6 +17,7 @@ #include "hw/arm/arm.h" #include "hw/arm/ast2400.h" #include "hw/boards.h" +#include "qemu/log.h" static struct arm_boot_info palmetto_bmc_binfo = { .loader_start = AST2400_SDRAM_BASE, diff --git a/hw/arm/pxa2xx_gpio.c b/hw/arm/pxa2xx_gpio.c index 8c9626e9f2..576a8eb91f 100644 --- a/hw/arm/pxa2xx_gpio.c +++ b/hw/arm/pxa2xx_gpio.c @@ -12,6 +12,7 @@ #include "hw/hw.h" #include "hw/sysbus.h" #include "hw/arm/pxa.h" +#include "qemu/log.h" #define PXA2XX_GPIO_BANKS 4 diff --git a/hw/arm/stellaris.c b/hw/arm/stellaris.c index f90b9fd190..44591716fe 100644 --- a/hw/arm/stellaris.c +++ b/hw/arm/stellaris.c @@ -17,6 +17,7 @@ #include "hw/i2c/i2c.h" #include "net/net.h" #include "hw/boards.h" +#include "qemu/log.h" #include "exec/address-spaces.h" #include "sysemu/sysemu.h" diff --git a/hw/arm/strongarm.c b/hw/arm/strongarm.c index 3bc8a98150..f1b2c6c966 100644 --- a/hw/arm/strongarm.c +++ b/hw/arm/strongarm.c @@ -38,6 +38,7 @@ #include "sysemu/sysemu.h" #include "hw/ssi/ssi.h" #include "qemu/cutils.h" +#include "qemu/log.h" //#define DEBUG diff --git a/hw/arm/xlnx-ep108.c b/hw/arm/xlnx-ep108.c index 5f480182b2..40f7cc1425 100644 --- a/hw/arm/xlnx-ep108.c +++ b/hw/arm/xlnx-ep108.c @@ -23,6 +23,7 @@ #include "hw/boards.h" #include "qemu/error-report.h" #include "exec/address-spaces.h" +#include "qemu/log.h" typedef struct XlnxEP108 { XlnxZynqMPState soc; diff --git a/hw/audio/pl041.c b/hw/audio/pl041.c index 4717bc9b9c..6e9c104011 100644 --- a/hw/audio/pl041.c +++ b/hw/audio/pl041.c @@ -22,6 +22,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" +#include "qemu/log.h" #include "pl041.h" #include "lm4549.h" diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index 5d308637df..4c856f5278 100644 --- a/hw/block/m25p80.c +++ b/hw/block/m25p80.c @@ -27,6 +27,7 @@ #include "sysemu/blockdev.h" #include "hw/ssi/ssi.h" #include "qemu/bitops.h" +#include "qemu/log.h" #ifndef M25P80_ERR_DEBUG #define M25P80_ERR_DEBUG 0 diff --git a/hw/block/pflash_cfi01.c b/hw/block/pflash_cfi01.c index 3a1f85d279..31585e3aa1 100644 --- a/hw/block/pflash_cfi01.c +++ b/hw/block/pflash_cfi01.c @@ -45,6 +45,7 @@ #include "qemu/bitops.h" #include "exec/address-spaces.h" #include "qemu/host-utils.h" +#include "qemu/log.h" #include "hw/sysbus.h" #include "sysemu/sysemu.h" diff --git a/hw/char/bcm2835_aux.c b/hw/char/bcm2835_aux.c index 0394d11a88..319f1652f6 100644 --- a/hw/char/bcm2835_aux.c +++ b/hw/char/bcm2835_aux.c @@ -22,6 +22,7 @@ #include "qemu/osdep.h" #include "hw/char/bcm2835_aux.h" +#include "qemu/log.h" #define AUX_IRQ 0x0 #define AUX_ENABLES 0x4 diff --git a/hw/char/cadence_uart.c b/hw/char/cadence_uart.c index 797787823e..442dac52cf 100644 --- a/hw/char/cadence_uart.c +++ b/hw/char/cadence_uart.c @@ -17,6 +17,10 @@ */ #include "qemu/osdep.h" +#include "hw/sysbus.h" +#include "sysemu/char.h" +#include "qemu/timer.h" +#include "qemu/log.h" #include "hw/char/cadence_uart.h" #ifdef CADENCE_UART_ERR_DEBUG diff --git a/hw/char/digic-uart.c b/hw/char/digic-uart.c index d3bc533d7c..0e44878405 100644 --- a/hw/char/digic-uart.c +++ b/hw/char/digic-uart.c @@ -30,6 +30,7 @@ #include "hw/hw.h" #include "hw/sysbus.h" #include "sysemu/char.h" +#include "qemu/log.h" #include "hw/char/digic-uart.h" diff --git a/hw/char/imx_serial.c b/hw/char/imx_serial.c index 6df74ac7c4..44856d671e 100644 --- a/hw/char/imx_serial.c +++ b/hw/char/imx_serial.c @@ -22,6 +22,7 @@ #include "hw/char/imx_serial.h" #include "sysemu/sysemu.h" #include "sysemu/char.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_UART #define DEBUG_IMX_UART 0 diff --git a/hw/char/pl011.c b/hw/char/pl011.c index 210c87b4c2..6876ea6eef 100644 --- a/hw/char/pl011.c +++ b/hw/char/pl011.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" #include "sysemu/char.h" +#include "qemu/log.h" #define TYPE_PL011 "pl011" #define PL011(obj) OBJECT_CHECK(PL011State, (obj), TYPE_PL011) diff --git a/hw/char/stm32f2xx_usart.c b/hw/char/stm32f2xx_usart.c index a94d61cebc..72305ec5d4 100644 --- a/hw/char/stm32f2xx_usart.c +++ b/hw/char/stm32f2xx_usart.c @@ -24,6 +24,7 @@ #include "qemu/osdep.h" #include "hw/char/stm32f2xx_usart.h" +#include "qemu/log.h" #ifndef STM_USART_ERR_DEBUG #define STM_USART_ERR_DEBUG 0 diff --git a/hw/display/bcm2835_fb.c b/hw/display/bcm2835_fb.c index 506f1d3d90..7eab927652 100644 --- a/hw/display/bcm2835_fb.c +++ b/hw/display/bcm2835_fb.c @@ -29,6 +29,7 @@ #include "hw/display/framebuffer.h" #include "ui/pixel_ops.h" #include "hw/misc/bcm2835_mbox_defs.h" +#include "qemu/log.h" #define DEFAULT_VCRAM_SIZE 0x4000000 #define BCM2835_FB_OFFSET 0x00100000 diff --git a/hw/display/cg3.c b/hw/display/cg3.c index eb0e71a90a..1174220394 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -31,6 +31,7 @@ #include "ui/console.h" #include "hw/sysbus.h" #include "hw/loader.h" +#include "qemu/log.h" /* Change to 1 to enable debugging */ #define DEBUG_CG3 0 diff --git a/hw/display/pl110.c b/hw/display/pl110.c index d589959f1b..c069c0b7fd 100644 --- a/hw/display/pl110.c +++ b/hw/display/pl110.c @@ -12,6 +12,7 @@ #include "ui/console.h" #include "framebuffer.h" #include "ui/pixel_ops.h" +#include "qemu/log.h" #define PL110_CR_EN 0x001 #define PL110_CR_BGR 0x100 diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index c181fb364c..91345bd399 100644 --- a/hw/display/virtio-gpu.c +++ b/hw/display/virtio-gpu.c @@ -19,6 +19,7 @@ #include "hw/virtio/virtio.h" #include "hw/virtio/virtio-gpu.h" #include "hw/virtio/virtio-bus.h" +#include "qemu/log.h" static struct virtio_gpu_simple_resource* virtio_gpu_find_resource(VirtIOGPU *g, uint32_t resource_id); diff --git a/hw/dma/bcm2835_dma.c b/hw/dma/bcm2835_dma.c index 5421175998..5d144a2633 100644 --- a/hw/dma/bcm2835_dma.c +++ b/hw/dma/bcm2835_dma.c @@ -6,6 +6,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "hw/dma/bcm2835_dma.h" +#include "qemu/log.h" /* DMA CS Control and Status bits */ #define BCM2708_DMA_ACTIVE (1 << 0) diff --git a/hw/dma/pl080.c b/hw/dma/pl080.c index 9318108b81..3bed5c3390 100644 --- a/hw/dma/pl080.c +++ b/hw/dma/pl080.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" #include "exec/address-spaces.h" +#include "qemu/log.h" #define PL080_MAX_CHANNELS 8 #define PL080_CONF_E 0x1 diff --git a/hw/dma/pl330.c b/hw/dma/pl330.c index ea89ecb00e..c0bd9fec30 100644 --- a/hw/dma/pl330.c +++ b/hw/dma/pl330.c @@ -19,6 +19,7 @@ #include "qapi/error.h" #include "qemu/timer.h" #include "sysemu/dma.h" +#include "qemu/log.h" #ifndef PL330_ERR_DEBUG #define PL330_ERR_DEBUG 0 diff --git a/hw/dma/rc4030.c b/hw/dma/rc4030.c index a06c2359a7..2f2576fafb 100644 --- a/hw/dma/rc4030.c +++ b/hw/dma/rc4030.c @@ -27,6 +27,7 @@ #include "hw/mips/mips.h" #include "hw/sysbus.h" #include "qemu/timer.h" +#include "qemu/log.h" #include "exec/address-spaces.h" #include "trace.h" diff --git a/hw/gpio/imx_gpio.c b/hw/gpio/imx_gpio.c index ed7e247f56..f3574aa8f3 100644 --- a/hw/gpio/imx_gpio.c +++ b/hw/gpio/imx_gpio.c @@ -19,6 +19,7 @@ #include "qemu/osdep.h" #include "hw/gpio/imx_gpio.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_GPIO #define DEBUG_IMX_GPIO 0 diff --git a/hw/gpio/pl061.c b/hw/gpio/pl061.c index 29dc7fc38e..44faeb23b7 100644 --- a/hw/gpio/pl061.c +++ b/hw/gpio/pl061.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" +#include "qemu/log.h" //#define DEBUG_PL061 1 diff --git a/hw/i2c/imx_i2c.c b/hw/i2c/imx_i2c.c index e19d4fa745..37e5a62ce7 100644 --- a/hw/i2c/imx_i2c.c +++ b/hw/i2c/imx_i2c.c @@ -21,6 +21,7 @@ #include "qemu/osdep.h" #include "hw/i2c/imx_i2c.h" #include "hw/i2c/i2c.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_I2C #define DEBUG_IMX_I2C 0 diff --git a/hw/i2c/versatile_i2c.c b/hw/i2c/versatile_i2c.c index fee3bc7619..0bce52416e 100644 --- a/hw/i2c/versatile_i2c.c +++ b/hw/i2c/versatile_i2c.c @@ -24,6 +24,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" #include "bitbang_i2c.h" +#include "qemu/log.h" #define TYPE_VERSATILE_I2C "versatile_i2c" #define VERSATILE_I2C(obj) \ diff --git a/hw/input/pl050.c b/hw/input/pl050.c index 3092b0fe3b..be9cd57b17 100644 --- a/hw/input/pl050.c +++ b/hw/input/pl050.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" #include "hw/input/ps2.h" +#include "qemu/log.h" #define TYPE_PL050 "pl050" #define PL050(obj) OBJECT_CHECK(PL050State, (obj), TYPE_PL050) diff --git a/hw/intc/allwinner-a10-pic.c b/hw/intc/allwinner-a10-pic.c index dc971a1603..11f13663c8 100644 --- a/hw/intc/allwinner-a10-pic.c +++ b/hw/intc/allwinner-a10-pic.c @@ -20,6 +20,7 @@ #include "hw/devices.h" #include "sysemu/sysemu.h" #include "hw/intc/allwinner-a10-pic.h" +#include "qemu/log.h" static void aw_a10_pic_update(AwA10PICState *s) { diff --git a/hw/intc/arm_gic.c b/hw/intc/arm_gic.c index 5ee79b83e6..06a22e0aaf 100644 --- a/hw/intc/arm_gic.c +++ b/hw/intc/arm_gic.c @@ -23,6 +23,7 @@ #include "gic_internal.h" #include "qapi/error.h" #include "qom/cpu.h" +#include "qemu/log.h" #include "trace.h" //#define DEBUG_GIC diff --git a/hw/intc/arm_gicv2m.c b/hw/intc/arm_gicv2m.c index 589d315c10..3922fbc1c1 100644 --- a/hw/intc/arm_gicv2m.c +++ b/hw/intc/arm_gicv2m.c @@ -30,6 +30,7 @@ #include "hw/sysbus.h" #include "hw/pci/msi.h" #include "sysemu/kvm.h" +#include "qemu/log.h" #define TYPE_ARM_GICV2M "arm-gicv2m" #define ARM_GICV2M(obj) OBJECT_CHECK(ARMGICv2mState, (obj), TYPE_ARM_GICV2M) diff --git a/hw/intc/armv7m_nvic.c b/hw/intc/armv7m_nvic.c index 4d584ef74c..890d5d7442 100644 --- a/hw/intc/armv7m_nvic.c +++ b/hw/intc/armv7m_nvic.c @@ -19,6 +19,7 @@ #include "hw/arm/arm.h" #include "exec/address-spaces.h" #include "gic_internal.h" +#include "qemu/log.h" typedef struct { GICState gic; diff --git a/hw/intc/bcm2835_ic.c b/hw/intc/bcm2835_ic.c index 80513b28fd..00d25306fd 100644 --- a/hw/intc/bcm2835_ic.c +++ b/hw/intc/bcm2835_ic.c @@ -14,6 +14,7 @@ #include "qemu/osdep.h" #include "hw/intc/bcm2835_ic.h" +#include "qemu/log.h" #define GPU_IRQS 64 #define ARM_IRQS 8 diff --git a/hw/intc/bcm2836_control.c b/hw/intc/bcm2836_control.c index d0271810cc..cfa5bc7365 100644 --- a/hw/intc/bcm2836_control.c +++ b/hw/intc/bcm2836_control.c @@ -15,6 +15,7 @@ #include "qemu/osdep.h" #include "hw/intc/bcm2836_control.h" +#include "qemu/log.h" #define REG_GPU_ROUTE 0x0c #define REG_TIMERCONTROL 0x40 diff --git a/hw/intc/i8259.c b/hw/intc/i8259.c index bb43669b93..c2607a5868 100644 --- a/hw/intc/i8259.c +++ b/hw/intc/i8259.c @@ -27,6 +27,7 @@ #include "hw/isa/isa.h" #include "monitor/monitor.h" #include "qemu/timer.h" +#include "qemu/log.h" #include "hw/isa/i8259_internal.h" /* debug PIC */ diff --git a/hw/intc/imx_avic.c b/hw/intc/imx_avic.c index d21cb97451..813e587a63 100644 --- a/hw/intc/imx_avic.c +++ b/hw/intc/imx_avic.c @@ -17,6 +17,7 @@ #include "qemu/osdep.h" #include "hw/intc/imx_avic.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_AVIC #define DEBUG_IMX_AVIC 0 diff --git a/hw/intc/openpic.c b/hw/intc/openpic.c index 2d3769310f..4349e45e04 100644 --- a/hw/intc/openpic.c +++ b/hw/intc/openpic.c @@ -44,6 +44,7 @@ #include "qapi/error.h" #include "qemu/bitops.h" #include "qapi/qmp/qerror.h" +#include "qemu/log.h" //#define DEBUG_OPENPIC diff --git a/hw/intc/pl190.c b/hw/intc/pl190.c index 1e50baf237..55ea15de76 100644 --- a/hw/intc/pl190.c +++ b/hw/intc/pl190.c @@ -9,6 +9,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" +#include "qemu/log.h" /* The number of virtual priority levels. 16 user vectors plus the unvectored IRQ. Chained interrupts would require an additional level diff --git a/hw/misc/arm11scu.c b/hw/misc/arm11scu.c index 5e54b494be..7042ce11e8 100644 --- a/hw/misc/arm11scu.c +++ b/hw/misc/arm11scu.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/misc/arm11scu.h" +#include "qemu/log.h" static uint64_t mpcore_scu_read(void *opaque, hwaddr offset, unsigned size) diff --git a/hw/misc/arm_integrator_debug.c b/hw/misc/arm_integrator_debug.c index 902605fef4..8a5f29559d 100644 --- a/hw/misc/arm_integrator_debug.c +++ b/hw/misc/arm_integrator_debug.c @@ -19,6 +19,7 @@ #include "hw/sysbus.h" #include "exec/address-spaces.h" #include "hw/misc/arm_integrator_debug.h" +#include "qemu/log.h" #define INTEGRATOR_DEBUG(obj) \ OBJECT_CHECK(IntegratorDebugState, (obj), TYPE_INTEGRATOR_DEBUG) diff --git a/hw/misc/arm_l2x0.c b/hw/misc/arm_l2x0.c index 7e179f1a4e..4442227877 100644 --- a/hw/misc/arm_l2x0.c +++ b/hw/misc/arm_l2x0.c @@ -20,6 +20,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" +#include "qemu/log.h" /* L2C-310 r3p2 */ #define CACHE_ID 0x410000c8 diff --git a/hw/misc/arm_sysctl.c b/hw/misc/arm_sysctl.c index 34d90d5230..8524008708 100644 --- a/hw/misc/arm_sysctl.c +++ b/hw/misc/arm_sysctl.c @@ -14,6 +14,7 @@ #include "hw/sysbus.h" #include "hw/arm/primecell.h" #include "sysemu/sysemu.h" +#include "qemu/log.h" #define LOCK_VALUE 0xa05f diff --git a/hw/misc/bcm2835_mbox.c b/hw/misc/bcm2835_mbox.c index 263280fd49..e97cc814af 100644 --- a/hw/misc/bcm2835_mbox.c +++ b/hw/misc/bcm2835_mbox.c @@ -11,6 +11,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "hw/misc/bcm2835_mbox.h" +#include "qemu/log.h" #define MAIL0_PEEK 0x90 #define MAIL0_SENDER 0x94 diff --git a/hw/misc/bcm2835_property.c b/hw/misc/bcm2835_property.c index 34473469d4..70eaafd325 100644 --- a/hw/misc/bcm2835_property.c +++ b/hw/misc/bcm2835_property.c @@ -8,6 +8,7 @@ #include "hw/misc/bcm2835_property.h" #include "hw/misc/bcm2835_mbox_defs.h" #include "sysemu/dma.h" +#include "qemu/log.h" /* https://github.com/raspberrypi/firmware/wiki/Mailbox-property-interface */ diff --git a/hw/misc/imx25_ccm.c b/hw/misc/imx25_ccm.c index 225604d823..5cd8c0a9a7 100644 --- a/hw/misc/imx25_ccm.c +++ b/hw/misc/imx25_ccm.c @@ -13,6 +13,7 @@ #include "qemu/osdep.h" #include "hw/misc/imx25_ccm.h" +#include "qemu/log.h" #ifndef DEBUG_IMX25_CCM #define DEBUG_IMX25_CCM 0 diff --git a/hw/misc/imx31_ccm.c b/hw/misc/imx31_ccm.c index 80c1647166..1c03e52c40 100644 --- a/hw/misc/imx31_ccm.c +++ b/hw/misc/imx31_ccm.c @@ -13,6 +13,7 @@ #include "qemu/osdep.h" #include "hw/misc/imx31_ccm.h" +#include "qemu/log.h" #define CKIH_FREQ 26000000 /* 26MHz crystal input */ diff --git a/hw/misc/imx6_ccm.c b/hw/misc/imx6_ccm.c index 4e1d49da69..ec58eef92d 100644 --- a/hw/misc/imx6_ccm.c +++ b/hw/misc/imx6_ccm.c @@ -12,6 +12,7 @@ #include "qemu/osdep.h" #include "hw/misc/imx6_ccm.h" +#include "qemu/log.h" #ifndef DEBUG_IMX6_CCM #define DEBUG_IMX6_CCM 0 diff --git a/hw/misc/imx6_src.c b/hw/misc/imx6_src.c index 6b026b459f..8bb6829575 100644 --- a/hw/misc/imx6_src.c +++ b/hw/misc/imx6_src.c @@ -12,6 +12,7 @@ #include "hw/misc/imx6_src.h" #include "sysemu/sysemu.h" #include "qemu/bitops.h" +#include "qemu/log.h" #include "arm-powerctl.h" #ifndef DEBUG_IMX6_SRC diff --git a/hw/misc/imx_ccm.c b/hw/misc/imx_ccm.c index 986d890caf..7f239a41d8 100644 --- a/hw/misc/imx_ccm.c +++ b/hw/misc/imx_ccm.c @@ -13,6 +13,7 @@ #include "qemu/osdep.h" #include "hw/misc/imx_ccm.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_CCM #define DEBUG_IMX_CCM 0 diff --git a/hw/misc/macio/cuda.c b/hw/misc/macio/cuda.c index f15f301100..05c02fb3a4 100644 --- a/hw/misc/macio/cuda.c +++ b/hw/misc/macio/cuda.c @@ -29,6 +29,7 @@ #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "qemu/cutils.h" +#include "qemu/log.h" /* XXX: implement all timer modes */ diff --git a/hw/misc/macio/mac_dbdma.c b/hw/misc/macio/mac_dbdma.c index 6051f17dbd..5632743d36 100644 --- a/hw/misc/macio/mac_dbdma.c +++ b/hw/misc/macio/mac_dbdma.c @@ -41,6 +41,7 @@ #include "hw/isa/isa.h" #include "hw/ppc/mac_dbdma.h" #include "qemu/main-loop.h" +#include "qemu/log.h" /* debug DBDMA */ //#define DEBUG_DBDMA diff --git a/hw/misc/mips_cmgcr.c b/hw/misc/mips_cmgcr.c index 37be23995b..40f34643e3 100644 --- a/hw/misc/mips_cmgcr.c +++ b/hw/misc/mips_cmgcr.c @@ -11,6 +11,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" +#include "qemu/log.h" #include "hw/hw.h" #include "hw/sysbus.h" #include "sysemu/sysemu.h" diff --git a/hw/misc/mips_cpc.c b/hw/misc/mips_cpc.c index 05688b7c4b..e6a35dd6a0 100644 --- a/hw/misc/mips_cpc.c +++ b/hw/misc/mips_cpc.c @@ -20,6 +20,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "cpu.h" +#include "qemu/log.h" #include "hw/sysbus.h" #include "hw/misc/mips_cpc.h" diff --git a/hw/misc/mips_itu.c b/hw/misc/mips_itu.c index c1a44537a3..fda7201940 100644 --- a/hw/misc/mips_itu.c +++ b/hw/misc/mips_itu.c @@ -20,6 +20,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "cpu.h" +#include "qemu/log.h" #include "hw/hw.h" #include "hw/sysbus.h" #include "sysemu/sysemu.h" diff --git a/hw/misc/stm32f2xx_syscfg.c b/hw/misc/stm32f2xx_syscfg.c index d0d7076eff..7c45833d09 100644 --- a/hw/misc/stm32f2xx_syscfg.c +++ b/hw/misc/stm32f2xx_syscfg.c @@ -24,6 +24,7 @@ #include "qemu/osdep.h" #include "hw/misc/stm32f2xx_syscfg.h" +#include "qemu/log.h" #ifndef STM_SYSCFG_ERR_DEBUG #define STM_SYSCFG_ERR_DEBUG 0 diff --git a/hw/misc/zynq-xadc.c b/hw/misc/zynq-xadc.c index 71fbccd79f..14906103c9 100644 --- a/hw/misc/zynq-xadc.c +++ b/hw/misc/zynq-xadc.c @@ -18,6 +18,7 @@ #include "hw/misc/zynq-xadc.h" #include "qemu/timer.h" #include "sysemu/sysemu.h" +#include "qemu/log.h" enum { CFG = 0x000 / 4, diff --git a/hw/misc/zynq_slcr.c b/hw/misc/zynq_slcr.c index b1b7591ef6..7891219001 100644 --- a/hw/misc/zynq_slcr.c +++ b/hw/misc/zynq_slcr.c @@ -19,6 +19,7 @@ #include "qemu/timer.h" #include "hw/sysbus.h" #include "sysemu/sysemu.h" +#include "qemu/log.h" #ifndef ZYNQ_SLCR_ERR_DEBUG #define ZYNQ_SLCR_ERR_DEBUG 0 diff --git a/hw/net/allwinner_emac.c b/hw/net/allwinner_emac.c index 16d4b63ba0..d57502300c 100644 --- a/hw/net/allwinner_emac.c +++ b/hw/net/allwinner_emac.c @@ -21,6 +21,7 @@ #include "net/net.h" #include "qemu/fifo8.h" #include "hw/net/allwinner_emac.h" +#include "qemu/log.h" #include static uint8_t padding[60]; diff --git a/hw/net/fsl_etsec/etsec.c b/hw/net/fsl_etsec/etsec.c index 1e35f7f8c5..98250e0591 100644 --- a/hw/net/fsl_etsec/etsec.c +++ b/hw/net/fsl_etsec/etsec.c @@ -33,6 +33,7 @@ #include "hw/ptimer.h" #include "etsec.h" #include "registers.h" +#include "qemu/log.h" /* #define HEX_DUMP */ /* #define DEBUG_REGISTER */ diff --git a/hw/net/fsl_etsec/rings.c b/hw/net/fsl_etsec/rings.c index ed1de7da9b..79d2f14dd8 100644 --- a/hw/net/fsl_etsec/rings.c +++ b/hw/net/fsl_etsec/rings.c @@ -23,7 +23,7 @@ */ #include "qemu/osdep.h" #include "net/checksum.h" - +#include "qemu/log.h" #include "etsec.h" #include "registers.h" diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index e60e3380e4..9055ea89a9 100644 --- a/hw/net/imx_fec.c +++ b/hw/net/imx_fec.c @@ -24,6 +24,7 @@ #include "qemu/osdep.h" #include "hw/net/imx_fec.h" #include "sysemu/dma.h" +#include "qemu/log.h" /* For crc32 */ #include diff --git a/hw/net/lan9118.c b/hw/net/lan9118.c index 08dc474d61..205207356c 100644 --- a/hw/net/lan9118.c +++ b/hw/net/lan9118.c @@ -16,6 +16,7 @@ #include "hw/devices.h" #include "sysemu/sysemu.h" #include "hw/ptimer.h" +#include "qemu/log.h" /* For crc32 */ #include diff --git a/hw/net/spapr_llan.c b/hw/net/spapr_llan.c index db97da3d38..a8266f8ec7 100644 --- a/hw/net/spapr_llan.c +++ b/hw/net/spapr_llan.c @@ -28,6 +28,7 @@ #include "qemu-common.h" #include "cpu.h" #include "hw/hw.h" +#include "qemu/log.h" #include "net/net.h" #include "hw/qdev.h" #include "hw/ppc/spapr.h" diff --git a/hw/pci-host/apb.c b/hw/pci-host/apb.c index aaef7bb3a1..babbbef0c2 100644 --- a/hw/pci-host/apb.c +++ b/hw/pci-host/apb.c @@ -36,6 +36,7 @@ #include "hw/pci-host/apb.h" #include "sysemu/sysemu.h" #include "exec/address-spaces.h" +#include "qemu/log.h" /* debug APB */ //#define DEBUG_APB diff --git a/hw/pci-host/versatile.c b/hw/pci-host/versatile.c index 339ec2c508..0792c4501c 100644 --- a/hw/pci-host/versatile.c +++ b/hw/pci-host/versatile.c @@ -13,6 +13,7 @@ #include "hw/pci/pci_bus.h" #include "hw/pci/pci_host.h" #include "exec/address-spaces.h" +#include "qemu/log.h" /* Old and buggy versions of QEMU used the wrong mapping from * PCI IRQs to system interrupt lines. Unfortunately the Linux diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index b69995e0dc..de1de1d067 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -29,6 +29,7 @@ #include "sysemu/sysemu.h" #include "sysemu/numa.h" #include "hw/hw.h" +#include "qemu/log.h" #include "hw/fw-path-provider.h" #include "elf.h" #include "net/net.h" diff --git a/hw/ppc/spapr_hcall.c b/hw/ppc/spapr_hcall.c index 4426a50e04..c5fecb50e6 100644 --- a/hw/ppc/spapr_hcall.c +++ b/hw/ppc/spapr_hcall.c @@ -1,6 +1,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "sysemu/sysemu.h" +#include "qemu/log.h" #include "cpu.h" #include "helper_regs.h" #include "hw/ppc/spapr.h" diff --git a/hw/ppc/spapr_iommu.c b/hw/ppc/spapr_iommu.c index 7dd458846e..722db91ffa 100644 --- a/hw/ppc/spapr_iommu.c +++ b/hw/ppc/spapr_iommu.c @@ -18,6 +18,7 @@ */ #include "qemu/osdep.h" #include "hw/hw.h" +#include "qemu/log.h" #include "sysemu/kvm.h" #include "hw/qdev.h" #include "kvm_ppc.h" diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c index 580829e2f1..43e2c684fd 100644 --- a/hw/ppc/spapr_rtas.c +++ b/hw/ppc/spapr_rtas.c @@ -26,6 +26,7 @@ */ #include "qemu/osdep.h" #include "cpu.h" +#include "qemu/log.h" #include "sysemu/sysemu.h" #include "sysemu/char.h" #include "hw/qdev.h" diff --git a/hw/ppc/spapr_vio.c b/hw/ppc/spapr_vio.c index 6b20b40682..d084aedadf 100644 --- a/hw/ppc/spapr_vio.c +++ b/hw/ppc/spapr_vio.c @@ -22,6 +22,7 @@ #include "qemu/osdep.h" #include "qapi/error.h" #include "hw/hw.h" +#include "qemu/log.h" #include "sysemu/sysemu.h" #include "hw/boards.h" #include "hw/loader.h" diff --git a/hw/sd/pl181.c b/hw/sd/pl181.c index e87abb2051..eb783c6b51 100644 --- a/hw/sd/pl181.c +++ b/hw/sd/pl181.c @@ -12,6 +12,7 @@ #include "sysemu/blockdev.h" #include "hw/sysbus.h" #include "hw/sd/sd.h" +#include "qemu/log.h" //#define DEBUG_PL181 1 diff --git a/hw/sd/sd.c b/hw/sd/sd.c index 87e3d23a3d..87c6dc108d 100644 --- a/hw/sd/sd.c +++ b/hw/sd/sd.c @@ -39,6 +39,7 @@ #include "hw/qdev-properties.h" #include "qemu/error-report.h" #include "qemu/timer.h" +#include "qemu/log.h" //#define DEBUG_SD 1 diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c index d28b5871fc..01fbf228be 100644 --- a/hw/sd/sdhci.c +++ b/hw/sd/sdhci.c @@ -30,6 +30,7 @@ #include "qemu/timer.h" #include "qemu/bitops.h" #include "sdhci-internal.h" +#include "qemu/log.h" /* host controller debug messages */ #ifndef SDHC_DEBUG diff --git a/hw/ssi/imx_spi.c b/hw/ssi/imx_spi.c index d5dd42aca6..4226199811 100644 --- a/hw/ssi/imx_spi.c +++ b/hw/ssi/imx_spi.c @@ -11,6 +11,7 @@ #include "qemu/osdep.h" #include "hw/ssi/imx_spi.h" #include "sysemu/sysemu.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_SPI #define DEBUG_IMX_SPI 0 diff --git a/hw/ssi/pl022.c b/hw/ssi/pl022.c index 564a0d36e7..c1368018ee 100644 --- a/hw/ssi/pl022.c +++ b/hw/ssi/pl022.c @@ -10,6 +10,7 @@ #include "qemu/osdep.h" #include "hw/sysbus.h" #include "hw/ssi/ssi.h" +#include "qemu/log.h" //#define DEBUG_PL022 1 diff --git a/hw/timer/allwinner-a10-pit.c b/hw/timer/allwinner-a10-pit.c index 51cdc98f3a..3385e5dc35 100644 --- a/hw/timer/allwinner-a10-pit.c +++ b/hw/timer/allwinner-a10-pit.c @@ -19,6 +19,7 @@ #include "hw/sysbus.h" #include "sysemu/sysemu.h" #include "hw/timer/allwinner-a10-pit.h" +#include "qemu/log.h" static void a10_pit_update_irq(AwA10PITState *s) { diff --git a/hw/timer/arm_timer.c b/hw/timer/arm_timer.c index f1ede5f53b..111a16db37 100644 --- a/hw/timer/arm_timer.c +++ b/hw/timer/arm_timer.c @@ -14,6 +14,7 @@ #include "hw/qdev.h" #include "hw/ptimer.h" #include "qemu/main-loop.h" +#include "qemu/log.h" /* Common timer implementation. */ diff --git a/hw/timer/digic-timer.c b/hw/timer/digic-timer.c index 5b97e1e1a6..0f21faf876 100644 --- a/hw/timer/digic-timer.c +++ b/hw/timer/digic-timer.c @@ -30,6 +30,7 @@ #include "hw/sysbus.h" #include "hw/ptimer.h" #include "qemu/main-loop.h" +#include "qemu/log.h" #include "hw/timer/digic-timer.h" diff --git a/hw/timer/imx_epit.c b/hw/timer/imx_epit.c index f5836e21f4..eddf3481e8 100644 --- a/hw/timer/imx_epit.c +++ b/hw/timer/imx_epit.c @@ -16,6 +16,7 @@ #include "hw/timer/imx_epit.h" #include "hw/misc/imx_ccm.h" #include "qemu/main-loop.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_EPIT #define DEBUG_IMX_EPIT 0 diff --git a/hw/timer/imx_gpt.c b/hw/timer/imx_gpt.c index ab2e213a19..3c2f01ab99 100644 --- a/hw/timer/imx_gpt.c +++ b/hw/timer/imx_gpt.c @@ -16,6 +16,7 @@ #include "hw/timer/imx_gpt.h" #include "hw/misc/imx_ccm.h" #include "qemu/main-loop.h" +#include "qemu/log.h" #ifndef DEBUG_IMX_GPT #define DEBUG_IMX_GPT 0 diff --git a/hw/timer/pl031.c b/hw/timer/pl031.c index 38e0cb5ad6..dbbeb9b16b 100644 --- a/hw/timer/pl031.c +++ b/hw/timer/pl031.c @@ -16,6 +16,7 @@ #include "qemu/timer.h" #include "sysemu/sysemu.h" #include "qemu/cutils.h" +#include "qemu/log.h" //#define DEBUG_PL031 diff --git a/hw/timer/stm32f2xx_timer.c b/hw/timer/stm32f2xx_timer.c index 55dacbbe3b..bf0fb288c4 100644 --- a/hw/timer/stm32f2xx_timer.c +++ b/hw/timer/stm32f2xx_timer.c @@ -24,6 +24,7 @@ #include "qemu/osdep.h" #include "hw/timer/stm32f2xx_timer.h" +#include "qemu/log.h" #ifndef STM_TIMER_ERR_DEBUG #define STM_TIMER_ERR_DEBUG 0 diff --git a/hw/watchdog/wdt_diag288.c b/hw/watchdog/wdt_diag288.c index f54a35a0e3..a7b64e2c40 100644 --- a/hw/watchdog/wdt_diag288.c +++ b/hw/watchdog/wdt_diag288.c @@ -16,6 +16,7 @@ #include "hw/sysbus.h" #include "qemu/timer.h" #include "hw/watchdog/wdt_diag288.h" +#include "qemu/log.h" static WatchdogTimerModel model = { .wdt_name = TYPE_WDT_DIAG288, diff --git a/include/hw/hw.h b/include/hw/hw.h index a20321bada..029b1e8065 100644 --- a/include/hw/hw.h +++ b/include/hw/hw.h @@ -11,7 +11,6 @@ #include "hw/irq.h" #include "block/aio.h" #include "migration/vmstate.h" -#include "qemu/log.h" #include "qemu/module.h" typedef void QEMUResetHandler(void *opaque); diff --git a/monitor.c b/monitor.c index 812383ff4d..a2c1ad2e7b 100644 --- a/monitor.c +++ b/monitor.c @@ -71,6 +71,7 @@ #include "trace/simple.h" #endif #include "exec/memory.h" +#include "qemu/log.h" #include "qmp-commands.h" #include "hmp.h" #include "qemu/thread.h" diff --git a/target-arm/arm-powerctl.c b/target-arm/arm-powerctl.c index cb9919b465..ee475d9fab 100644 --- a/target-arm/arm-powerctl.c +++ b/target-arm/arm-powerctl.c @@ -13,6 +13,7 @@ #include #include "internals.h" #include "arm-powerctl.h" +#include "qemu/log.h" #ifndef DEBUG_ARM_POWERCTL #define DEBUG_ARM_POWERCTL 0 diff --git a/target-arm/kvm.c b/target-arm/kvm.c index 36710320f0..83da447cb7 100644 --- a/target-arm/kvm.c +++ b/target-arm/kvm.c @@ -25,6 +25,7 @@ #include "hw/arm/arm.h" #include "exec/memattrs.h" #include "hw/boards.h" +#include "qemu/log.h" const KVMCapabilityInfo kvm_arch_required_capabilities[] = { KVM_CAP_LAST_INFO diff --git a/target-arm/kvm32.c b/target-arm/kvm32.c index 7f5935ab13..c03e3e526a 100644 --- a/target-arm/kvm32.c +++ b/target-arm/kvm32.c @@ -22,6 +22,7 @@ #include "kvm_arm.h" #include "internals.h" #include "hw/arm/arm.h" +#include "qemu/log.h" static inline void set_feature(uint64_t *features, int feature) { diff --git a/vl.c b/vl.c index bf61983a57..a43a3bad18 100644 --- a/vl.c +++ b/vl.c @@ -80,6 +80,7 @@ int main(int argc, char **argv) #include "qemu/timer.h" #include "sysemu/char.h" #include "qemu/bitmap.h" +#include "qemu/log.h" #include "sysemu/blockdev.h" #include "hw/block/block.h" #include "migration/block.h" -- cgit 1.4.1