mirror of
https://github.com/qemu/qemu.git
synced 2026-02-04 05:35:39 +00:00
migration/vfio: compile only once
Acked-by: Fabiano Rosas <farosas@suse.de> Reviewed-by: Peter Xu <peterx@redhat.com> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-ID: <20250730220435.1139101-3-pierrick.bouvier@linaro.org> [PMD: Cover vfio-stub.c in MAINTAINERS] Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
This commit is contained in:
committed by
Philippe Mathieu-Daudé
parent
7ef54b7bf3
commit
01b6fb3705
@@ -2268,6 +2268,7 @@ F: util/vfio-helpers.c
|
||||
F: include/hw/vfio/
|
||||
F: docs/devel/migration/vfio.rst
|
||||
F: qapi/vfio.json
|
||||
F: migration/vfio-stub.c
|
||||
F: tests/functional/aarch64/test_device_passthrough.py
|
||||
|
||||
vfio-igd
|
||||
|
||||
@@ -49,6 +49,6 @@ system_ss.add(when: zstd, if_true: files('multifd-zstd.c'))
|
||||
system_ss.add(when: qpl, if_true: files('multifd-qpl.c'))
|
||||
system_ss.add(when: uadk, if_true: files('multifd-uadk.c'))
|
||||
system_ss.add(when: qatzip, if_true: files('multifd-qatzip.c'))
|
||||
|
||||
specific_ss.add(when: 'CONFIG_SYSTEM_ONLY',
|
||||
if_true: files('vfio.c'))
|
||||
system_ss.add(when: 'CONFIG_VFIO',
|
||||
if_true: files('vfio.c'),
|
||||
if_false: files('vfio-stub.c'))
|
||||
|
||||
16
migration/vfio-stub.c
Normal file
16
migration/vfio-stub.c
Normal file
@@ -0,0 +1,16 @@
|
||||
/*
|
||||
* QEMU live migration - stubs for VFIO
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "migration.h"
|
||||
|
||||
void migration_populate_vfio_info(MigrationInfo *info)
|
||||
{
|
||||
}
|
||||
|
||||
void migration_reset_vfio_bytes_transferred(void)
|
||||
{
|
||||
}
|
||||
@@ -8,13 +8,8 @@
|
||||
#include "qemu/osdep.h"
|
||||
#include "qapi/qapi-types-migration.h"
|
||||
#include "migration.h"
|
||||
#include CONFIG_DEVICES
|
||||
|
||||
#ifdef CONFIG_VFIO
|
||||
#include "hw/vfio/vfio-migration.h"
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_VFIO
|
||||
void migration_populate_vfio_info(MigrationInfo *info)
|
||||
{
|
||||
if (vfio_migration_active()) {
|
||||
@@ -27,12 +22,3 @@ void migration_reset_vfio_bytes_transferred(void)
|
||||
{
|
||||
vfio_migration_reset_bytes_transferred();
|
||||
}
|
||||
#else
|
||||
void migration_populate_vfio_info(MigrationInfo *info)
|
||||
{
|
||||
}
|
||||
|
||||
void migration_reset_vfio_bytes_transferred(void)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user