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>
Subject: [Qemu-devel] [PULL 23/24] hwaddr: Make hwaddr type usable beyond softmmu
Date: Fri, 28 Jun 2013 17:55:45 +0200	[thread overview]
Message-ID: <1372434946-18489-24-git-send-email-afaerber@suse.de> (raw)
In-Reply-To: <1372434946-18489-1-git-send-email-afaerber@suse.de>

While not normally needed for *-user, it can safely be used there since
always based on uint64_t, to avoid ifdeffery.

To avoid accidental uses, move the guards from exec/hwaddr.h to its
inclusion sites.  No need for them in include/hw/.

Prepares for hwaddr use in qom/cpu.h.

Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 include/exec/cpu-common.h | 2 ++
 include/exec/cpu-defs.h   | 2 ++
 include/exec/hwaddr.h     | 4 ----
 include/exec/memory.h     | 2 ++
 4 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/include/exec/cpu-common.h b/include/exec/cpu-common.h
index 92a4223..5240ae2 100644
--- a/include/exec/cpu-common.h
+++ b/include/exec/cpu-common.h
@@ -3,7 +3,9 @@
 
 /* CPU interfaces that are target independent.  */
 
+#ifndef CONFIG_USER_ONLY
 #include "exec/hwaddr.h"
+#endif
 
 #ifndef NEED_CPU_H
 #include "exec/poison.h"
diff --git a/include/exec/cpu-defs.h b/include/exec/cpu-defs.h
index 2e5a9ba..c4ac929 100644
--- a/include/exec/cpu-defs.h
+++ b/include/exec/cpu-defs.h
@@ -28,7 +28,9 @@
 #include <inttypes.h>
 #include "qemu/osdep.h"
 #include "qemu/queue.h"
+#ifndef CONFIG_USER_ONLY
 #include "exec/hwaddr.h"
+#endif
 
 #ifndef TARGET_LONG_BITS
 #error TARGET_LONG_BITS must be defined before including this header
diff --git a/include/exec/hwaddr.h b/include/exec/hwaddr.h
index 251cf92..c9eb78f 100644
--- a/include/exec/hwaddr.h
+++ b/include/exec/hwaddr.h
@@ -3,8 +3,6 @@
 #ifndef HWADDR_H
 #define HWADDR_H
 
-#ifndef CONFIG_USER_ONLY
-
 #define HWADDR_BITS 64
 /* hwaddr is the type of a physical address (its size can
    be different from 'target_ulong').  */
@@ -20,5 +18,3 @@ typedef uint64_t hwaddr;
 #define HWADDR_PRIX PRIX64
 
 #endif
-
-#endif
diff --git a/include/exec/memory.h b/include/exec/memory.h
index 3598c4f..2ddc3c5 100644
--- a/include/exec/memory.h
+++ b/include/exec/memory.h
@@ -20,7 +20,9 @@
 #include <stdbool.h>
 #include "qemu-common.h"
 #include "exec/cpu-common.h"
+#ifndef CONFIG_USER_ONLY
 #include "exec/hwaddr.h"
+#endif
 #include "qemu/queue.h"
 #include "exec/iorange.h"
 #include "exec/ioport.h"
-- 
1.8.1.4

  parent reply	other threads:[~2013-06-28 16:00 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-28 15:55 [Qemu-devel] [PULL 00/24] QOM CPUState patch queue 2013-06-28 Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 01/24] cpu: Fix cpu_class_set_vmsd() documentation Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 02/24] cpu: Introduce device_class_set_vmsd() helper Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 03/24] cpu: Introduce VMSTATE_CPU() macro for CPUState Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 04/24] target-alpha: Register VMStateDescription for AlphaCPU Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 05/24] target-openrisc: Register VMStateDescription for OpenRISCCPU Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 06/24] cpu: Guard cpu_{save, load}() definitions Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 07/24] gdbstub: Simplify find_cpu() Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 08/24] kvm: Change kvm_cpu_synchronize_state() argument to CPUState Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 09/24] kvm: Change cpu_synchronize_state() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 10/24] cpu: Change cpu_exit() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 11/24] cpus: Change cpu_thread_is_idle() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 12/24] cpus: Change qemu_kvm_wait_io_event() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 13/24] kvm: Change kvm_set_signal_mask() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 14/24] cpus: Change qemu_kvm_init_cpu_signals() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 15/24] cpu: Turn cpu_dump_{state, statistics}() into CPUState hooks Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 16/24] kvm: Change kvm_handle_internal_error() argument to CPUState Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 17/24] kvm: Change kvm_cpu_exec() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 18/24] gdbstub: Set gdb_set_stop_cpu() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 19/24] cpus: Change cpu_handle_guest_debug() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 20/24] cpus: Change qemu_kvm_start_vcpu() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 21/24] cpus: Change qemu_dummy_start_vcpu() " Andreas Färber
2013-06-28 15:55 ` [Qemu-devel] [PULL 22/24] cpu: Change qemu_init_vcpu() " Andreas Färber
2013-06-28 15:55 ` Andreas Färber [this message]
2013-06-28 15:55 ` [Qemu-devel] [PULL 24/24] cpu: Turn cpu_unassigned_access() into a CPUState hook Andreas Färber

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=1372434946-18489-24-git-send-email-afaerber@suse.de \
    --to=afaerber@suse.de \
    --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).