include: avoid useless includes of exec/ headers

Headers in include/exec/ are for the deepest innards of QEMU,
they should almost never be included directly.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
Paolo Bonzini 2013-04-08 17:29:59 +02:00
parent dccfcd0e5f
commit 0bc3cd624f
9 changed files with 9 additions and 11 deletions

View File

@ -40,7 +40,6 @@
#include "hw/audio/audio.h" #include "hw/audio/audio.h"
#include "sysemu/kvm.h" #include "sysemu/kvm.h"
#include "migration/migration.h" #include "migration/migration.h"
#include "exec/gdbstub.h"
#include "hw/i386/smbios.h" #include "hw/i386/smbios.h"
#include "exec/address-spaces.h" #include "exec/address-spaces.h"
#include "hw/audio/pcspk.h" #include "hw/audio/pcspk.h"

6
dump.c
View File

@ -23,7 +23,6 @@
#include "sysemu/memory_mapping.h" #include "sysemu/memory_mapping.h"
#include "qapi/error.h" #include "qapi/error.h"
#include "qmp-commands.h" #include "qmp-commands.h"
#include "exec/gdbstub.h"
static uint16_t cpu_convert_to_target16(uint16_t val, int endian) static uint16_t cpu_convert_to_target16(uint16_t val, int endian)
{ {
@ -268,6 +267,11 @@ static int write_elf64_note(DumpState *s)
return 0; return 0;
} }
static inline int cpu_index(CPUState *cpu)
{
return cpu->cpu_index + 1;
}
static int write_elf64_notes(DumpState *s) static int write_elf64_notes(DumpState *s)
{ {
CPUArchState *env; CPUArchState *env;

View File

@ -7,7 +7,6 @@
*/ */
#include "cpu.h" #include "cpu.h"
#include "exec/exec-all.h"
#include "hw/hw.h" #include "hw/hw.h"
#include "hw/devices.h" #include "hw/devices.h"
#include "sysemu/sysemu.h" #include "sysemu/sysemu.h"

View File

@ -29,7 +29,6 @@
#include "monitor/monitor.h" #include "monitor/monitor.h"
#include "sysemu/dma.h" #include "sysemu/dma.h"
#include "exec/cpu-common.h"
#include "internal.h" #include "internal.h"
#include <hw/ide/pci.h> #include <hw/ide/pci.h>
#include <hw/ide/ahci.h> #include <hw/ide/ahci.h>

View File

@ -8,7 +8,6 @@
*/ */
#include <hw/ide.h> #include <hw/ide.h>
#include <hw/isa/isa.h> #include <hw/isa/isa.h>
#include "exec/iorange.h"
#include "sysemu/dma.h" #include "sysemu/dma.h"
#include "sysemu/sysemu.h" #include "sysemu/sysemu.h"
#include "hw/block/block.h" #include "hw/block/block.h"

View File

@ -15,6 +15,7 @@
* *
*/ */
#include "hw/hw.h"
#include "vmxnet_tx_pkt.h" #include "vmxnet_tx_pkt.h"
#include "net/eth.h" #include "net/eth.h"
#include "qemu-common.h" #include "qemu-common.h"
@ -22,7 +23,6 @@
#include "net/checksum.h" #include "net/checksum.h"
#include "net/tap.h" #include "net/tap.h"
#include "net/net.h" #include "net/net.h"
#include "exec/cpu-common.h"
enum { enum {
VMXNET_TX_PKT_VHDR_FRAG = 0, VMXNET_TX_PKT_VHDR_FRAG = 0,

View File

@ -20,7 +20,7 @@
* THE SOFTWARE. * THE SOFTWARE.
*/ */
#include "qemu-common.h" #include "qemu-common.h"
#include "exec/cpu-common.h" #include "hw/hw.h"
#include "hw/usb.h" #include "hw/usb.h"
#include "sysemu/dma.h" #include "sysemu/dma.h"

View File

@ -14,7 +14,6 @@
#include "hw/hw.h" #include "hw/hw.h"
#include "hw/pci/msi.h" #include "hw/pci/msi.h"
#include "cpu.h" #include "cpu.h"
#include "exec/gdbstub.h"
#include "sysemu/kvm.h" #include "sysemu/kvm.h"
KVMState *kvm_state; KVMState *kvm_state;

View File

@ -35,9 +35,6 @@
#include "cpu.h" #include "cpu.h"
#include "disas/disas.h" #include "disas/disas.h"
#include "tcg.h" #include "tcg.h"
#include "qemu/timer.h"
#include "exec/memory.h"
#include "exec/address-spaces.h"
#if defined(CONFIG_USER_ONLY) #if defined(CONFIG_USER_ONLY)
#include "qemu.h" #include "qemu.h"
#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
@ -55,6 +52,8 @@
#include <libutil.h> #include <libutil.h>
#endif #endif
#endif #endif
#else
#include "exec/address-spaces.h"
#endif #endif
#include "exec/cputlb.h" #include "exec/cputlb.h"