History log of /qemu/migration/qemu-file.h (Results 1 – 25 of 106)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: v8.2.2, v7.2.10
# 7f5b50a4 29-Feb-2024 Fabiano Rosas <farosas@suse.de>

migration/qemu-file: add utility methods for working with seekable channels

Add utility methods that will be needed when implementing 'mapped-ram'
migration capability.

Signed-off-by: Fabiano Rosas

migration/qemu-file: add utility methods for working with seekable channels

Add utility methods that will be needed when implementing 'mapped-ram'
migration capability.

Signed-off-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: "Daniel P. Berrangé" <berrange@redhat.com>
Link: https://lore.kernel.org/r/20240229153017.2221-7-farosas@suse.de
Signed-off-by: Peter Xu <peterx@redhat.com>

show more ...


Revision tags: v8.2.2, v7.2.10
# 7f5b50a4 29-Feb-2024 Fabiano Rosas <farosas@suse.de>

migration/qemu-file: add utility methods for working with seekable channels

Add utility methods that will be needed when implementing 'mapped-ram'
migration capability.

Signed-off-by: Fabiano Rosas

migration/qemu-file: add utility methods for working with seekable channels

Add utility methods that will be needed when implementing 'mapped-ram'
migration capability.

Signed-off-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: "Daniel P. Berrangé" <berrange@redhat.com>
Link: https://lore.kernel.org/r/20240229153017.2221-7-farosas@suse.de
Signed-off-by: Peter Xu <peterx@redhat.com>

show more ...


Revision tags: v8.2.1, v8.1.5, v7.2.9, v8.1.4, v7.2.8, v8.2.0, v8.2.0-rc4, v8.2.0-rc3, v8.2.0-rc2, v8.2.0-rc1, v7.2.7, v8.1.3, v8.2.0-rc0
# 7aa6070d 17-Oct-2023 Peter Xu <peterx@redhat.com>

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_err

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_error),
but also not good enough in that we only do error_report() and set it to
true, we never can keep a history of the exact error and show it in
query-migrate.

To make this better, a few things done:

- Use error_setg() rather than error_report() across the whole lifecycle
of return path thread, keeping the error in an Error*.

- With above, no need to have mark_source_rp_bad(), remove it, alongside
with rp_state.error itself.

- Use migrate_set_error() to apply that captured error to the global
migration object when error occured in this thread.

- Do the same when detected qemufile error in source return path

We need to re-export qemu_file_get_error_obj() to do the last one.

Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231017202633.296756-2-peterx@redhat.com>

show more ...


Revision tags: v8.2.1, v8.1.5, v7.2.9, v8.1.4, v7.2.8, v8.2.0, v8.2.0-rc4, v8.2.0-rc3, v8.2.0-rc2, v8.2.0-rc1, v7.2.7, v8.1.3, v8.2.0-rc0
# 7aa6070d 17-Oct-2023 Peter Xu <peterx@redhat.com>

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_err

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_error),
but also not good enough in that we only do error_report() and set it to
true, we never can keep a history of the exact error and show it in
query-migrate.

To make this better, a few things done:

- Use error_setg() rather than error_report() across the whole lifecycle
of return path thread, keeping the error in an Error*.

- With above, no need to have mark_source_rp_bad(), remove it, alongside
with rp_state.error itself.

- Use migrate_set_error() to apply that captured error to the global
migration object when error occured in this thread.

- Do the same when detected qemufile error in source return path

We need to re-export qemu_file_get_error_obj() to do the last one.

Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231017202633.296756-2-peterx@redhat.com>

show more ...


Revision tags: v8.2.1, v8.1.5, v7.2.9, v8.1.4, v7.2.8, v8.2.0, v8.2.0-rc4, v8.2.0-rc3, v8.2.0-rc2, v8.2.0-rc1, v7.2.7, v8.1.3, v8.2.0-rc0
# 7aa6070d 17-Oct-2023 Peter Xu <peterx@redhat.com>

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_err

migration: Refactor error handling in source return path

rp_state.error was a boolean used to show error happened in return path
thread. That's not only duplicating error reporting (migrate_set_error),
but also not good enough in that we only do error_report() and set it to
true, we never can keep a history of the exact error and show it in
query-migrate.

To make this better, a few things done:

- Use error_setg() rather than error_report() across the whole lifecycle
of return path thread, keeping the error in an Error*.

- With above, no need to have mark_source_rp_bad(), remove it, alongside
with rp_state.error itself.

- Use migrate_set_error() to apply that captured error to the global
migration object when error occured in this thread.

- Do the same when detected qemufile error in source return path

We need to re-export qemu_file_get_error_obj() to do the last one.

Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231017202633.296756-2-peterx@redhat.com>

show more ...


# be07a0ed 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret = qemu_fflush(f);
if (ret) {
return ret;
}

I updated all callers where there is any error check.
qemu_fclose() don't need to check for f->last_error because
qemu_fflush() returns it at the beggining of the function.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-13-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e9c0eed7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Ju

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-7-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e833cad7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.co

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.com>

show more ...


# be07a0ed 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret = qemu_fflush(f);
if (ret) {
return ret;
}

I updated all callers where there is any error check.
qemu_fclose() don't need to check for f->last_error because
qemu_fflush() returns it at the beggining of the function.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-13-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e9c0eed7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Ju

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-7-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e833cad7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.co

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.com>

show more ...


# be07a0ed 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret

qemu-file: Make qemu_fflush() return errors

This let us simplify code of this shape.

qemu_fflush(f);
int ret = qemu_file_get_error(f);
if (ret) {
return ret;
}

into:

int ret = qemu_fflush(f);
if (ret) {
return ret;
}

I updated all callers where there is any error check.
qemu_fclose() don't need to check for f->last_error because
qemu_fflush() returns it at the beggining of the function.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-13-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e9c0eed7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Ju

qemu-file: Remove _noflush from qemu_file_transferred_noflush()

qemu_file_transferred() don't exist anymore, so we can reuse the name.

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>

Message-ID: <20231025091117.6342-7-quintela@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

show more ...


# e833cad7 25-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.co

qemu_file: Remove unused qemu_file_transferred()

Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231025091117.6342-6-quintela@redhat.com>

show more ...


Revision tags: v8.1.2
# 10cb3336 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Move rdma constants from qemu-file.h to rdma.h

Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat

migration/rdma: Move rdma constants from qemu-file.h to rdma.h

Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-9-quintela@redhat.com>

show more ...


# 8b670f48 11-Oct-2023 Juan Quintela <quintela@redhat.com>

qemu-file: Remove QEMUFileHooks

The only user was rdma, and its use is gone.

Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <

qemu-file: Remove QEMUFileHooks

The only user was rdma, and its use is gone.

Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-8-quintela@redhat.com>

show more ...


# e493008d 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Create rdma_control_save_page()

The only user of ram_control_save_page() and save_page() hook was
rdma. Just move the function to rdma.c, rename it to
rdma_control_save_page().

Revi

migration/rdma: Create rdma_control_save_page()

The only user of ram_control_save_page() and save_page() hook was
rdma. Just move the function to rdma.c, rename it to
rdma_control_save_page().

Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-7-quintela@redhat.com>

show more ...


# a6323300 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Unfold hook_ram_load()

There is only one flag called with: RAM_CONTROL_BLOCK_REG.

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>

migration/rdma: Unfold hook_ram_load()

There is only one flag called with: RAM_CONTROL_BLOCK_REG.

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-6-quintela@redhat.com>

show more ...


# f6d6c089 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Remove all uses of RAM_CONTROL_HOOK

Instead of going through ram_control_load_hook(), call
qemu_rdma_registration_handle() directly.

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>

migration/rdma: Remove all uses of RAM_CONTROL_HOOK

Instead of going through ram_control_load_hook(), call
qemu_rdma_registration_handle() directly.

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-5-quintela@redhat.com>

show more ...


# 5f5b8858 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Unfold ram_control_after_iterate()

Once there:
- Remove unused data parameter
- unfold it in its callers
- change all callers to call qemu_rdma_registration_stop()
- We need to call

migration/rdma: Unfold ram_control_after_iterate()

Once there:
- Remove unused data parameter
- unfold it in its callers
- change all callers to call qemu_rdma_registration_stop()
- We need to call QIO_CHANNEL_RDMA() after we check for migrate_rdma()

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-4-quintela@redhat.com>

show more ...


# 48408174 11-Oct-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Unfold ram_control_before_iterate()

Once there:
- Remove unused data parameter
- unfold it in its callers.
- change all callers to call qemu_rdma_registration_start()
- We need to ca

migration/rdma: Unfold ram_control_before_iterate()

Once there:
- Remove unused data parameter
- unfold it in its callers.
- change all callers to call qemu_rdma_registration_start()
- We need to call QIO_CHANNEL_RDMA() after we check for migrate_rdma()

Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Reviewed-by: Fabiano Rosas <farosas@suse.de>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-ID: <20231011203527.9061-3-quintela@redhat.com>

show more ...


Revision tags: v8.1.1, v7.2.6, v8.0.5, v8.1.0, v8.1.0-rc4, v8.1.0-rc3, v7.2.5, v8.0.4, v8.1.0-rc2, v8.1.0-rc1, v8.1.0-rc0, v8.0.3, v7.2.4, v8.0.2, v8.0.1, v7.2.3
# 9c53d369 15-May-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Simplify the function that saves a page

When we sent a page through QEMUFile hooks (RDMA) there are three
posiblities:
- We are not using RDMA. return RAM_SAVE_CONTROL_DELAYED and

migration/rdma: Simplify the function that saves a page

When we sent a page through QEMUFile hooks (RDMA) there are three
posiblities:
- We are not using RDMA. return RAM_SAVE_CONTROL_DELAYED and
control_save_page() returns false to let anything else to proceed.
- There is one error but we are using RDMA. Then we return a negative
value, control_save_page() needs to return true.
- Everything goes well and RDMA start the sent of the page
asynchronously. It returns RAM_SAVE_CONTROL_DELAYED and we need to
return 1 for ram_save_page_legacy.

Clear?

I know, I know, the interface is as bad as it gets. I think that now
it is a bit clearer, but this needs to be done some other way.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20230515195709.63843-16-quintela@redhat.com>

show more ...


# 9f51fe92 15-May-2023 Juan Quintela <quintela@redhat.com>

migration: Remove unused qemu_file_credit_transfer()

After this change, nothing abuses QEMUFile to account for data
transferrefd during migration.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Si

migration: Remove unused qemu_file_credit_transfer()

After this change, nothing abuses QEMUFile to account for data
transferrefd during migration.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20230515195709.63843-15-quintela@redhat.com>

show more ...


Revision tags: v8.1.1, v7.2.6, v8.0.5, v8.1.0, v8.1.0-rc4, v8.1.0-rc3, v7.2.5, v8.0.4, v8.1.0-rc2, v8.1.0-rc1, v8.1.0-rc0, v8.0.3, v7.2.4, v8.0.2, v8.0.1, v7.2.3
# 9c53d369 15-May-2023 Juan Quintela <quintela@redhat.com>

migration/rdma: Simplify the function that saves a page

When we sent a page through QEMUFile hooks (RDMA) there are three
posiblities:
- We are not using RDMA. return RAM_SAVE_CONTROL_DELAYED and

migration/rdma: Simplify the function that saves a page

When we sent a page through QEMUFile hooks (RDMA) there are three
posiblities:
- We are not using RDMA. return RAM_SAVE_CONTROL_DELAYED and
control_save_page() returns false to let anything else to proceed.
- There is one error but we are using RDMA. Then we return a negative
value, control_save_page() needs to return true.
- Everything goes well and RDMA start the sent of the page
asynchronously. It returns RAM_SAVE_CONTROL_DELAYED and we need to
return 1 for ram_save_page_legacy.

Clear?

I know, I know, the interface is as bad as it gets. I think that now
it is a bit clearer, but this needs to be done some other way.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20230515195709.63843-16-quintela@redhat.com>

show more ...


# 9f51fe92 15-May-2023 Juan Quintela <quintela@redhat.com>

migration: Remove unused qemu_file_credit_transfer()

After this change, nothing abuses QEMUFile to account for data
transferrefd during migration.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Si

migration: Remove unused qemu_file_credit_transfer()

After this change, nothing abuses QEMUFile to account for data
transferrefd during migration.

Reviewed-by: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Message-Id: <20230515195709.63843-15-quintela@redhat.com>

show more ...


12345