ChangeSet 1.1719, 2005/06/18 01:49:11+01:00, iap10@xxxxxxxxxxxxxxxxxxxxx
manual merge
b/tools/libxc/xc.h | 231 ++++++++++++++++++------
b/tools/python/xen/xend/server/SrvConsole.py | 30 +--
b/tools/python/xen/xend/server/SrvConsoleDir.py | 26 +-
b/tools/python/xen/xend/server/SrvDmesg.py | 24 +-
b/tools/python/xen/xend/server/SrvDomainDir.py | 51 ++---
b/tools/python/xen/xend/server/SrvNode.py | 44 +---
b/tools/python/xen/xend/server/SrvVnetDir.py | 26 +-
b/tools/python/xen/xend/server/SrvXendLog.py | 9
tools/python/xen/xend/server/SrvBase.py | 184 -------------------
tools/python/xen/xend/server/SrvDir.py | 111 -----------
10 files changed, 266 insertions(+), 470 deletions(-)
diff -Nru a/tools/libxc/xc.h b/tools/libxc/xc.h
--- a/tools/libxc/xc.h 2005-06-21 04:04:08 -04:00
+++ b/tools/libxc/xc.h 2005-06-21 04:04:08 -04:00
@@ -10,6 +10,7 @@
#define __XC_H__
#include <stdint.h>
+
typedef uint8_t u8;
typedef uint16_t u16;
typedef uint32_t u32;
@@ -19,15 +20,31 @@
typedef int32_t s32;
typedef int64_t s64;
+#include <sys/ptrace.h>
#include <xen/xen.h>
#include <xen/dom0_ops.h>
#include <xen/event_channel.h>
#include <xen/sched_ctl.h>
-#include <xen/io/domain_controller.h>
-/*\
+/*
+ * DEFINITIONS FOR CPU BARRIERS
+ */
+
+#if defined(__i386__)
+#define mb() __asm__ __volatile__ ( "lock; addl $0,0(%%esp)" : : : "memory" )
+#define rmb() __asm__ __volatile__ ( "lock; addl $0,0(%%esp)" : : : "memory" )
+#define wmb() __asm__ __volatile__ ( "" : : : "memory")
+#elif defined(__x86_64__)
+#define mb() __asm__ __volatile__ ( "mfence" : : : "memory")
+#define rmb() __asm__ __volatile__ ( "lfence" : : : "memory")
+#define wmb() __asm__ __volatile__ ( "" : : : "memory")
+#else
+#error "Define barriers"
+#endif
+
+/*
* INITIALIZATION FUNCTIONS
-\*/
+ */
/**
* This function opens a handle to the hypervisor interface. This function can
@@ -55,13 +72,44 @@
*/
int xc_interface_close(int xc_handle);
-/*\
+/*
+ * DOMAIN DEBUGGING FUNCTIONS
+ */
+
+typedef struct xc_core_header {
+ unsigned int xch_magic;
+ unsigned int xch_nr_vcpus;
+ unsigned int xch_nr_pages;
+ unsigned int xch_ctxt_offset;
+ unsigned int xch_index_offset;
+ unsigned int xch_pages_offset;
+} xc_core_header_t;
+
+
+long xc_ptrace(enum __ptrace_request request,
+ u32 domid,
+ long addr,
+ long data);
+
+long xc_ptrace_core(enum __ptrace_request request,
+ u32 domid,
+ long addr,
+ long data);
+
+int xc_waitdomain(int domain,
+ int *status,
+ int options);
+
+int xc_waitdomain_core(int domain,
+ int *status,
+ int options);
+
+/*
* DOMAIN MANAGEMENT FUNCTIONS
-\*/
+ */
typedef struct {
u32 domid;
- unsigned int cpu;
unsigned int dying:1, crashed:1, shutdown:1,
paused:1, blocked:1, running:1;
unsigned int shutdown_reason; /* only meaningful if shutdown==1 */
@@ -69,15 +117,21 @@
unsigned long shared_info_frame;
u64 cpu_time;
unsigned long max_memkb;
+ unsigned int vcpus;
+ s32 vcpu_to_cpu[MAX_VIRT_CPUS];
+ cpumap_t cpumap[MAX_VIRT_CPUS];
} xc_dominfo_t;
typedef dom0_getdomaininfo_t xc_domaininfo_t;
int xc_domain_create(int xc_handle,
- unsigned int mem_kb,
- int cpu,
- float cpu_weight,
u32 *pdomid);
+
+int xc_domain_dumpcore(int xc_handle,
+ u32 domid,
+ const char *corename);
+
+
/**
* This function pauses a domain. A paused domain still exists in memory
* however it does not receive any timeslices from the hypervisor.
@@ -112,7 +166,8 @@
u32 domid);
int xc_domain_pincpu(int xc_handle,
u32 domid,
- int cpu);
+ int vcpu,
+ cpumap_t *cpumap);
/**
* This function will return information about one or more domains. It is
* designed to iterate over the list of domains. If a single domain is
@@ -144,15 +199,17 @@
* domain
* @return 0 on success, -1 on failure
*/
-int xc_domain_getfullinfo(int xc_handle,
- u32 domid,
- xc_domaininfo_t *info,
- full_execution_context_t *ctxt);
+int xc_domain_get_vcpu_context(int xc_handle,
+ u32 domid,
+ u32 vcpu,
+ vcpu_guest_context_t *ctxt);
+
int xc_domain_setcpuweight(int xc_handle,
u32 domid,
float weight);
long long xc_domain_get_cpu_usage(int xc_handle,
- domid_t domid);
+ domid_t domid,
+ int vcpu);
typedef dom0_shadow_control_stats_t xc_shadow_control_stats_t;
@@ -172,26 +229,25 @@
struct XcIOContext;
/**
- * This function will save a domain running Linux to an IO context. This
- * IO context is currently a private interface making this function difficult
- * to call. It's interface will likely change in the future.
+ * This function will save a domain running Linux.
*
* @parm xc_handle a handle to an open hypervisor interface
- * @parm ioctxt the IO context to save a domain to
+ * @parm fd the file descriptor to save a domain to
+ * @parm dom the id of the domain
* @return 0 on success, -1 on failure
*/
-int xc_linux_save(int xc_handle, struct XcIOContext *ioctxt);
+int xc_linux_save(int xc_handle, int fd, u32 dom);
/**
- * This function will restore a saved domain running Linux to an IO context.
- * Like xc_linux_save(), this function uses a parameter who's structure is
- * privately defined. It's interface will also likely change.
+ * This function will restore a saved domain running Linux.
*
* @parm xc_handle a handle to an open hypervisor interface
- * @parm ioctxt the IO context to restore a domain from
+ * @parm fd the file descriptor to restore a domain from
+ * @parm dom the id of the domain
+ * @parm nr_pfns the number of pages
* @return 0 on success, -1 on failure
*/
-int xc_linux_restore(int xc_handle, struct XcIOContext *ioctxt);
+int xc_linux_restore(int xc_handle, int io_fd, u32 dom, unsigned long nr_pfns);
int xc_linux_build(int xc_handle,
u32 domid,
@@ -199,15 +255,29 @@
const char *ramdisk_name,
const char *cmdline,
unsigned int control_evtchn,
- unsigned long flags);
+ unsigned long flags,
+ unsigned int vcpus,
+ unsigned int store_evtchn,
+ unsigned long *store_mfn);
int
xc_plan9_build (int xc_handle,
u32 domid,
const char *image_name,
const char *cmdline,
- unsigned int control_evtchn,
- unsigned long flags);
+ unsigned int control_evtchn,
+ unsigned long flags);
+
+struct mem_map;
+int xc_vmx_build(int xc_handle,
+ u32 domid,
+ int memsize,
+ const char *image_name,
+ struct mem_map *memmap,
+ const char *ramdisk_name,
+ const char *cmdline,
+ unsigned int control_evtchn,
+ unsigned long flags);
int xc_bvtsched_global_set(int xc_handle,
unsigned long ctx_allow);
@@ -231,25 +301,19 @@
long long *warpl,
long long *warpu);
-int xc_atropos_domain_set(int xc_handle,
+int xc_sedf_domain_set(int xc_handle,
u32 domid,
- u64 period, u64 slice, u64 latency,
- int xtratime);
+ u64 period, u64 slice, u64 latency, u16 extratime,
u16 weight);
-int xc_atropos_domain_get(int xc_handle,
+int xc_sedf_domain_get(int xc_handle,
u32 domid,
- u64* period, u64 *slice, u64 *latency,
- int *xtratime);
-
-int xc_rrobin_global_set(int xc_handle, u64 slice);
-
-int xc_rrobin_global_get(int xc_handle, u64 *slice);
+ u64* period, u64 *slice, u64 *latency, u16
*extratime, u16* weight);
typedef evtchn_status_t xc_evtchn_status_t;
-/*\
+/*
* EVENT CHANNEL FUNCTIONS
-\*/
+ */
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|