On 12.01.23 19:36, Dr. David Alan Gilbert wrote:
* David Hildenbrand (da...@redhat.com) wrote:
On 12.01.23 17:58, Dr. David Alan Gilbert wrote:
* David Hildenbrand (da...@redhat.com) wrote:
Let's move more code into vmstate_save(), reducing code duplication and
preparing for reuse of vmstate_save() in qemu_savevm_state_setup(). We
have to move vmstate_save() to make the compiler happy.

We'll now also trace from qemu_save_device_state().

Mostly OK, but..

Signed-off-by: David Hildenbrand <da...@redhat.com>
---
   migration/savevm.c | 79 ++++++++++++++++++++++------------------------

Doesn't this also need to upate trace-events?

The existing trace events from
qemu_savevm_state_complete_precopy_non_iterable() are simply moved to
vmstate_save(), so qemu_save_device_state() will implicitly use them.

So no update should be needed (no new events), or am I missing something?

Aren't you losing the trace_savevm_state_setup() trace?

trace_savevm_state_setup() is called from qemu_savevm_state_setup() before/after this change.

Calling it from qemu_save_device_state() would be wrong: they skip the setup phase and don't call any save_setup() -- skipping all "se->is_ram".

--
Thanks,

David / dhildenb


Reply via email to