qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: qemu-devel@nongnu.org
Cc: "Andreas Färber" <afaerber@suse.de>,
	"David Gibson" <david@gibson.dropbear.id.au>
Subject: [Qemu-devel] [PATCH RFC qom-cpu 2/4] qemu-common.h: Move fprintf_function to qemu-types.h
Date: Tue, 18 Dec 2012 08:53:41 +0100	[thread overview]
Message-ID: <1355817223-13076-3-git-send-email-afaerber@suse.de> (raw)
In-Reply-To: <1355817223-13076-1-git-send-email-afaerber@suse.de>

This avoids a dependency on qemu-common.h from qemu/cpu.h.

Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 include/qemu/cpu.h |    2 +-
 qemu-common.h      |    5 -----
 qemu-types.h       |    6 ++++++
 3 Dateien geändert, 7 Zeilen hinzugefügt(+), 6 Zeilen entfernt(-)

diff --git a/include/qemu/cpu.h b/include/qemu/cpu.h
index 5fbb3f9..d737fcd 100644
--- a/include/qemu/cpu.h
+++ b/include/qemu/cpu.h
@@ -21,7 +21,7 @@
 #define QEMU_CPU_H
 
 #include "qemu/object.h"
-#include "qemu-common.h"
+#include "qemu-types.h"
 #include "qemu-thread.h"
 
 /**
diff --git a/qemu-common.h b/qemu-common.h
index e674786..98ab78d 100644
--- a/qemu-common.h
+++ b/qemu-common.h
@@ -12,7 +12,6 @@
 #ifndef QEMU_COMMON_H
 #define QEMU_COMMON_H
 
-#include "compiler.h"
 #include "config-host.h"
 #include "qemu-types.h"
 
@@ -24,7 +23,6 @@
 
 /* we put basic includes here to avoid repeating them in device drivers */
 #include <stdlib.h>
-#include <stdio.h>
 #include <stdarg.h>
 #include <stdbool.h>
 #include <string.h>
@@ -95,9 +93,6 @@ struct iovec {
 #include <sys/uio.h>
 #endif
 
-typedef int (*fprintf_function)(FILE *f, const char *fmt, ...)
-    GCC_FMT_ATTR(2, 3);
-
 #ifdef _WIN32
 #define fsync _commit
 #if !defined(lseek)
diff --git a/qemu-types.h b/qemu-types.h
index fd532a2..f7a7194 100644
--- a/qemu-types.h
+++ b/qemu-types.h
@@ -1,6 +1,12 @@
 #ifndef QEMU_TYPEDEFS_H
 #define QEMU_TYPEDEFS_H
 
+#include "compiler.h"
+#include <stdio.h>
+
+typedef int (*fprintf_function)(FILE *f, const char *fmt, ...)
+    GCC_FMT_ATTR(2, 3);
+
 /* A load of opaque types so that device init declarations don't have to
    pull in all the real definitions.  */
 typedef struct QEMUTimer QEMUTimer;
-- 
1.7.10.4

  parent reply	other threads:[~2012-12-18  7:54 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-18  7:53 [Qemu-devel] [PATCH qom-cpu 0/4] CPU cleanup and PPC subclasses Andreas Färber
2012-12-18  7:53 ` [Qemu-devel] [PATCH qom-cpu 1/4] cpu: Introduce CPUListState struct Andreas Färber
2012-12-18 15:59   ` Igor Mammedov
2012-12-18 18:44     ` Andreas Färber
2012-12-18 17:42   ` Eduardo Habkost
2012-12-18 20:00     ` Andreas Färber
2012-12-18  7:53 ` Andreas Färber [this message]
2012-12-18 17:25   ` [Qemu-devel] [PATCH RFC qom-cpu 2/4] qemu-common.h: Move fprintf_function to qemu-types.h Eduardo Habkost
2012-12-18  7:53 ` [Qemu-devel] [PATCH qom-cpu 3/4] target-ppc: Slim conversion of model definitions to QOM subclasses Andreas Färber
2012-12-18 18:15   ` Eduardo Habkost
2012-12-19  2:46   ` Andreas Färber
2012-12-18  7:53 ` [Qemu-devel] [PATCH qom-cpu 4/4] target-ppc: Error out for -cpu host on unknown PVR Andreas Färber
2013-01-03 12:26   ` Alexander Graf

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=1355817223-13076-3-git-send-email-afaerber@suse.de \
    --to=afaerber@suse.de \
    --cc=david@gibson.dropbear.id.au \
    --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).