e5c6318b4d
- Update to libvirt 1.2.5 - Introduce virDomain{Get,Set}Time APIs - Introduce virDomainFSFreeze() and virDomainFSThaw() public API - Many incremental improvements and bug fixes, see http://libvirt.org/news.html - Drop upstream patches: b98bf811-add-paravirt-shutdown-flag.patch, c4fe29f8-use-shutdown-flag.patch, da744120-use-reboot-flag.patch, d6b27d3e-CVE-2014-0179.patch, fd43d1f8-libxl-iface-hostdev.patch, 99f50208-managed-hostdev-iface.patch, 292d3f2d-libselinux-build-fix1.patch, b109c097-libselinux-build-fix2.patch OBS-URL: https://build.opensuse.org/request/show/235993 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libvirt?expand=0&rev=381
67 lines
1.9 KiB
Diff
67 lines
1.9 KiB
Diff
Index: libvirt-1.2.5/src/lxc/lxc_container.c
|
|
===================================================================
|
|
--- libvirt-1.2.5.orig/src/lxc/lxc_container.c
|
|
+++ libvirt-1.2.5/src/lxc/lxc_container.c
|
|
@@ -164,12 +164,19 @@ int lxcContainerHasReboot(void)
|
|
VIR_FREE(buf);
|
|
cmd = v ? LINUX_REBOOT_CMD_CAD_ON : LINUX_REBOOT_CMD_CAD_OFF;
|
|
|
|
+#ifdef __ia64__
|
|
+ stacksize *= 2;
|
|
+#endif
|
|
if (VIR_ALLOC_N(stack, stacksize) < 0)
|
|
return -1;
|
|
|
|
childStack = stack + stacksize;
|
|
|
|
+#ifdef __ia64__
|
|
+ cpid = __clone2(lxcContainerRebootChild, childStack, stacksize, flags, &cmd);
|
|
+#else
|
|
cpid = clone(lxcContainerRebootChild, childStack, flags, &cmd);
|
|
+#endif
|
|
VIR_FREE(stack);
|
|
if (cpid < 0) {
|
|
virReportSystemError(errno, "%s",
|
|
@@ -2007,6 +2014,9 @@ int lxcContainerStart(virDomainDefPtr de
|
|
.handshakefd = handshakefd
|
|
};
|
|
|
|
+#ifdef __ia64__
|
|
+ stacksize *= 2;
|
|
+#endif
|
|
/* allocate a stack for the container */
|
|
if (VIR_ALLOC_N(stack, stacksize) < 0)
|
|
return -1;
|
|
@@ -2032,7 +2042,11 @@ int lxcContainerStart(virDomainDefPtr de
|
|
cflags |= CLONE_NEWNET;
|
|
}
|
|
|
|
+#ifdef __ia64__
|
|
+ pid = __clone2(lxcContainerChild, stacktop, stacksize, cflags, &args);
|
|
+#else
|
|
pid = clone(lxcContainerChild, stacktop, cflags, &args);
|
|
+#endif
|
|
VIR_FREE(stack);
|
|
VIR_DEBUG("clone() completed, new container PID is %d", pid);
|
|
|
|
@@ -2066,12 +2080,19 @@ int lxcContainerAvailable(int features)
|
|
if (features & LXC_CONTAINER_FEATURE_NET)
|
|
flags |= CLONE_NEWNET;
|
|
|
|
+#ifdef __ia64__
|
|
+ stacksize *= 2;
|
|
+#endif
|
|
if (VIR_ALLOC_N(stack, stacksize) < 0)
|
|
return -1;
|
|
|
|
childStack = stack + stacksize;
|
|
|
|
+#ifdef __ia64__
|
|
+ cpid = __clone2(lxcContainerDummyChild, childStack, stacksize, flags, NULL);
|
|
+#else
|
|
cpid = clone(lxcContainerDummyChild, childStack, flags, NULL);
|
|
+#endif
|
|
VIR_FREE(stack);
|
|
if (cpid < 0) {
|
|
char ebuf[1024] ATTRIBUTE_UNUSED;
|