diff mbox series

[RFC,v2,19/20] stubs/vmstate: Add VMSTATE_END_OF_LIST to vmstate_user_mode_cpu_dummy

Message ID 20210117192446.23753-20-f4bug@amsat.org (mailing list archive)
State New, archived
Headers show
Series hw: Mark the device with no migratable fields | expand

Commit Message

Philippe Mathieu-Daudé Jan. 17, 2021, 7:24 p.m. UTC
Add a name and end marker to the vmstate_user_mode_cpu_dummy variable.

Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 stubs/vmstate.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

Comments

Dr. David Alan Gilbert Jan. 20, 2021, 10:56 a.m. UTC | #1
* Philippe Mathieu-Daudé (f4bug@amsat.org) wrote:
> Add a name and end marker to the vmstate_user_mode_cpu_dummy variable.
> 
> Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>

> ---
>  stubs/vmstate.c | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/stubs/vmstate.c b/stubs/vmstate.c
> index f561f9f39bd..1d0e03e233b 100644
> --- a/stubs/vmstate.c
> +++ b/stubs/vmstate.c
> @@ -2,7 +2,12 @@
>  #include "migration/vmstate.h"
>  
>  #if defined(CONFIG_USER_ONLY)
> -const VMStateDescription vmstate_user_mode_cpu_dummy = {};
> +const VMStateDescription vmstate_user_mode_cpu_dummy = {
> +    .name = "cpu_common_user",
> +    .fields = (VMStateField[]) {
> +        VMSTATE_END_OF_LIST()
> +    },
> +};
>  #endif
>  
>  const VMStateDescription vmstate_no_state_to_migrate = {
> -- 
> 2.26.2
>
diff mbox series

Patch

diff --git a/stubs/vmstate.c b/stubs/vmstate.c
index f561f9f39bd..1d0e03e233b 100644
--- a/stubs/vmstate.c
+++ b/stubs/vmstate.c
@@ -2,7 +2,12 @@ 
 #include "migration/vmstate.h"
 
 #if defined(CONFIG_USER_ONLY)
-const VMStateDescription vmstate_user_mode_cpu_dummy = {};
+const VMStateDescription vmstate_user_mode_cpu_dummy = {
+    .name = "cpu_common_user",
+    .fields = (VMStateField[]) {
+        VMSTATE_END_OF_LIST()
+    },
+};
 #endif
 
 const VMStateDescription vmstate_no_state_to_migrate = {