[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1/3] migration: Use savevm_handlers instead of l
From: |
Juan Quintela |
Subject: |
Re: [Qemu-devel] [PATCH 1/3] migration: Use savevm_handlers instead of loadvm copy |
Date: |
Wed, 24 May 2017 16:35:43 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) |
Laurent Vivier <address@hidden> wrote:
> On 24/05/2017 10:55, Juan Quintela wrote:
>> From: Juan Quintela <address@hidden>
>>
>> There is no reason for having the loadvm_handlers at all. There is
>> only one use, and we can use the savevm handlers.
>>
>> We will remove the loadvm handlers on a following patch.
>>
>> Signed-off-by: Juan Quintela <address@hidden>
>> + QTAILQ_FOREACH(se, &savevm_state.handlers, entry) {
>> + if (se->section_id == section_id) {
>> break;
>> }
>> }
>> - if (le == NULL) {
>> + if (se == NULL) {
>> error_report("Unknown savevm section %d", section_id);
>> return -EINVAL;
>> }
>>
>> - ret = vmstate_load(f, le->se, le->version_id);
>> + ret = vmstate_load(f, se, se->version_id);
> Are you sure you can replace le->version_id by se->version?
>
> Because according to code in qemu_loadvm_section_start_full(),
> we can have le->version_id <= se->version_id.
You are right. We don't use basically anymore version_id, but we used
to use it.
I will arrive to a different solution. Thanks a lot.
Later, Juan.