diff options
Diffstat (limited to 'tools/ocaml/libs')
-rw-r--r-- | tools/ocaml/libs/xl/genwrap.py | 5 | ||||
-rw-r--r-- | tools/ocaml/libs/xl/xenlight_stubs.c | 14 |
2 files changed, 11 insertions, 8 deletions
diff --git a/tools/ocaml/libs/xl/genwrap.py b/tools/ocaml/libs/xl/genwrap.py index c73d40fb63..f9e2e81e95 100644 --- a/tools/ocaml/libs/xl/genwrap.py +++ b/tools/ocaml/libs/xl/genwrap.py @@ -22,10 +22,7 @@ DEVICE_FUNCTIONS = [ ("add", ["t", "domid", "unit"]), ] functions = { # ( name , [type1,type2,....] ) - "device_vfb": [ ("add", ["t", "domid", "unit"]), - ("clean_shutdown", ["domid", "unit"]), - ("hard_shutdown", ["domid", "unit"]), - ], + "device_vfb": DEVICE_FUNCTIONS, "device_vkb": DEVICE_FUNCTIONS, "device_disk": DEVICE_FUNCTIONS, "device_nic": DEVICE_FUNCTIONS, diff --git a/tools/ocaml/libs/xl/xenlight_stubs.c b/tools/ocaml/libs/xl/xenlight_stubs.c index eea91345d4..f7790b7dd0 100644 --- a/tools/ocaml/libs/xl/xenlight_stubs.c +++ b/tools/ocaml/libs/xl/xenlight_stubs.c @@ -360,14 +360,17 @@ value stub_xl_device_vfb_add(value info, value domid) CAMLreturn(Val_unit); } -value stub_xl_device_vfb_clean_shutdown(value domid) +value stub_xl_device_vfb_remove(value info, value domid) { CAMLparam1(domid); + libxl_device_vfb c_info; int ret; INIT_STRUCT(); + device_vfb_val(&gc, &lg, &c_info, info); + INIT_CTX(); - ret = libxl_device_vfb_clean_shutdown(ctx, Int_val(domid)); + ret = libxl_device_vfb_remove(ctx, Int_val(domid), &c_info); if (ret != 0) failwith_xl("vfb_clean_shutdown", &lg); FREE_CTX(); @@ -375,14 +378,17 @@ value stub_xl_device_vfb_clean_shutdown(value domid) CAMLreturn(Val_unit); } -value stub_xl_device_vfb_hard_shutdown(value domid) +value stub_xl_device_vfb_destroy(value info, value domid) { CAMLparam1(domid); + libxl_device_vfb c_info; int ret; INIT_STRUCT(); + device_vfb_val(&gc, &lg, &c_info, info); + INIT_CTX(); - ret = libxl_device_vfb_hard_shutdown(ctx, Int_val(domid)); + ret = libxl_device_vfb_destroy(ctx, Int_val(domid), &c_info); if (ret != 0) failwith_xl("vfb_hard_shutdown", &lg); FREE_CTX(); |