[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] libxl: tweak formatting of _libxl_types.h to better suit autogeneration
# HG changeset patch # User Ian Campbell <ian.campbell@xxxxxxxxxx> # Date 1282225592 -3600 # Node ID a05a2d55993188c6af8f8e6116bff758642037ae # Parent e486507c2d9176b519ba47d8cf3205bba96b7c58 libxl: tweak formatting of _libxl_types.h to better suit autogeneration This makes it easier to do a before/after comparison when the file becomes autogenerated. [PATCH 03 of 16 of libxl: autogenerate type definitions and destructor functions] Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> --- tools/libxl/_libxl_types.h | 278 +++++++++++++++++++++++++++++++-------------- 1 files changed, 194 insertions(+), 84 deletions(-) diff -r e486507c2d91 -r a05a2d559931 tools/libxl/_libxl_types.h --- a/tools/libxl/_libxl_types.h Thu Aug 19 14:45:36 2010 +0100 +++ b/tools/libxl/_libxl_types.h Thu Aug 19 14:46:32 2010 +0100 @@ -9,7 +9,6 @@ typedef struct { uint8_t paused:1; uint8_t shutdown:1; uint8_t dying:1; - /* * Valid SHUTDOWN_* value from xen/sched.h iff (shutdown||dying). * @@ -17,7 +16,6 @@ typedef struct { * SHUTDOWN_* constant. */ unsigned int shutdown_reason; - uint64_t max_memkb; uint64_t cpu_time; uint32_t vcpu_max_id; @@ -36,16 +34,16 @@ typedef struct { typedef struct { int xen_version_major; int xen_version_minor; - char *xen_version_extra; - char *compiler; - char *compile_by; - char *compile_domain; - char *compile_date; - char *capabilities; - char *changeset; + char * xen_version_extra; + char * compiler; + char * compile_by; + char * compile_domain; + char * compile_date; + char * capabilities; + char * changeset; unsigned long virt_start; unsigned long pagesize; - char *commandline; + char * commandline; } libxl_version_info; typedef struct { @@ -53,22 +51,22 @@ typedef struct { bool hap; bool oos; int ssidref; - char *name; + char * name; libxl_uuid uuid; libxl_key_value_list xsdata; libxl_key_value_list platformdata; uint32_t poolid; - char *poolname; + char * poolname; } libxl_domain_create_info; typedef struct { /* - * Path is always set if the file refernece is valid. However if + * Path is always set if the file reference is valid. However if * mapped is true then the actual file may already be unlinked. */ - char *path; + char * path; int mapped; - void *data; + void * data; size_t size; } libxl_file_reference; @@ -97,18 +95,18 @@ typedef struct { bool acpi; bool nx; bool viridian; - char *timeoffset; + char * timeoffset; bool hpet; bool vpt_align; int timer_mode; } hvm; struct { - uint32_t slack_memkb; - const char *bootloader; - const char *bootloader_args; - char *cmdline; + uint32_t slack_memkb; + const char * bootloader; + const char * bootloader_args; + char * cmdline; libxl_file_reference ramdisk; - const char *features; + const char * features; } pv; } u; } libxl_domain_build_info; @@ -120,51 +118,145 @@ typedef struct { unsigned long console_mfn; } libxl_domain_build_state; +/* + * Device Model information. + * + * Network is missing + */ typedef struct { int domid; - libxl_uuid uuid; /* this is use only with stubdom, and must be different from the domain uuid */ - char *dom_name; - char *device_model; - char *saved_state; + /* + * this is use only with stubdom, and must be different from the domain uuid + */ + libxl_uuid uuid; + char * dom_name; + char * device_model; + char * saved_state; libxl_qemu_machine_type type; - int videoram; /* size of the videoram in MB */ - bool stdvga; /* stdvga enabled or disabled */ - bool vnc; /* vnc enabled or disabled */ - char *vnclisten; /* address:port that should be listened on for the VNC server if vnc is set */ - char *vncpasswd; /* the VNC password */ - int vncdisplay; /* set VNC display number */ - bool vncunused; /* try to find an unused port for the VNC server */ - char *keymap; /* set keyboard layout, default is en-us keyboard */ - bool sdl; /* sdl enabled or disabled */ - bool opengl; /* opengl enabled or disabled (if enabled requires sdl enabled) */ - bool nographic; /* no graphics, use serial port */ - char *serial; /* serial port re-direct to pty deivce */ - char *boot; /* boot order, for example dca */ - bool usb; /* usb support enabled or disabled */ - char *usbdevice; /* enable usb mouse: tablet for absolute mouse, mouse for PS/2 protocol relative mouse */ - char *soundhw; /* enable sound hardware */ - bool apic; /* apic enabled or disabled */ - int vcpus; /* max number of vcpus */ - int vcpu_avail; /* vcpus actually available */ - int xen_platform_pci; /* enable/disable the xen platform pci device */ - libxl_string_list extra; /* extra parameters pass directly to qemu, NULL terminated */ - /* Network is missing */ + /* + * size of the videoram in MB + */ + int videoram; + /* + * stdvga enabled or disabled + */ + bool stdvga; + /* + * vnc enabled or disabled + */ + bool vnc; + /* + * address:port that should be listened on for the VNC server if vnc is set + */ + char * vnclisten; + /* + * the VNC password + */ + char * vncpasswd; + /* + * set VNC display number + */ + int vncdisplay; + /* + * try to find an unused port for the VNC server + */ + bool vncunused; + /* + * set keyboard layout, default is en-us keyboard + */ + char * keymap; + /* + * sdl enabled or disabled + */ + bool sdl; + /* + * opengl enabled or disabled (if enabled requires sdl enabled) + */ + bool opengl; + /* + * no graphics, use serial port + */ + bool nographic; + /* + * serial port re-direct to pty deivce + */ + char * serial; + /* + * boot order, for example dca + */ + char * boot; + /* + * usb support enabled or disabled + */ + bool usb; + /* + * enable usb mouse: tablet for absolute mouse, mouse for PS/2 protocol relative mouse + */ + char * usbdevice; + /* + * enable sound hardware + */ + char * soundhw; + /* + * apic enabled or disabled + */ + bool apic; + /* + * max number of vcpus + */ + int vcpus; + /* + * vcpus actually available + */ + int vcpu_avail; + /* + * enable/disable the xen platform pci device + */ + int xen_platform_pci; + /* + * extra parameters pass directly to qemu, NULL terminated + */ + libxl_string_list extra; } libxl_device_model_info; typedef struct { uint32_t backend_domid; uint32_t domid; int devid; - bool vnc; /* vnc enabled or disabled */ - char *vnclisten; /* address:port that should be listened on for the VNC server if vnc is set */ - char *vncpasswd; /* the VNC password */ - int vncdisplay; /* set VNC display number */ - bool vncunused; /* try to find an unused port for the VNC server */ - char *keymap; /* set keyboard layout, default is en-us keyboard */ - bool sdl; /* sdl enabled or disabled */ - bool opengl; /* opengl enabled or disabled (if enabled requires sdl enabled) */ - char *display; - char *xauthority; + /* + * vnc enabled or disabled + */ + bool vnc; + /* + * address:port that should be listened on for the VNC server if vnc is set + */ + char * vnclisten; + /* + * the VNC password + */ + char * vncpasswd; + /* + * set VNC display number + */ + int vncdisplay; + /* + * try to find an unused port for the VNC server + */ + bool vncunused; + /* + * set keyboard layout, default is en-us keyboard + */ + char * keymap; + /* + * sdl enabled or disabled + */ + bool sdl; + /* + * opengl enabled or disabled (if enabled requires sdl enabled) + */ + bool opengl; + char * display; + char * xauthority; } libxl_device_vfb; typedef struct { @@ -178,16 +270,16 @@ typedef struct { uint32_t domid; int devid; libxl_console_consback consback; - libxl_domain_build_state *build_state; - char *output; + libxl_domain_build_state * build_state; + char * output; } libxl_device_console; typedef struct { uint32_t backend_domid; uint32_t domid; - char *physpath; + char * physpath; libxl_disk_phystype phystype; - char *virtpath; + char * virtpath; int unpluggable; int readwrite; int is_cdrom; @@ -198,12 +290,12 @@ typedef struct { uint32_t domid; int devid; int mtu; - char *model; + char * model; libxl_mac mac; struct in_addr ip; - char *bridge; - char *ifname; - char *script; + char * bridge; + char * ifname; + char * script; libxl_nic_type nictype; } libxl_device_nic; @@ -219,7 +311,7 @@ typedef struct { uint32_t front_filter_mac:1; uint32_t pdev; uint32_t max_bypasses; - char *bridge; + char * bridge; } libxl_device_net2; typedef struct { @@ -243,9 +335,9 @@ typedef struct { } libxl_device_pci; typedef struct { - char *backend; + char * backend; uint32_t backend_id; - char *frontend; + char * frontend; uint32_t frontend_id; int devid; int state; @@ -254,13 +346,13 @@ typedef struct { } libxl_diskinfo; typedef struct { - char *backend; + char * backend; uint32_t backend_id; - char *frontend; + char * frontend; uint32_t frontend_id; int devid; int state; - char *script; + char * script; libxl_mac mac; int evtch; int rref_tx; @@ -268,31 +360,49 @@ typedef struct { } libxl_nicinfo; typedef struct { - uint32_t vcpuid; /* vcpu's id */ - uint32_t cpu; /* current mapping */ - uint8_t online:1; /* currently online (not hotplugged)? */ - uint8_t blocked:1; /* blocked waiting for an event? */ - uint8_t running:1; /* currently scheduled on its CPU? */ - uint64_t vcpu_time; /* total vcpu time ran (ns) */ - libxl_cpumap cpumap; /* current cpu's affinities */ + /* + * vcpu's id + */ + uint32_t vcpuid; + /* + * current mapping + */ + uint32_t cpu; + /* + * currently online (not hotplugged)? + */ + uint8_t online:1; + /* + * blocked waiting for an event? + */ + uint8_t blocked:1; + /* + * currently scheduled on its CPU? + */ + uint8_t running:1; + /* + * total vcpu time ran (ns) + */ + uint64_t vcpu_time; + /* + * current cpu's affinities + */ + libxl_cpumap cpumap; } libxl_vcpuinfo; typedef struct { uint32_t threads_per_core; uint32_t cores_per_socket; - uint32_t max_cpu_id; uint32_t nr_cpus; uint32_t cpu_khz; - uint64_t total_pages; uint64_t free_pages; uint64_t scrub_pages; - uint32_t nr_nodes; libxl_hwcap hw_cap; uint32_t phys_cap; -} libxl_physinfo; +} libxl_physinfo; typedef struct { int weight; @@ -300,9 +410,9 @@ typedef struct { } libxl_sched_credit; typedef struct { - char *backend; + char * backend; uint32_t backend_id; - char *frontend; + char * frontend; uint32_t frontend_id; int devid; int state; _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |