Skip to contentSkip to conversation

macio/pmu: Fix missing vmsd terminator

PATCH In review Dr. David Alan Gilbert (git) 4 participants 9 messages Jul 27, 2018 – Oct 17, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 macio/pmu: Fix missing vmsd terminator

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
 hw/misc/macio/pmu.c | 1 +
 1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +1 -0
index e246b0fd41..27dfaf8a74 100644
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
         VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
         VMSTATE_UINT8(adb_reply_size, PMUState),
         VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
     }
 };
 
Signature · 1 line
2.17.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
  hw/misc/macio/pmu.c | 1 +
  1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
          VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
          VMSTATE_UINT8(adb_reply_size, PMUState),
          VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
      }
  };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

ATB,

Mark.

#2 lore raw
Quoted 27 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
  hw/misc/macio/pmu.c | 1 +
  1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
          VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
          VMSTATE_UINT8(adb_reply_size, PMUState),
          VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
      }
  };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Quoted 4 lines

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

Have you got a suggested command line to test it with?

Dave

Quoted 4 lines

ATB,

Mark.

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

#3 lore raw
Quoted 28 lines · Dr. David Alan Gilbert
Quoted 27 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
   hw/misc/macio/pmu.c | 1 +
   1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
           VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
           VMSTATE_UINT8(adb_reply_size, PMUState),
           VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
       }
   };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Quoted 6 lines
Quoted 4 lines

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

Have you got a suggested command line to test it with?

I'm effectively AFK until tomorrow now, but just quickly:

$ ./qemu-system-ppc -M mac99,via=pmu

Note that PMU support is new for 3.0 so there shouldn't be any backward compatibility issue here.

ATB,

Mark.

#4 lore raw
Quoted 35 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 33 lines · Dr. David Alan Gilbert
Quoted 31 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
   hw/misc/macio/pmu.c | 1 +
   1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
           VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
           VMSTATE_UINT8(adb_reply_size, PMUState),
           VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
       }
   };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

Quoted 8 lines
Quoted 1 line

Have you got a suggested command line to test it with?

I'm effectively AFK until tomorrow now, but just quickly:

$ ./qemu-system-ppc -M mac99,via=pmu

Note that PMU support is new for 3.0 so there shouldn't be any backward compatibility issue here.

[root@virtlab414 try-64]# ./ppc-softmmu/qemu-system-ppc -M mac99,via=pmu -nographic /home/vms/dummy1.qcow2 QEMU 2.12.50 monitor - type 'help' for more information
(qemu) ss>> et_property: NULL phandle

Quoted 7 lines
Quoted 7 lines

=============================================================
OpenBIOS 1.1 [Jun 18 2018 18:20] Configuration device id QEMU version 1 machine id 1
CPUs: 1
Memory: 128M
UUID: 00000000-0000-0000-0000-000000000000 CPU type PowerPC,G4

milliseconds isn't unique.
saWelcome to OpenBIOS v1.1 built on Jun 18 2018 18:20 Trying hd:,\\:tbxi...
savTrying hd:,\ppc\bootinfo.txt...
Trying hd:,%BOOT...
saveNo valid state has been set by load or init-program

(qemu)
ok
0 > ok
0 > (qemu)
(qemu) savevm "frob"
(qemu) loadvm "frob"
(qemu)
ok
0 > 2 2 + . 4 ok

Looks OK to me.

Dave

Quoted 4 lines

ATB,

Mark.

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

#5 lore raw

I noticed this hadn't got merged - who wants it?

Dave

Quoted 76 lines · * Dr. David Alan Gilbert ([email protected]) wrote:
Quoted 35 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 33 lines · Dr. David Alan Gilbert
Quoted 31 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
   hw/misc/macio/pmu.c | 1 +
   1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
           VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
           VMSTATE_UINT8(adb_reply_size, PMUState),
           VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
       }
   };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

Quoted 8 lines
Quoted 1 line

Have you got a suggested command line to test it with?

I'm effectively AFK until tomorrow now, but just quickly:

$ ./qemu-system-ppc -M mac99,via=pmu

Note that PMU support is new for 3.0 so there shouldn't be any backward compatibility issue here.

[root@virtlab414 try-64]# ./ppc-softmmu/qemu-system-ppc -M mac99,via=pmu -nographic /home/vms/dummy1.qcow2 QEMU 2.12.50 monitor - type 'help' for more information
(qemu) ss>> et_property: NULL phandle

Quoted 7 lines
Quoted 7 lines

=============================================================
OpenBIOS 1.1 [Jun 18 2018 18:20] Configuration device id QEMU version 1 machine id 1
CPUs: 1
Memory: 128M
UUID: 00000000-0000-0000-0000-000000000000 CPU type PowerPC,G4

milliseconds isn't unique.
saWelcome to OpenBIOS v1.1 built on Jun 18 2018 18:20 Trying hd:,\\:tbxi...
savTrying hd:,\ppc\bootinfo.txt...
Trying hd:,%BOOT...
saveNo valid state has been set by load or init-program

(qemu)
ok
0 > ok
0 > (qemu)
(qemu) savevm "frob"
(qemu) loadvm "frob"
(qemu)
ok
0 > 2 2 + . 4 ok

Looks OK to me.

Quoted 9 lines

Dave

Quoted 4 lines

ATB,

Mark.

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

--
Dr. David Alan Gilbert / [email protected] / Manchester, UK

#6 lore raw
Quoted 2 lines · Dr. David Alan Gilbert

I noticed this hadn't got merged - who wants it?

I think that's one for my tree, but I'm afraid I completely missed it before. It's generally best to CC me on ppc related patches, otherwise I'm likely to lose them in the flood of qemu-devel.

Anyway, I dug it out of my archives and applied.

Quoted 86 lines

Dave

Quoted 82 lines · * Dr. David Alan Gilbert ([email protected]) wrote:
Quoted 35 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 33 lines · Dr. David Alan Gilbert
Quoted 31 lines · * Mark Cave-Ayland ([email protected]) wrote:
Quoted 15 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
   hw/misc/macio/pmu.c | 1 +
   1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 691

Quoted 6 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
           VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
           VMSTATE_UINT8(adb_reply_size, PMUState),
           VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
       }
   };

Gah, yes indeed it certainly looks like I missed this whilst working on the PMU code :(

Just out of interest does a savevm/loadvm migration still succeed once this has been added?

Quoted 8 lines
Quoted 1 line

Have you got a suggested command line to test it with?

I'm effectively AFK until tomorrow now, but just quickly:

$ ./qemu-system-ppc -M mac99,via=pmu

Note that PMU support is new for 3.0 so there shouldn't be any backward compatibility issue here.

[root@virtlab414 try-64]# ./ppc-softmmu/qemu-system-ppc -M mac99,via=pmu -nographic /home/vms/dummy1.qcow2 QEMU 2.12.50 monitor - type 'help' for more information
(qemu) ss>> et_property: NULL phandle

Quoted 7 lines
Quoted 7 lines

=============================================================
OpenBIOS 1.1 [Jun 18 2018 18:20] Configuration device id QEMU version 1 machine id 1
CPUs: 1
Memory: 128M
UUID: 00000000-0000-0000-0000-000000000000 CPU type PowerPC,G4

milliseconds isn't unique.
saWelcome to OpenBIOS v1.1 built on Jun 18 2018 18:20 Trying hd:,\\:tbxi...
savTrying hd:,\ppc\bootinfo.txt...
Trying hd:,%BOOT...
saveNo valid state has been set by load or init-program

(qemu)
ok
0 > ok
0 > (qemu)
(qemu) savevm "frob"
(qemu) loadvm "frob"
(qemu)
ok
0 > 2 2 + . 4 ok

Looks OK to me.

Dave

Quoted 4 lines

ATB,

Mark.

Signature · 4 lines
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
#7 lore raw
Quoted 9 lines · David Gibson
Quoted 2 lines · Dr. David Alan Gilbert

I noticed this hadn't got merged - who wants it?

I think that's one for my tree, but I'm afraid I completely missed it before. It's generally best to CC me on ppc related patches, otherwise I'm likely to lose them in the flood of qemu-devel.

Anyway, I dug it out of my archives and applied.

Great - thanks David. Apologies for the delay in my response, I've been fairly flat out recently so not much time for QEMU hacking.

ATB,

Mark.

Reviewed-by on v1 1/1
#8 lore raw
In reply to Dr. David Alan Gilbert (git)
Quoted 16 lines · Dr. David Alan Gilbert (git)

From: "Dr. David Alan Gilbert" <[email protected]>

Fix missing terminator in VMStateDescription

Fixes d811d61fbc6ca5f2be2185fd7cfa916e7ba613ce
---
 hw/misc/macio/pmu.c | 1 +
 1 file changed, 1 insertion(+)
hw/misc/macio/pmu.c +0 -0
index e246b0fd41..27dfaf8a74 100644

hw/misc/macio/pmu.c static const VMStateDescription vmstate_pmu_adb = { · line 692

Quoted 7 lines
hw/misc/macio/pmu.c +1 -0
@@ -686,6 +686,7 @@ static const VMStateDescription vmstate_pmu_adb = {
         VMSTATE_TIMER_PTR(adb_poll_timer, PMUState),
         VMSTATE_UINT8(adb_reply_size, PMUState),
         VMSTATE_BUFFER(adb_reply, PMUState),
+        VMSTATE_END_OF_LIST()
     }
 };