diff options
author | Ian Campbell <ian.campbell@citrix.com> | 2011-04-20 17:13:07 +0100 |
---|---|---|
committer | Ian Campbell <ian.campbell@citrix.com> | 2011-04-20 17:13:07 +0100 |
commit | 2510e0239b70fe920d33a49b4521f059f9a33709 (patch) | |
tree | 226c1549647bfd0762f6306cc5d53258a29d95f5 /tools/ocaml | |
parent | 9740fd134867687f5955bf09daf30d498962b221 (diff) | |
download | xen-2510e0239b70fe920d33a49b4521f059f9a33709.tar.gz xen-2510e0239b70fe920d33a49b4521f059f9a33709.tar.bz2 xen-2510e0239b70fe920d33a49b4521f059f9a33709.zip |
tools: ocaml: reorder xl bindings type and function definitions to match IDL
Reduces the churn when comparing the before and after auto-generation
versions of the patch. (in practice the ocaml pre-autogeneration
bindings are so out of date that there isn't all that much benefit to
this though...)
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
Diffstat (limited to 'tools/ocaml')
-rw-r--r-- | tools/ocaml/libs/xl/xl.ml | 212 | ||||
-rw-r--r-- | tools/ocaml/libs/xl/xl.mli | 212 |
2 files changed, 212 insertions, 212 deletions
diff --git a/tools/ocaml/libs/xl/xl.ml b/tools/ocaml/libs/xl/xl.ml index 4bd3f8b20c..b83053b906 100644 --- a/tools/ocaml/libs/xl/xl.ml +++ b/tools/ocaml/libs/xl/xl.ml @@ -15,6 +15,28 @@ exception Error of string +type domid = int + +type console_type = + | CONSOLETYPE_XENCONSOLED + | CONSOLETYPE_IOEMU + +type disk_phystype = + | PHYSTYPE_QCOW + | PHYSTYPE_QCOW2 + | PHYSTYPE_VHD + | PHYSTYPE_AIO + | PHYSTYPE_FILE + | PHYSTYPE_PHY + +type nic_type = + | NICTYPE_IOEMU + | NICTYPE_VIF + +type button = + | Button_Power + | Button_Sleep + module Domain_create_info = struct type t = { @@ -31,54 +53,49 @@ module Domain_create_info = struct } end -module Domain_build_info = struct - module Hvm = struct - type t = - { - pae : bool; - apic : bool; - acpi : bool; - nx : bool; - viridian : bool; - timeoffset : string; - timer_mode : int; - hpet : int; - vpt_align : int; - } - end - - module Pv = struct - type t = - { - slack_memkb : int64; - cmdline : string; - ramdisk : string; - features : string; - } - end +module Device_vfb = struct + type t = + { + backend_domid : domid; + devid : int; + vnc : bool; + vnclisten : string; + vncpasswd : string; + vncdisplay : int; + vncunused : bool; + keymap : string; + sdl : bool; + opengl : bool; + display : string; + xauthority : string; + } + external add : t -> domid -> unit = "stub_xl_device_vfb_add" + external clean_shutdown : domid -> unit = "stub_xl_device_vfb_clean_shutdown" + external hard_shutdown : domid -> unit = "stub_xl_device_vfb_hard_shutdown" +end +module Device_vkb = struct type t = { - max_vcpus : int; - cur_vcpus : int; - max_memkb : int64; - target_memkb : int64; - video_memkb : int64; - shadow_memkb : int64; - kernel : string; - u : [ `HVM of Hvm.t | `PV of Pv.t ]; + backend_domid : domid; + devid : int; } + + external add : t -> domid -> unit = "stub_xl_device_vkb_add" + external clean_shutdown : domid -> unit = "stub_xl_device_vkb_clean_shutdown" + external hard_shutdown : domid -> unit = "stub_xl_device_vkb_hard_shutdown" end -type domid = int +module Device_console = struct + type t = + { + backend_domid : domid; + devid : int; + consoletype : console_type; + } -type disk_phystype = - | PHYSTYPE_QCOW - | PHYSTYPE_QCOW2 - | PHYSTYPE_VHD - | PHYSTYPE_AIO - | PHYSTYPE_FILE - | PHYSTYPE_PHY + external add : t -> domid -> unit = "stub_xl_device_console_add" +end module Device_disk = struct type t = @@ -96,10 +113,6 @@ module Device_disk = struct external del : t -> domid -> unit = "stub_xl_device_disk_del" end -type nic_type = - | NICTYPE_IOEMU - | NICTYPE_VIF - module Device_nic = struct type t = { @@ -117,54 +130,6 @@ module Device_nic = struct external del : t -> domid -> unit = "stub_xl_device_nic_del" end -type console_type = - | CONSOLETYPE_XENCONSOLED - | CONSOLETYPE_IOEMU - -module Device_console = struct - type t = - { - backend_domid : domid; - devid : int; - consoletype : console_type; - } - - external add : t -> domid -> unit = "stub_xl_device_console_add" -end - -module Device_vkb = struct - type t = - { - backend_domid : domid; - devid : int; - } - - external add : t -> domid -> unit = "stub_xl_device_vkb_add" - external clean_shutdown : domid -> unit = "stub_xl_device_vkb_clean_shutdown" - external hard_shutdown : domid -> unit = "stub_xl_device_vkb_hard_shutdown" -end - -module Device_vfb = struct - type t = - { - backend_domid : domid; - devid : int; - vnc : bool; - vnclisten : string; - vncpasswd : string; - vncdisplay : int; - vncunused : bool; - keymap : string; - sdl : bool; - opengl : bool; - display : string; - xauthority : string; - } - external add : t -> domid -> unit = "stub_xl_device_vfb_add" - external clean_shutdown : domid -> unit = "stub_xl_device_vfb_clean_shutdown" - external hard_shutdown : domid -> unit = "stub_xl_device_vfb_hard_shutdown" -end - module Device_pci = struct type t = { @@ -201,16 +166,6 @@ module Physinfo = struct end -module Topologyinfo = struct - type t = - { - core: int; - socket: int; - node: int; - } - external get: unit -> t = "stub_xl_topologyinfo" -end - module Sched_credit = struct type t = { @@ -221,9 +176,54 @@ module Sched_credit = struct external domain_set : domid -> t -> unit = "stub_xl_sched_credit_domain_set" end -type button = - | Button_Power - | Button_Sleep +module Domain_build_info = struct + module Hvm = struct + type t = + { + pae : bool; + apic : bool; + acpi : bool; + nx : bool; + viridian : bool; + timeoffset : string; + timer_mode : int; + hpet : int; + vpt_align : int; + } + end + + module Pv = struct + type t = + { + slack_memkb : int64; + cmdline : string; + ramdisk : string; + features : string; + } + end + + type t = + { + max_vcpus : int; + cur_vcpus : int; + max_memkb : int64; + target_memkb : int64; + video_memkb : int64; + shadow_memkb : int64; + kernel : string; + u : [ `HVM of Hvm.t | `PV of Pv.t ]; + } +end + +module Topologyinfo = struct + type t = + { + core: int; + socket: int; + node: int; + } + external get: unit -> t = "stub_xl_topologyinfo" +end external button_press : domid -> button -> unit = "stub_xl_button_press" diff --git a/tools/ocaml/libs/xl/xl.mli b/tools/ocaml/libs/xl/xl.mli index 6dc1df8c20..9d86ebee69 100644 --- a/tools/ocaml/libs/xl/xl.mli +++ b/tools/ocaml/libs/xl/xl.mli @@ -15,6 +15,28 @@ exception Error of string +type domid = int + +type console_type = + | CONSOLETYPE_XENCONSOLED + | CONSOLETYPE_IOEMU + +type disk_phystype = + | PHYSTYPE_QCOW + | PHYSTYPE_QCOW2 + | PHYSTYPE_VHD + | PHYSTYPE_AIO + | PHYSTYPE_FILE + | PHYSTYPE_PHY + +type nic_type = + | NICTYPE_IOEMU + | NICTYPE_VIF + +type button = + | Button_Power + | Button_Sleep + module Domain_create_info : sig type t = { @@ -31,54 +53,49 @@ module Domain_create_info : sig } end -module Domain_build_info : sig - module Hvm : sig - type t = - { - pae : bool; - apic : bool; - acpi : bool; - nx : bool; - viridian : bool; - timeoffset : string; - timer_mode : int; - hpet : int; - vpt_align : int; - } - end - - module Pv : sig - type t = - { - slack_memkb : int64; - cmdline : string; - ramdisk : string; - features : string; - } - end +module Device_vfb : sig + type t = + { + backend_domid : domid; + devid : int; + vnc : bool; + vnclisten : string; + vncpasswd : string; + vncdisplay : int; + vncunused : bool; + keymap : string; + sdl : bool; + opengl : bool; + display : string; + xauthority : string; + } + external add : t -> domid -> unit = "stub_xl_device_vfb_add" + external clean_shutdown : domid -> unit = "stub_xl_device_vfb_clean_shutdown" + external hard_shutdown : domid -> unit = "stub_xl_device_vfb_hard_shutdown" +end +module Device_vkb : sig type t = { - max_vcpus : int; - cur_vcpus : int; - max_memkb : int64; - target_memkb : int64; - video_memkb : int64; - shadow_memkb : int64; - kernel : string; - u : [ `HVM of Hvm.t | `PV of Pv.t ]; + backend_domid : domid; + devid : int; } + + external add : t -> domid -> unit = "stub_xl_device_vkb_add" + external clean_shutdown : domid -> unit = "stub_xl_device_vkb_clean_shutdown" + external hard_shutdown : domid -> unit = "stub_xl_device_vkb_hard_shutdown" end -type domid = int +module Device_console : sig + type t = + { + backend_domid : domid; + devid : int; + consoletype : console_type; + } -type disk_phystype = - | PHYSTYPE_QCOW - | PHYSTYPE_QCOW2 - | PHYSTYPE_VHD - | PHYSTYPE_AIO - | PHYSTYPE_FILE - | PHYSTYPE_PHY + external add : t -> domid -> unit = "stub_xl_device_console_add" +end module Device_disk : sig type t = @@ -96,10 +113,6 @@ module Device_disk : sig external del : t -> domid -> unit = "stub_xl_device_disk_del" end -type nic_type = - | NICTYPE_IOEMU - | NICTYPE_VIF - module Device_nic : sig type t = { @@ -117,54 +130,6 @@ module Device_nic : sig external del : t -> domid -> unit = "stub_xl_device_nic_del" end -type console_type = - | CONSOLETYPE_XENCONSOLED - | CONSOLETYPE_IOEMU - -module Device_console : sig - type t = - { - backend_domid : domid; - devid : int; - consoletype : console_type; - } - - external add : t -> domid -> unit = "stub_xl_device_console_add" -end - -module Device_vkb : sig - type t = - { - backend_domid : domid; - devid : int; - } - - external add : t -> domid -> unit = "stub_xl_device_vkb_add" - external clean_shutdown : domid -> unit = "stub_xl_device_vkb_clean_shutdown" - external hard_shutdown : domid -> unit = "stub_xl_device_vkb_hard_shutdown" -end - -module Device_vfb : sig - type t = - { - backend_domid : domid; - devid : int; - vnc : bool; - vnclisten : string; - vncpasswd : string; - vncdisplay : int; - vncunused : bool; - keymap : string; - sdl : bool; - opengl : bool; - display : string; - xauthority : string; - } - external add : t -> domid -> unit = "stub_xl_device_vfb_add" - external clean_shutdown : domid -> unit = "stub_xl_device_vfb_clean_shutdown" - external hard_shutdown : domid -> unit = "stub_xl_device_vfb_hard_shutdown" -end - module Device_pci : sig type t = { @@ -201,16 +166,6 @@ module Physinfo : sig end -module Topologyinfo : sig - type t = - { - core: int; - socket: int; - node: int; - } - external get : unit -> t = "stub_xl_topologyinfo" -end - module Sched_credit : sig type t = { @@ -222,9 +177,54 @@ module Sched_credit : sig external domain_set : domid -> t -> unit = "stub_xl_sched_credit_domain_set" end -type button = - | Button_Power - | Button_Sleep +module Domain_build_info : sig + module Hvm : sig + type t = + { + pae : bool; + apic : bool; + acpi : bool; + nx : bool; + viridian : bool; + timeoffset : string; + timer_mode : int; + hpet : int; + vpt_align : int; + } + end + + module Pv : sig + type t = + { + slack_memkb : int64; + cmdline : string; + ramdisk : string; + features : string; + } + end + + type t = + { + max_vcpus : int; + cur_vcpus : int; + max_memkb : int64; + target_memkb : int64; + video_memkb : int64; + shadow_memkb : int64; + kernel : string; + u : [ `HVM of Hvm.t | `PV of Pv.t ]; + } +end + +module Topologyinfo : sig + type t = + { + core: int; + socket: int; + node: int; + } + external get : unit -> t = "stub_xl_topologyinfo" +end external button_press : domid -> button -> unit = "stub_xl_button_press" |