mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-09-13 11:15:08 +00:00
adds xen and hvm guest types to test driver capabilities
* src/test.c: patch from Cole Robinson adding xen and hvm guest types to the test driver's capabilities. Daniel
This commit is contained in:
parent
2579443e21
commit
801a8f2e7b
@ -1,3 +1,8 @@
|
|||||||
|
Tue Apr 8 11:24:28 CEST 2008 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
|
* src/test.c: patch from Cole Robinson adding xen and hvm guest types
|
||||||
|
to the test driver's capabilities.
|
||||||
|
|
||||||
Tue Apr 8 10:19:01 CEST 2008 Daniel Veillard <daniel@veillard.com>
|
Tue Apr 8 10:19:01 CEST 2008 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
* python/generator.py: fix an infinite loop bug
|
* python/generator.py: fix an infinite loop bug
|
||||||
|
@ -1006,6 +1006,7 @@ static char *testGetCapabilities (virConnectPtr conn)
|
|||||||
virCapsPtr caps;
|
virCapsPtr caps;
|
||||||
virCapsGuestPtr guest;
|
virCapsGuestPtr guest;
|
||||||
char *xml;
|
char *xml;
|
||||||
|
const char *guest_types[] = { "hvm", "xen" };
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
GET_CONNECTION(conn, -1);
|
GET_CONNECTION(conn, -1);
|
||||||
@ -1024,8 +1025,10 @@ static char *testGetCapabilities (virConnectPtr conn)
|
|||||||
goto no_memory;
|
goto no_memory;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (i = 0; i < (sizeof(guest_types)/sizeof(guest_types[0])); ++i) {
|
||||||
|
|
||||||
if ((guest = virCapabilitiesAddGuest(caps,
|
if ((guest = virCapabilitiesAddGuest(caps,
|
||||||
"linux",
|
guest_types[i],
|
||||||
TEST_MODEL,
|
TEST_MODEL,
|
||||||
TEST_MODEL_WORDSIZE,
|
TEST_MODEL_WORDSIZE,
|
||||||
NULL,
|
NULL,
|
||||||
@ -1042,11 +1045,11 @@ static char *testGetCapabilities (virConnectPtr conn)
|
|||||||
NULL) == NULL)
|
NULL) == NULL)
|
||||||
goto no_memory;
|
goto no_memory;
|
||||||
|
|
||||||
|
|
||||||
if (virCapabilitiesAddGuestFeature(guest, "pae", 1, 1) == NULL)
|
if (virCapabilitiesAddGuestFeature(guest, "pae", 1, 1) == NULL)
|
||||||
goto no_memory;
|
goto no_memory;
|
||||||
if (virCapabilitiesAddGuestFeature(guest ,"nonpae", 1, 1) == NULL)
|
if (virCapabilitiesAddGuestFeature(guest ,"nonpae", 1, 1) == NULL)
|
||||||
goto no_memory;
|
goto no_memory;
|
||||||
|
}
|
||||||
|
|
||||||
if ((xml = virCapabilitiesFormatXML(caps)) == NULL)
|
if ((xml = virCapabilitiesFormatXML(caps)) == NULL)
|
||||||
goto no_memory;
|
goto no_memory;
|
||||||
|
Loading…
Reference in New Issue
Block a user