|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] minios: add CONFIG_XC conditional
# HG changeset patch
# User Matthew Fioravante <matthew.fioravante@xxxxxxxxxx>
# Date 1349703391 -3600
# Node ID 865626fc700457613e9049d9c19bf25b43bfa019
# Parent 42ca0ed31aa68293ba9b13e6a3ce9b4c3da97deb
minios: add CONFIG_XC conditional
This patch adds a CONFIG_XC option to mini-os, to allow conditional
support for libxc for mini-os domains.
Signed-off-by: Matthew Fioravante <matthew.fioravante@xxxxxxxxxx>
Acked-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxxx>
Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
diff -r 42ca0ed31aa6 -r 865626fc7004 extras/mini-os/Makefile
--- a/extras/mini-os/Makefile Mon Oct 08 14:36:30 2012 +0100
+++ b/extras/mini-os/Makefile Mon Oct 08 14:36:31 2012 +0100
@@ -27,6 +27,7 @@ CONFIG_FBFRONT ?= y
CONFIG_KBDFRONT ?= y
CONFIG_CONSFRONT ?= y
CONFIG_XENBUS ?= y
+CONFIG_XC ?=y
CONFIG_LWIP ?= $(lwip)
# Export config items as compiler directives
@@ -144,7 +145,9 @@ endif
OBJS := $(filter-out $(OBJ_DIR)/lwip%.o $(LWO), $(OBJS))
ifeq ($(libc),y)
+ifeq ($(CONFIG_XC),y)
APP_LDLIBS += -L$(XEN_ROOT)/stubdom/libxc-$(XEN_TARGET_ARCH) -whole-archive
-lxenguest -lxenctrl -no-whole-archive
+endif
APP_LDLIBS += -lpci
APP_LDLIBS += -lz
APP_LDLIBS += -lm
diff -r 42ca0ed31aa6 -r 865626fc7004 extras/mini-os/lib/sys.c
--- a/extras/mini-os/lib/sys.c Mon Oct 08 14:36:30 2012 +0100
+++ b/extras/mini-os/lib/sys.c Mon Oct 08 14:36:31 2012 +0100
@@ -359,6 +359,7 @@ int close(int fd)
return res;
}
#endif
+#ifdef CONFIG_XC
case FTYPE_XC:
minios_interface_close_fd(fd);
return 0;
@@ -368,6 +369,7 @@ int close(int fd)
case FTYPE_GNTMAP:
minios_gnttab_close_fd(fd);
return 0;
+#endif
#ifdef CONFIG_NETFRONT
case FTYPE_TAP:
shutdown_netfront(files[fd].tap.dev);
@@ -1153,10 +1155,13 @@ void *mmap(void *start, size_t length, i
if (fd == -1)
return map_zero(n, 1);
+#ifdef CONFIG_XC
else if (files[fd].type == FTYPE_XC) {
unsigned long zero = 0;
return map_frames_ex(&zero, n, 0, 0, 1, DOMID_SELF, NULL, 0);
- } else if (files[fd].type == FTYPE_MEM) {
+ }
+#endif
+ else if (files[fd].type == FTYPE_MEM) {
unsigned long first_mfn = offset >> PAGE_SHIFT;
return map_frames_ex(&first_mfn, n, 0, 1, 1, DOMID_IO, NULL,
_PAGE_PRESENT|_PAGE_RW);
} else ASSERT(0);
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |