qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: aliguori@us.ibm.com, afaerber@suse.de
Subject: [Qemu-devel] [PATCH 09/32] janitor: do not rely on indirect inclusions of or from qemu-char.h
Date: Thu,  6 Dec 2012 14:06:47 +0100	[thread overview]
Message-ID: <1354799230-30904-10-git-send-email-pbonzini@redhat.com> (raw)
In-Reply-To: <1354799230-30904-1-git-send-email-pbonzini@redhat.com>

Various header files rely on qemu-char.h including qemu-config.h or
main-loop.h, but they really do not need qemu-char.h at all (particularly
interesting is the case of the block layer!).  Clean this up, and also
add missing inclusions of qemu-char.h itself.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 arch_init.c            |    1 +
 audio/alsaaudio.c      |    1 +
 audio/ossaudio.c       |    1 +
 block/blkdebug.c       |    1 +
 block/iscsi.c          |    1 +
 bt-host.c              |    1 +
 bt-vhci.c              |    1 +
 event_notifier-posix.c |    1 +
 exec.c                 |    1 +
 hw/arm_boot.c          |    1 +
 hw/dma.c               |    1 +
 hw/fw_cfg.c            |    1 +
 hw/jazz_led.c          |    1 +
 hw/mac_dbdma.c         |    1 +
 hw/puv3.c              |    2 ++
 hw/qdev-monitor.c      |    1 +
 hw/qdev-properties.c   |    1 +
 hw/s390x/sclpconsole.c |    1 +
 hw/tcx.c               |    1 +
 hw/usb/dev-network.c   |    1 +
 net.c                  |    1 +
 qemu-config.h          |    1 +
 spice-qemu-char.c      |    1 +
 target-i386/kvm.c      |    1 +
 24 files changed, 25 insertions(+), 0 deletions(-)

diff --git a/arch_init.c b/arch_init.c
index e6effe8..dde7fad 100644
--- a/arch_init.c
+++ b/arch_init.c
@@ -46,6 +46,7 @@
 #include "exec-memory.h"
 #include "hw/pcspk.h"
 #include "qemu/page_cache.h"
+#include "qemu-config.h"
 #include "qmp-commands.h"
 #include "trace.h"
 
diff --git a/audio/alsaaudio.c b/audio/alsaaudio.c
index cb45b49..564d632 100644
--- a/audio/alsaaudio.c
+++ b/audio/alsaaudio.c
@@ -23,6 +23,7 @@
  */
 #include <alsa/asoundlib.h>
 #include "qemu-common.h"
+#include "main-loop.h"
 #include "qemu-char.h"
 #include "audio.h"
 
diff --git a/audio/ossaudio.c b/audio/ossaudio.c
index df51b7c..45abe39 100644
--- a/audio/ossaudio.c
+++ b/audio/ossaudio.c
@@ -31,6 +31,7 @@
 #include <sys/soundcard.h>
 #endif
 #include "qemu-common.h"
+#include "main-loop.h"
 #include "host-utils.h"
 #include "qemu-char.h"
 #include "audio.h"
diff --git a/block/blkdebug.c b/block/blkdebug.c
index d61ece8..19df74e 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -23,6 +23,7 @@
  */
 
 #include "qemu-common.h"
+#include "qemu-config.h"
 #include "block_int.h"
 #include "module.h"
 
diff --git a/block/iscsi.c b/block/iscsi.c
index c0b70b3..33b93d8 100644
--- a/block/iscsi.c
+++ b/block/iscsi.c
@@ -27,6 +27,7 @@
 #include <poll.h>
 #include <arpa/inet.h>
 #include "qemu-common.h"
+#include "qemu-config.h"
 #include "qemu-error.h"
 #include "block_int.h"
 #include "trace.h"
diff --git a/bt-host.c b/bt-host.c
index 0d3ad28..8b47370 100644
--- a/bt-host.c
+++ b/bt-host.c
@@ -21,6 +21,7 @@
 #include "qemu-char.h"
 #include "net.h"
 #include "bt-host.h"
+#include "main-loop.h"
 
 #ifndef _WIN32
 # include <errno.h>
diff --git a/bt-vhci.c b/bt-vhci.c
index bbc1029..878460a 100644
--- a/bt-vhci.c
+++ b/bt-vhci.c
@@ -21,6 +21,7 @@
 #include "qemu-char.h"
 #include "net.h"
 #include "hw/bt.h"
+#include "main-loop.h"
 
 #define VHCI_DEV	"/dev/vhci"
 #define VHCI_UDEV	"/dev/hci_vhci"
diff --git a/event_notifier-posix.c b/event_notifier-posix.c
index 6f3239a..f0bd839 100644
--- a/event_notifier-posix.c
+++ b/event_notifier-posix.c
@@ -13,6 +13,7 @@
 #include "qemu-common.h"
 #include "event_notifier.h"
 #include "qemu-char.h"
+#include "main-loop.h"
 
 #ifdef CONFIG_EVENTFD
 #include <sys/eventfd.h>
diff --git a/exec.c b/exec.c
index 8435de0..d4ef5b2 100644
--- a/exec.c
+++ b/exec.c
@@ -33,6 +33,7 @@
 #include "kvm.h"
 #include "hw/xen.h"
 #include "qemu-timer.h"
+#include "qemu-config.h"
 #include "memory.h"
 #include "dma.h"
 #include "exec-memory.h"
diff --git a/hw/arm_boot.c b/hw/arm_boot.c
index 92e2cab..ae1cf66 100644
--- a/hw/arm_boot.c
+++ b/hw/arm_boot.c
@@ -15,6 +15,7 @@
 #include "loader.h"
 #include "elf.h"
 #include "device_tree.h"
+#include "qemu-config.h"
 
 #define KERNEL_ARGS_ADDR 0x100
 #define KERNEL_LOAD_ADDR 0x00010000
diff --git a/hw/dma.c b/hw/dma.c
index d6aeac2..b5d9f7f 100644
--- a/hw/dma.c
+++ b/hw/dma.c
@@ -23,6 +23,7 @@
  */
 #include "hw.h"
 #include "isa.h"
+#include "main-loop.h"
 
 /* #define DEBUG_DMA */
 
diff --git a/hw/fw_cfg.c b/hw/fw_cfg.c
index 2b92cda..7b0e50f 100644
--- a/hw/fw_cfg.c
+++ b/hw/fw_cfg.c
@@ -27,6 +27,7 @@
 #include "fw_cfg.h"
 #include "sysbus.h"
 #include "qemu-error.h"
+#include "qemu-config.h"
 
 /* debug firmware config */
 //#define DEBUG_FW_CFG
diff --git a/hw/jazz_led.c b/hw/jazz_led.c
index 640e75e..09c7742 100644
--- a/hw/jazz_led.c
+++ b/hw/jazz_led.c
@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  */
 
+#include "qemu-common.h"
 #include "console.h"
 #include "pixel_ops.h"
 #include "trace.h"
diff --git a/hw/mac_dbdma.c b/hw/mac_dbdma.c
index e551156..41eee50 100644
--- a/hw/mac_dbdma.c
+++ b/hw/mac_dbdma.c
@@ -39,6 +39,7 @@
 #include "hw.h"
 #include "isa.h"
 #include "mac_dbdma.h"
+#include "main-loop.h"
 
 /* debug DBDMA */
 //#define DEBUG_DBDMA
diff --git a/hw/puv3.c b/hw/puv3.c
index 764799c..57c4e19 100644
--- a/hw/puv3.c
+++ b/hw/puv3.c
@@ -8,6 +8,8 @@
  * published by the Free Software Foundation, or any later version.
  * See the COPYING file in the top-level directory.
  */
+
+#include "qemu-common.h"
 #include "console.h"
 #include "elf.h"
 #include "exec-memory.h"
diff --git a/hw/qdev-monitor.c b/hw/qdev-monitor.c
index a1b4d6a..5aaf74b 100644
--- a/hw/qdev-monitor.c
+++ b/hw/qdev-monitor.c
@@ -21,6 +21,7 @@
 #include "monitor.h"
 #include "qmp-commands.h"
 #include "arch_init.h"
+#include "qemu-config.h"
 
 /*
  * Aliases were a bad idea from the start.  Let's keep them
diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c
index 81d901c..b9cd3c0 100644
--- a/hw/qdev-properties.c
+++ b/hw/qdev-properties.c
@@ -5,6 +5,7 @@
 #include "hw/block-common.h"
 #include "net/hub.h"
 #include "qapi/qapi-visit-core.h"
+#include "qemu-char.h"
 
 void *qdev_get_prop_ptr(DeviceState *dev, Property *prop)
 {
diff --git a/hw/s390x/sclpconsole.c b/hw/s390x/sclpconsole.c
index 0ec5623..15e7b61 100644
--- a/hw/s390x/sclpconsole.c
+++ b/hw/s390x/sclpconsole.c
@@ -17,6 +17,7 @@
 
 #include "sclp.h"
 #include "event-facility.h"
+#include "qemu-char.h"
 
 typedef struct ASCIIConsoleData {
     EventBufferHeader ebh;
diff --git a/hw/tcx.c b/hw/tcx.c
index 7aee2a9..a66fbee 100644
--- a/hw/tcx.c
+++ b/hw/tcx.c
@@ -22,6 +22,7 @@
  * THE SOFTWARE.
  */
 
+#include "qemu-common.h"
 #include "console.h"
 #include "pixel_ops.h"
 #include "sysbus.h"
diff --git a/hw/usb/dev-network.c b/hw/usb/dev-network.c
index 14d9e5a..3a7c607 100644
--- a/hw/usb/dev-network.c
+++ b/hw/usb/dev-network.c
@@ -28,6 +28,7 @@
 #include "hw/usb/desc.h"
 #include "net.h"
 #include "qemu-queue.h"
+#include "qemu-config.h"
 #include "sysemu.h"
 #include "iov.h"
 
diff --git a/net.c b/net.c
index e8ae13e..4f3d642 100644
--- a/net.c
+++ b/net.c
@@ -32,6 +32,7 @@
 #include "monitor.h"
 #include "qemu-common.h"
 #include "qemu_socket.h"
+#include "qemu-config.h"
 #include "qmp-commands.h"
 #include "hw/qdev.h"
 #include "iov.h"
diff --git a/qemu-config.h b/qemu-config.h
index 812c4c5..eb50eca 100644
--- a/qemu-config.h
+++ b/qemu-config.h
@@ -4,6 +4,7 @@
 #include <stdio.h>
 #include "qemu-option.h"
 #include "error.h"
+#include "qemu-option.h"
 
 extern QemuOptsList qemu_fsdev_opts;
 extern QemuOptsList qemu_virtfs_opts;
diff --git a/spice-qemu-char.c b/spice-qemu-char.c
index 09aa22d..5f95c93 100644
--- a/spice-qemu-char.c
+++ b/spice-qemu-char.c
@@ -1,6 +1,7 @@
 #include "config-host.h"
 #include "trace.h"
 #include "ui/qemu-spice.h"
+#include "qemu-char.h"
 #include <spice.h>
 #include <spice-experimental.h>
 
diff --git a/target-i386/kvm.c b/target-i386/kvm.c
index f669281..93d4524 100644
--- a/target-i386/kvm.c
+++ b/target-i386/kvm.c
@@ -27,6 +27,7 @@
 #include "cpu.h"
 #include "gdbstub.h"
 #include "host-utils.h"
+#include "qemu-config.h"
 #include "hw/pc.h"
 #include "hw/apic.h"
 #include "ioport.h"
-- 
1.7.1

  parent reply	other threads:[~2012-12-06 13:08 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-06 13:06 [Qemu-devel] [PATCH 00/32] Build cleanups and header file movement to include/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 01/32] libcacard: simplify rules for recursive build Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 02/32] vscclient: use per-target variables Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 03/32] build: adjust setting of QEMU_INCLUDES Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 04/32] build: add $(TARGET_DIR) to "GEN config-target.h" lines Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 05/32] build: move rules from Makefile to */Makefile.objs Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 06/32] build: create ldscripts/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 07/32] build: kill libdis, move disassemblers to disas/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 08/32] build: kill libuser Paolo Bonzini
2012-12-06 13:06 ` Paolo Bonzini [this message]
2012-12-06 13:06 ` [Qemu-devel] [PATCH 10/32] janitor: do not include qemu-char everywhere Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 11/32] net: move Bluetooth stuff out of net.h Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 12/32] net: do not include net.h everywhere Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 13/32] net: move net.c to net/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 14/32] net: reorganize headers Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 15/32] qemu-ga: move qemu-ga files to qga/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 16/32] ui: move files to ui/ and include/ui/ Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 17/32] qapi: move inclusions of qemu-common.h from headers to .c files Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 18/32] qapi: remove qapi/qapi-types-core.h Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 19/32] qapi: make struct Visitor opaque Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 20/32] janitor: add guards to headers Paolo Bonzini
2012-12-06 13:06 ` [Qemu-devel] [PATCH 21/32] qapi: move include files to include/qapi/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 22/32] block: move include files to include/block/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 23/32] exec: move include files to include/exec/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 24/32] monitor: move include files to include/monitor/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 25/32] migration: move include files to include/migration/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 26/32] qom: move include files to include/qom/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 27/32] misc: move include files to include/qemu/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 28/32] softmmu: move include files to include/sysemu/ Paolo Bonzini
2013-01-07  1:15   ` Amos Kong
2012-12-06 13:07 ` [Qemu-devel] [PATCH 29/32] softmmu: move remaining include files to include/ subdirectories Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 30/32] fpu: move public header file to include/fpu Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 31/32] hw: move executable format header files to hw/ Paolo Bonzini
2012-12-06 13:07 ` [Qemu-devel] [PATCH 32/32] janitor: move remaining public headers to include/ Paolo Bonzini
2012-12-11  8:45 ` [Qemu-devel] [PATCH 00/32] Build cleanups and header file movement " Stefan Hajnoczi
  -- strict thread matches above, loose matches on Subject: below --
2012-12-17 18:17 [Qemu-devel] [PULL 00/45] Include reorganization + PCI patch queue Paolo Bonzini
2012-12-17 18:17 ` [Qemu-devel] [PATCH 09/32] janitor: do not rely on indirect inclusions of or from qemu-char.h Paolo Bonzini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1354799230-30904-10-git-send-email-pbonzini@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=afaerber@suse.de \
    --cc=aliguori@us.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).