mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 17:53:56 -06:00
migration: convert to NotifierWithReturn
Change all migration notifiers to type NotifierWithReturn, so notifiers can return an error status in a future patch. For now, pass NULL for the notifier error parameter, and do not check the return value. Signed-off-by: Steve Sistare <steven.sistare@oracle.com> Reviewed-by: Peter Xu <peterx@redhat.com> Reviewed-by: David Hildenbrand <david@redhat.com> Link: https://lore.kernel.org/r/1708622920-68779-4-git-send-email-steven.sistare@oracle.com [peterx: dropped unexpected update to roms/seabios-hppa] Signed-off-by: Peter Xu <peterx@redhat.com>
This commit is contained in:
parent
d91f33c72e
commit
3e7757301c
9 changed files with 29 additions and 20 deletions
|
@ -754,7 +754,8 @@ static void vfio_vmstate_change(void *opaque, bool running, RunState state)
|
|||
mig_state_to_str(new_state));
|
||||
}
|
||||
|
||||
static void vfio_migration_state_notifier(Notifier *notifier, void *data)
|
||||
static int vfio_migration_state_notifier(NotifierWithReturn *notifier,
|
||||
void *data, Error **errp)
|
||||
{
|
||||
MigrationState *s = data;
|
||||
VFIOMigration *migration = container_of(notifier, VFIOMigration,
|
||||
|
@ -770,6 +771,7 @@ static void vfio_migration_state_notifier(Notifier *notifier, void *data)
|
|||
case MIGRATION_STATUS_FAILED:
|
||||
vfio_migration_set_state_or_reset(vbasedev, VFIO_DEVICE_STATE_RUNNING);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void vfio_migration_free(VFIODevice *vbasedev)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue