Message ID | 1344369413-9053-2-git-send-email-ehabkost@redhat.com |
---|---|
State | New |
Headers | show |
On 08/07/2012 09:56 PM, Eduardo Habkost wrote: > Needed for the definition of fprint_function. > > This is not necessary right now, but it will be necessary if code that > doesn't include cpu-common.h includes cpus.h. could fprint_function declaration be moved somewhere else? A lot of headers include cpu-common.h just for the sake of these simple/independent declarations and forward declared structures pointers. Maybe these trivial cases could be moved in separate header qemu-common-trivial.h. It could replace cpu-common.h in most headers and would help to untangle circular deps between cpu-common.h and cpu.h and reduce complications when one tries to embed in cpu some Device/SysBusDevice as a child. > > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> > --- > cpus.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/cpus.h b/cpus.h > index 81bd817..061ff7f 100644 > --- a/cpus.h > +++ b/cpus.h > @@ -1,6 +1,8 @@ > #ifndef QEMU_CPUS_H > #define QEMU_CPUS_H > > +#include "qemu-common.h" > + > /* cpus.c */ > void qemu_init_cpu_loop(void); > void resume_all_vcpus(void); >
diff --git a/cpus.h b/cpus.h index 81bd817..061ff7f 100644 --- a/cpus.h +++ b/cpus.h @@ -1,6 +1,8 @@ #ifndef QEMU_CPUS_H #define QEMU_CPUS_H +#include "qemu-common.h" + /* cpus.c */ void qemu_init_cpu_loop(void); void resume_all_vcpus(void);
Needed for the definition of fprint_function. This is not necessary right now, but it will be necessary if code that doesn't include cpu-common.h includes cpus.h. Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> --- cpus.h | 2 ++ 1 file changed, 2 insertions(+)