summary refs log tree commit diff stats
path: root/hw/vfio/platform.c
diff options
context:
space:
mode:
authorSteve Sistare <steven.sistare@oracle.com>2025-07-02 14:58:46 -0700
committerCédric Le Goater <clg@redhat.com>2025-07-03 13:42:28 +0200
commitb9b389b9e0f08b207786d501b790dab9cb2c09de (patch)
treed887bb256eda00756a32dbad3f09032aa2c7a7e4 /hw/vfio/platform.c
parentfb32965b6dd8a001815593642a5146fbd2e85651 (diff)
downloadfocaccia-qemu-b9b389b9e0f08b207786d501b790dab9cb2c09de.tar.gz
focaccia-qemu-b9b389b9e0f08b207786d501b790dab9cb2c09de.zip
vfio/iommufd: invariant device name
cpr-transfer will use the device name as a key to find the value
of the device descriptor in new QEMU.  However, if the descriptor
number is specified by a command-line fd parameter, then
vfio_device_get_name creates a name that includes the fd number.
This causes a chicken-and-egg problem: new QEMU must know the fd
number to construct a name to find the fd number.

To fix, create an invariant name based on the id command-line parameter,
if id is defined.  The user will need to provide such an id to use CPR.

Signed-off-by: Steve Sistare <steven.sistare@oracle.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Reviewed-by: Zhenzhong Duan <zhenzhong.duan@intel.com>
Link: https://lore.kernel.org/qemu-devel/1751493538-202042-10-git-send-email-steven.sistare@oracle.com
Signed-off-by: Cédric Le Goater <clg@redhat.com>
Diffstat (limited to 'hw/vfio/platform.c')
0 files changed, 0 insertions, 0 deletions