diff mbox

[for-2.4,v3,2/3] migration: Add configuration section to vmstate with xen.

Message ID 1438612161-15822-3-git-send-email-anthony.perard@citrix.com
State New
Headers show

Commit Message

Anthony PERARD Aug. 3, 2015, 2:29 p.m. UTC
This adds the configuration section in the vmstate saved by
xen_save_devices_state.

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
---
 migration/savevm.c | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Stefano Stabellini Aug. 3, 2015, 2:48 p.m. UTC | #1
On Mon, 3 Aug 2015, Anthony PERARD wrote:
> This adds the configuration section in the vmstate saved by
> xen_save_devices_state.
> 
> Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>

It doesn't seem to me that this patch is actually necessary to fix the
issue, is that right? 

If that is the case, I would rather skip it.


>  migration/savevm.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/migration/savevm.c b/migration/savevm.c
> index 6071215..b3f605c 100644
> --- a/migration/savevm.c
> +++ b/migration/savevm.c
> @@ -961,6 +961,11 @@ static int qemu_save_device_state(QEMUFile *f)
>  
>      cpu_synchronize_all_states();
>  
> +    if (!savevm_state.skip_configuration) {
> +        qemu_put_byte(f, QEMU_VM_CONFIGURATION);
> +        vmstate_save_state(f, &vmstate_configuration, &savevm_state, 0);
> +    }
> +
>      QTAILQ_FOREACH(se, &savevm_state.handlers, entry) {
>          if (se->is_ram) {
>              continue;
> -- 
> Anthony PERARD
>
Anthony PERARD Aug. 3, 2015, 2:53 p.m. UTC | #2
On Mon, Aug 03, 2015 at 03:48:18PM +0100, Stefano Stabellini wrote:
> On Mon, 3 Aug 2015, Anthony PERARD wrote:
> > This adds the configuration section in the vmstate saved by
> > xen_save_devices_state.
> > 
> > Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
> 
> It doesn't seem to me that this patch is actually necessary to fix the
> issue, is that right? 

No, it is not. This is going to be skipped with the next patch and with
accel=xen.

> If that is the case, I would rather skip it.
> 
> 
> >  migration/savevm.c | 5 +++++
> >  1 file changed, 5 insertions(+)
> > 
> > diff --git a/migration/savevm.c b/migration/savevm.c
> > index 6071215..b3f605c 100644
> > --- a/migration/savevm.c
> > +++ b/migration/savevm.c
> > @@ -961,6 +961,11 @@ static int qemu_save_device_state(QEMUFile *f)
> >  
> >      cpu_synchronize_all_states();
> >  
> > +    if (!savevm_state.skip_configuration) {
> > +        qemu_put_byte(f, QEMU_VM_CONFIGURATION);
> > +        vmstate_save_state(f, &vmstate_configuration, &savevm_state, 0);
> > +    }
> > +
> >      QTAILQ_FOREACH(se, &savevm_state.handlers, entry) {
> >          if (se->is_ram) {
> >              continue;
> > -- 
> > Anthony PERARD
> >
diff mbox

Patch

diff --git a/migration/savevm.c b/migration/savevm.c
index 6071215..b3f605c 100644
--- a/migration/savevm.c
+++ b/migration/savevm.c
@@ -961,6 +961,11 @@  static int qemu_save_device_state(QEMUFile *f)
 
     cpu_synchronize_all_states();
 
+    if (!savevm_state.skip_configuration) {
+        qemu_put_byte(f, QEMU_VM_CONFIGURATION);
+        vmstate_save_state(f, &vmstate_configuration, &savevm_state, 0);
+    }
+
     QTAILQ_FOREACH(se, &savevm_state.handlers, entry) {
         if (se->is_ram) {
             continue;