# HG changeset patch
# User awilliam@xxxxxxxxxxxx
# Date 1173372625 25200
# Node ID 9fbaf07d3f670b96d6a1653a002f5ca3db895fc8
# Parent 4e367aa898956466747417bff637a681b8b58202
[IA64] Add HYPERVISOR_vcpu_op
For support of steal time accounting, only supports
VCPUOP_register_runstate_memory_area right now.
Signed-off-by: Atsushi SAKAI <sakaia@xxxxxxxxxxxxxx>
---
linux-2.6-xen-sparse/arch/ia64/xen/xcom_hcall.c | 18 +++++++++++++++++
linux-2.6-xen-sparse/include/asm-ia64/hypercall.h | 7 ++++++
linux-2.6-xen-sparse/include/asm-ia64/xen/xcom_hcall.h | 2 +
3 files changed, 27 insertions(+)
diff -r 4e367aa89895 -r 9fbaf07d3f67
linux-2.6-xen-sparse/arch/ia64/xen/xcom_hcall.c
--- a/linux-2.6-xen-sparse/arch/ia64/xen/xcom_hcall.c Wed Mar 07 13:16:07
2007 -0700
+++ b/linux-2.6-xen-sparse/arch/ia64/xen/xcom_hcall.c Thu Mar 08 09:50:25
2007 -0700
@@ -33,6 +33,7 @@
#include <xen/interface/acm_ops.h>
#include <xen/interface/hvm/params.h>
#include <xen/interface/xenoprof.h>
+#include <xen/interface/vcpu.h>
#include <asm/hypercall.h>
#include <asm/page.h>
#include <asm/uaccess.h>
@@ -363,3 +364,20 @@ xencomm_hypercall_perfmon_op(unsigned lo
xencomm_create_inline(arg),
count);
}
+
+long
+xencomm_hypercall_vcpu_op(int cmd, int cpu, void *arg)
+{
+ switch (cmd) {
+ case VCPUOP_register_runstate_memory_area:
+ xencommize_memory_reservation((xen_memory_reservation_t *)arg);
+ break;
+
+ default:
+ printk("%s: unknown vcpu op %d\n", __func__, cmd);
+ return -ENOSYS;
+ }
+
+ return xencomm_arch_hypercall_vcpu_op(cmd, cpu,
+ xencomm_create_inline(arg));
+}
diff -r 4e367aa89895 -r 9fbaf07d3f67
linux-2.6-xen-sparse/include/asm-ia64/hypercall.h
--- a/linux-2.6-xen-sparse/include/asm-ia64/hypercall.h Wed Mar 07 13:16:07
2007 -0700
+++ b/linux-2.6-xen-sparse/include/asm-ia64/hypercall.h Thu Mar 08 09:50:25
2007 -0700
@@ -203,6 +203,12 @@ xencomm_arch_hypercall_hvm_op(int cmd, v
xencomm_arch_hypercall_hvm_op(int cmd, void *arg)
{
return _hypercall2(unsigned long, hvm_op, cmd, arg);
+}
+
+static inline long
+xencomm_arch_hypercall_vcpu_op(int cmd, int cpu, void *arg)
+{
+ return _hypercall3(long, vcpu_op, cmd, cpu, arg);
}
static inline int
@@ -405,5 +411,6 @@ xencomm_arch_hypercall_perfmon_op(unsign
#endif
#define HYPERVISOR_suspend xencomm_hypercall_suspend
+#define HYPERVISOR_vcpu_op xencomm_hypercall_vcpu_op
#endif /* __HYPERCALL_H__ */
diff -r 4e367aa89895 -r 9fbaf07d3f67
linux-2.6-xen-sparse/include/asm-ia64/xen/xcom_hcall.h
--- a/linux-2.6-xen-sparse/include/asm-ia64/xen/xcom_hcall.h Wed Mar 07
13:16:07 2007 -0700
+++ b/linux-2.6-xen-sparse/include/asm-ia64/xen/xcom_hcall.h Thu Mar 08
09:50:25 2007 -0700
@@ -51,6 +51,8 @@ extern int xencomm_hypercall_perfmon_op(
extern int xencomm_hypercall_perfmon_op(unsigned long cmd, void* arg,
unsigned long count);
+extern long xencomm_hypercall_vcpu_op(int cmd, int cpu, void *arg);
+
/* Using mini xencomm. */
extern int xencomm_mini_hypercall_console_io(int cmd, int count, char *str);
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|