[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [RFC][PATCH 03/13] Kemari: change parameter type of xc_{set, get}_hvm_param



This is an updated version of the following patch.  Modifies files
which use xc_{set,get}_hvm_param.

http://lists.xensource.com/archives/html/xen-devel/2009-03/msg00370.html

Signed-off-by: Yoshisato Yanagisawa <yanagisawa.yoshisato@xxxxxxxxxxxxx>
Signed-off-by: Yoshi Tamura <tamura.yoshiaki@xxxxxxxxxxxxx>
---
 tools/libxc/xc_cpuid_x86.c        |    2 +-
 tools/libxc/xc_domain.c           |    4 ++--
 tools/libxc/xc_domain_save.c      |   10 +++++-----
 tools/libxc/xc_resume.c           |    2 +-
 tools/python/xen/lowlevel/xc/xc.c |    2 +-
 tools/xcutils/xc_save.c           |    2 +-
 6 files changed, 11 insertions(+), 11 deletions(-)

diff -r b249f3e979a5 -r cf6a910e3663 tools/libxc/xc_domain.c
--- a/tools/libxc/xc_domain.c   Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/libxc/xc_domain.c   Wed Mar 11 18:03:47 2009 +0900
@@ -792,7 +792,7 @@
     return do_domctl(xc_handle, &domctl);
 }

-int xc_set_hvm_param(int handle, domid_t dom, int param, unsigned long value)
+int xc_set_hvm_param(int handle, domid_t dom, int param, uint64_t value)
 {
     DECLARE_HYPERCALL;
     xen_hvm_param_t arg;
@@ -811,7 +811,7 @@
     return rc;
 }

-int xc_get_hvm_param(int handle, domid_t dom, int param, unsigned long *value)
+int xc_get_hvm_param(int handle, domid_t dom, int param, uint64_t *value)
 {
     DECLARE_HYPERCALL;
     xen_hvm_param_t arg;
diff -r b249f3e979a5 -r cf6a910e3663 tools/libxc/xc_cpuid_x86.c
--- a/tools/libxc/xc_cpuid_x86.c        Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/libxc/xc_cpuid_x86.c        Wed Mar 11 18:03:47 2009 +0900
@@ -167,7 +167,7 @@
     int xc, domid_t domid, const unsigned int *input, unsigned int *regs)
 {
     char brand[13];
-    unsigned long pae;
+    uint64_t pae;
     int is_pae;

     xc_get_hvm_param(xc, domid, HVM_PARAM_PAE_ENABLED, &pae);
diff -r b249f3e979a5 -r cf6a910e3663 tools/xcutils/xc_save.c
--- a/tools/xcutils/xc_save.c   Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/xcutils/xc_save.c   Wed Mar 11 18:03:47 2009 +0900
@@ -164,7 +164,7 @@

 static int suspend(void)
 {
-    unsigned long sx_state = 0;
+    uint64_t sx_state = 0;

     /* Cannot notify guest to shut itself down if it's in ACPI sleep state. */
     if (si.flags & XCFLAGS_HVM)
diff -r b249f3e979a5 -r cf6a910e3663 tools/libxc/xc_domain_save.c
--- a/tools/libxc/xc_domain_save.c      Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/libxc/xc_domain_save.c      Wed Mar 11 18:03:47 2009 +0900
@@ -1395,7 +1395,7 @@

         chunk.id = -3;
         xc_get_hvm_param(xc_handle, dom, HVM_PARAM_IDENT_PT,
-                         (unsigned long *)&chunk.data);
+                         &chunk.data);

         if ( (chunk.data != 0) &&
              write_exact(io_fd, &chunk, sizeof(chunk)) )
@@ -1406,7 +1406,7 @@

         chunk.id = -4;
         xc_get_hvm_param(xc_handle, dom, HVM_PARAM_VM86_TSS,
-                         (unsigned long *)&chunk.data);
+                         &chunk.data);

         if ( (chunk.data != 0) &&
              write_exact(io_fd, &chunk, sizeof(chunk)) )
@@ -1431,11 +1431,11 @@
         /* Save magic-page locations. */
         memset(magic_pfns, 0, sizeof(magic_pfns));
         xc_get_hvm_param(xc_handle, dom, HVM_PARAM_IOREQ_PFN,
-                         (unsigned long *)&magic_pfns[0]);
+                         &magic_pfns[0]);
         xc_get_hvm_param(xc_handle, dom, HVM_PARAM_BUFIOREQ_PFN,
-                         (unsigned long *)&magic_pfns[1]);
+                         &magic_pfns[1]);
         xc_get_hvm_param(xc_handle, dom, HVM_PARAM_STORE_PFN,
-                         (unsigned long *)&magic_pfns[2]);
+                         &magic_pfns[2]);
         if ( write_exact(io_fd, magic_pfns, sizeof(magic_pfns)) )
         {
             PERROR("Error when writing to state file (7)");
diff -r b249f3e979a5 -r cf6a910e3663 tools/libxc/xc_resume.c
--- a/tools/libxc/xc_resume.c   Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/libxc/xc_resume.c   Wed Mar 11 18:03:47 2009 +0900
@@ -27,7 +27,7 @@
     /* HVM guests without PV drivers do not have a return code to modify. */
     if ( info.hvm )
     {
-        unsigned long irq = 0;
+        uint64_t irq = 0;
         xc_get_hvm_param(xc_handle, domid, HVM_PARAM_CALLBACK_IRQ, &irq);
         if ( !irq )
             return 0;
diff -r b249f3e979a5 -r cf6a910e3663 tools/python/xen/lowlevel/xc/xc.c
--- a/tools/python/xen/lowlevel/xc/xc.c Mon Mar 09 10:32:24 2009 +0000
+++ b/tools/python/xen/lowlevel/xc/xc.c Wed Mar 11 18:03:47 2009 +0900
@@ -490,7 +490,7 @@
 {
     uint32_t dom;
     int param;
-    unsigned long value;
+    uint64_t value;

     static char *kwd_list[] = { "domid", "param", NULL };
     if ( !PyArg_ParseTupleAndKeywords(args, kwds, "ii", kwd_list,



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.