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

[Xen-API] [PATCH 09 of 15] libxl/ocaml: add domain_build/create_info and events to the bindings



# HG changeset patch
# User Ian Campbell <ijc@xxxxxxxxxxxxxx>
# Date 1353432141 0
# Node ID 5173d29f64fa541f6ec0c48481c4957a03f0302c
# Parent  21c5e58956d09437903e1ee1b0588d61a7c28145
libxl/ocaml: add domain_build/create_info and events to the bindings.

We now have enoguh infrastructure in place to do this trivially.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

diff -r 21c5e58956d0 -r 5173d29f64fa tools/ocaml/libs/xl/genwrap.py
--- a/tools/ocaml/libs/xl/genwrap.py    Tue Nov 20 17:22:21 2012 +0000
+++ b/tools/ocaml/libs/xl/genwrap.py    Tue Nov 20 17:22:21 2012 +0000
@@ -19,7 +19,7 @@ builtins = {
     "libxl_mac":            ("int array",              "Mac_val(gc, lg, 
&%(c)s, %(o)s)",    "Val_mac(&%(c)s)"),
     "libxl_hwcap":          ("int32 array",            None,                   
             "Val_hwcap(&%(c)s)"),
     # This is an opaque type
-    "libxl_cpuid_policy_list": ("Cpuid_policy.t",      
"Cpuid_policy_list_val(gc, lg, &%(c)s, %(o)s)",   
"Val_cpuid_policy_list(&%(c)s)"),    
+    "libxl_cpuid_policy_list": ("Cpuid_policy.t",      
"Cpuid_policy_list_val(gc, lg, &%(c)s, %(o)s)",   
"Val_cpuid_policy_list(%(c)s)"),    
     }
 
 DEVICE_FUNCTIONS = [ ("add",            ["t", "domid", "unit"]),
@@ -420,11 +420,8 @@ if __name__ == '__main__':
     # Do not generate these yet.
     blacklist = [
         "cpupoolinfo",
-        "domain_create_info",
-        "domain_build_info",
         "domain_config",
         "vcpuinfo",
-        "event",
         ]
 
     for t in blacklist:
diff -r 21c5e58956d0 -r 5173d29f64fa tools/ocaml/libs/xl/xenlight_stubs.c
--- a/tools/ocaml/libs/xl/xenlight_stubs.c      Tue Nov 20 17:22:21 2012 +0000
+++ b/tools/ocaml/libs/xl/xenlight_stubs.c      Tue Nov 20 17:22:21 2012 +0000
@@ -224,7 +224,7 @@ static int Bitmap_val(caml_gc *gc, struc
        abort(); /* XXX */
 }
 
-static value Val_cpuid_policy_list(libxl_cpuid_policy_list *c_val)
+static value Val_cpuid_policy_list(libxl_cpuid_policy_list c_val)
 {
        CAMLparam0();
        /* An opaque pointer */
@@ -232,12 +232,13 @@ static value Val_cpuid_policy_list(libxl
 }
 
 static int Cpuid_policy_list_val(caml_gc *gc, struct caml_logger *lg,
-                                libxl_cpuid_policy_list **c_val, value v)
+                                libxl_cpuid_policy_list *c_val, value v)
 {
        CAMLparam1(v);
 
        /* An opaque pointer */
-       *c_val = (libxl_cpuid_policy_list*)v;
+       *c_val = (libxl_cpuid_policy_list)v;
+
        CAMLreturn(0);
 }
 

_______________________________________________
Xen-api mailing list
Xen-api@xxxxxxxxxxxxx
http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api


 


Rackspace

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