diff mbox

[1/3] Make 'qemu_init_vcpu' a function (instead of a macro)

Message ID 20110921132322.3516.25189.stgit@ginnungagap.bsc.es
State New
Headers show

Commit Message

Lluís Vilanova Sept. 21, 2011, 1:23 p.m. UTC
Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
---
 qemu-common.h |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

Comments

Lluís Vilanova Sept. 21, 2011, 1:45 p.m. UTC | #1
Please ignore these patches.

Implementation of 'qemu_init_vcpu' in CONFIG_USER_ONLY must be moved into a C
file to avoid an include loop between trace.h and qemu-common.h

Ideas on which file this is supposed to go?


Lluis

Lluís Vilanova writes:

> Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
> ---
>  qemu-common.h |    4 +++-
>  1 files changed, 3 insertions(+), 1 deletions(-)

> diff --git a/qemu-common.h b/qemu-common.h
> index 404c421..fca101e 100644
> --- a/qemu-common.h
> +++ b/qemu-common.h
> @@ -297,7 +297,9 @@ struct qemu_work_item {
>  };
 
>  #ifdef CONFIG_USER_ONLY
> -#define qemu_init_vcpu(env) do { } while (0)
> +static inline void qemu_init_vcpu(void *env)
> +{
> +}
>  #else
>  void qemu_init_vcpu(void *env);
>  #endif
diff mbox

Patch

diff --git a/qemu-common.h b/qemu-common.h
index 404c421..fca101e 100644
--- a/qemu-common.h
+++ b/qemu-common.h
@@ -297,7 +297,9 @@  struct qemu_work_item {
 };
 
 #ifdef CONFIG_USER_ONLY
-#define qemu_init_vcpu(env) do { } while (0)
+static inline void qemu_init_vcpu(void *env)
+{
+}
 #else
 void qemu_init_vcpu(void *env);
 #endif