mirror of
https://github.com/libvirt/libvirt.git
synced 2026-08-11 13:34:45 -05:00
virCaps: get rid of defaultConsoleTargetType callback
This patch refactors various places to allow removing of the defaultConsoleTargetType callback from the virCaps structure. A new console character device target type is introduced - VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_NONE - to mark that no type was specified in the XML. This type is at the end converted to the standard VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_SERIAL. Other types that are different from this default have to be processed separately in the device post parse callback.
This commit is contained in:
@@ -15,11 +15,6 @@ static virCapsPtr caps;
|
||||
static virVMXContext ctx;
|
||||
static virDomainXMLOptionPtr xmlopt;
|
||||
|
||||
static int testDefaultConsoleType(const char *ostype ATTRIBUTE_UNUSED,
|
||||
virArch arch ATTRIBUTE_UNUSED)
|
||||
{
|
||||
return VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_SERIAL;
|
||||
}
|
||||
|
||||
static void
|
||||
testCapsInit(void)
|
||||
@@ -32,8 +27,6 @@ testCapsInit(void)
|
||||
return;
|
||||
}
|
||||
|
||||
caps->defaultConsoleTargetType = testDefaultConsoleType;
|
||||
|
||||
virCapabilitiesAddHostMigrateTransport(caps, "esx");
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user