qapi/vfio: Rename VfioMigrationState to Qapi*, and drop prefix

QAPI's 'prefix' feature can make the connection between enumeration
type and its constants less than obvious.  It's best used with
restraint.

VfioMigrationState has a 'prefix' that overrides the generated
enumeration constants' prefix to QAPI_VFIO_MIGRATION_STATE.

We could simply drop 'prefix', but then the enumeration constants
would look as if they came from kernel header linux/vfio.h.

Rename the type to QapiVfioMigrationState instead, so that 'prefix' is
not needed.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20240904111836.3273842-20-armbru@redhat.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
This commit is contained in:
Markus Armbruster 2024-09-04 13:18:36 +02:00
parent b1019999e8
commit 64f5e9db77
2 changed files with 5 additions and 6 deletions

View file

@ -81,7 +81,7 @@ static const char *mig_state_to_str(enum vfio_device_mig_state state)
}
}
static VfioMigrationState
static QapiVfioMigrationState
mig_state_to_qapi_state(enum vfio_device_mig_state state)
{
switch (state) {