diff mbox series

[06/10] exec/ramblock: Add missing includes

Message ID 20220203193803.45671-7-f4bug@amsat.org (mailing list archive)
State New, archived
Headers show
Series exec: Remove 'qemu/log.h' from 'exec-all.h' | expand

Commit Message

Philippe Mathieu-Daudé Feb. 3, 2022, 7:37 p.m. UTC
Add missing includes to avoid when refactoring include/

  include/exec/ramblock.h:26:21: error: field has incomplete type 'struct rcu_head'
    struct rcu_head rcu;
                    ^

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 include/exec/ramblock.h | 2 ++
 1 file changed, 2 insertions(+)

Comments

Thomas Huth Feb. 4, 2022, 2:59 p.m. UTC | #1
On 03/02/2022 20.37, Philippe Mathieu-Daudé wrote:
> Add missing includes to avoid when refactoring include/
> 
>    include/exec/ramblock.h:26:21: error: field has incomplete type 'struct rcu_head'
>      struct rcu_head rcu;
>                      ^

... and errors due to missing definition of RAMBlockNotifier.

> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
>   include/exec/ramblock.h | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/include/exec/ramblock.h b/include/exec/ramblock.h
> index 664701b759..6cbedf9e0c 100644
> --- a/include/exec/ramblock.h
> +++ b/include/exec/ramblock.h
> @@ -21,6 +21,8 @@
>   
>   #ifndef CONFIG_USER_ONLY
>   #include "cpu-common.h"
> +#include "qemu/rcu.h"
> +#include "exec/ramlist.h"
>   
>   struct RAMBlock {
>       struct rcu_head rcu;

Reviewed-by: Thomas Huth <thuth@redhat.com>
Richard Henderson Feb. 5, 2022, 11:50 p.m. UTC | #2
On 2/4/22 06:37, Philippe Mathieu-Daudé wrote:
> Add missing includes to avoid when refactoring include/
> 
>    include/exec/ramblock.h:26:21: error: field has incomplete type 'struct rcu_head'
>      struct rcu_head rcu;
>                      ^
> 
> Signed-off-by: Philippe Mathieu-Daudé<f4bug@amsat.org>
> ---
>   include/exec/ramblock.h | 2 ++
>   1 file changed, 2 insertions(+)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~
diff mbox series

Patch

diff --git a/include/exec/ramblock.h b/include/exec/ramblock.h
index 664701b759..6cbedf9e0c 100644
--- a/include/exec/ramblock.h
+++ b/include/exec/ramblock.h
@@ -21,6 +21,8 @@ 
 
 #ifndef CONFIG_USER_ONLY
 #include "cpu-common.h"
+#include "qemu/rcu.h"
+#include "exec/ramlist.h"
 
 struct RAMBlock {
     struct rcu_head rcu;