File indexing completed on 2025-01-18 10:13:28
0001 #ifndef __VKI_XEN_SYSCTL_H
0002 #define __VKI_XEN_SYSCTL_H
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022 #define VKI_XEN_SYSCTL_readconsole 1
0023 #define VKI_XEN_SYSCTL_tbuf_op 2
0024 #define VKI_XEN_SYSCTL_physinfo 3
0025 #define VKI_XEN_SYSCTL_sched_id 4
0026 #define VKI_XEN_SYSCTL_perfc_op 5
0027 #define VKI_XEN_SYSCTL_getdomaininfolist 6
0028 #define VKI_XEN_SYSCTL_debug_keys 7
0029 #define VKI_XEN_SYSCTL_getcpuinfo 8
0030 #define VKI_XEN_SYSCTL_availheap 9
0031 #define VKI_XEN_SYSCTL_get_pmstat 10
0032 #define VKI_XEN_SYSCTL_cpu_hotplug 11
0033 #define VKI_XEN_SYSCTL_pm_op 12
0034 #define VKI_XEN_SYSCTL_page_offline_op 14
0035 #define VKI_XEN_SYSCTL_lockprof_op 15
0036 #define VKI_XEN_SYSCTL_topologyinfo 16
0037 #define VKI_XEN_SYSCTL_numainfo 17
0038 #define VKI_XEN_SYSCTL_cpupool_op 18
0039 #define VKI_XEN_SYSCTL_scheduler_op 19
0040 #define VKI_XEN_SYSCTL_coverage_op 20
0041
0042 struct vki_xen_sysctl_readconsole {
0043
0044 vki_uint8_t clear;
0045 vki_uint8_t incremental;
0046
0047 vki_uint8_t pad0, pad1;
0048
0049
0050
0051
0052
0053 vki_uint32_t index;
0054 VKI_XEN_GUEST_HANDLE_64(char) buffer;
0055
0056
0057
0058
0059
0060 vki_uint32_t count;
0061 };
0062
0063 struct vki_xen_sysctl_getdomaininfolist_00000008 {
0064
0065 vki_xen_domid_t first_domain;
0066 vki_uint32_t max_domains;
0067 VKI_XEN_GUEST_HANDLE_64(vki_xen_domctl_getdomaininfo_00000007_t) buffer;
0068
0069 vki_uint32_t num_domains;
0070 };
0071
0072 struct vki_xen_sysctl_getdomaininfolist_00000009 {
0073
0074 vki_xen_domid_t first_domain;
0075 vki_uint32_t max_domains;
0076 VKI_XEN_GUEST_HANDLE_64(vki_xen_domctl_getdomaininfo_00000008_t) buffer;
0077
0078 vki_uint32_t num_domains;
0079 };
0080
0081 struct vki_xen_sysctl_getdomaininfolist_0000000a {
0082
0083 vki_xen_domid_t first_domain;
0084 vki_uint32_t max_domains;
0085 VKI_XEN_GUEST_HANDLE_64(vki_xen_domctl_getdomaininfo_00000009_t) buffer;
0086
0087 vki_uint32_t num_domains;
0088 };
0089
0090 struct vki_xen_sysctl_getdomaininfolist_00000010 {
0091
0092 vki_xen_domid_t first_domain;
0093 vki_uint32_t max_domains;
0094 VKI_XEN_GUEST_HANDLE_64(vki_xen_domctl_getdomaininfo_00000010_t) buffer;
0095
0096 vki_uint32_t num_domains;
0097 };
0098
0099
0100
0101 #define VKI_XEN_SYSCTL_CPUPOOL_OP_CREATE 1
0102 #define VKI_XEN_SYSCTL_CPUPOOL_OP_DESTROY 2
0103 #define VKI_XEN_SYSCTL_CPUPOOL_OP_INFO 3
0104 #define VKI_XEN_SYSCTL_CPUPOOL_OP_ADDCPU 4
0105 #define VKI_XEN_SYSCTL_CPUPOOL_OP_RMCPU 5
0106 #define VKI_XEN_SYSCTL_CPUPOOL_OP_MOVEDOMAIN 6
0107 #define VKI_XEN_SYSCTL_CPUPOOL_OP_FREEINFO 7
0108 #define VKI_XEN_SYSCTL_CPUPOOL_PAR_ANY 0xFFFFFFFF
0109 struct vki_xen_sysctl_cpupool_op {
0110 vki_uint32_t op;
0111 vki_uint32_t cpupool_id;
0112 vki_uint32_t sched_id;
0113 vki_uint32_t domid;
0114 vki_uint32_t cpu;
0115 vki_uint32_t n_dom;
0116 struct vki_xenctl_bitmap cpumap;
0117 };
0118
0119 struct vki_xen_sysctl_debug_keys {
0120
0121 VKI_XEN_GUEST_HANDLE_64(char) keys;
0122 vki_uint32_t nr_keys;
0123 };
0124
0125 struct vki_xen_sysctl_topologyinfo {
0126 vki_uint32_t max_cpu_index;
0127 VKI_XEN_GUEST_HANDLE_64(vki_uint32) cpu_to_core;
0128 VKI_XEN_GUEST_HANDLE_64(vki_uint32) cpu_to_socket;
0129 VKI_XEN_GUEST_HANDLE_64(vki_uint32) cpu_to_node;
0130 };
0131
0132 struct vki_xen_sysctl_numainfo {
0133 vki_uint32_t max_node_index;
0134 VKI_XEN_GUEST_HANDLE_64(vki_uint64) node_to_memsize;
0135 VKI_XEN_GUEST_HANDLE_64(vki_uint64) node_to_memfree;
0136 VKI_XEN_GUEST_HANDLE_64(vki_uint32) node_to_node_distance;
0137 };
0138 struct vki_xen_sysctl_physinfo_00000008 {
0139 vki_uint32_t threads_per_core;
0140 vki_uint32_t cores_per_socket;
0141 vki_uint32_t nr_cpus;
0142 vki_uint32_t max_cpu_id;
0143 vki_uint32_t nr_nodes;
0144 vki_uint32_t max_node_id;
0145 vki_uint32_t cpu_khz;
0146 vki_xen_uint64_aligned_t total_pages;
0147 vki_xen_uint64_aligned_t free_pages;
0148 vki_xen_uint64_aligned_t scrub_pages;
0149 vki_uint32_t hw_cap[8];
0150
0151 vki_uint32_t capabilities;
0152 };
0153
0154 struct vki_xen_sysctl_physinfo_0000000a {
0155 vki_uint32_t threads_per_core;
0156 vki_uint32_t cores_per_socket;
0157 vki_uint32_t nr_cpus;
0158 vki_uint32_t max_cpu_id;
0159 vki_uint32_t nr_nodes;
0160 vki_uint32_t max_node_id;
0161 vki_uint32_t cpu_khz;
0162 vki_xen_uint64_aligned_t total_pages;
0163 vki_xen_uint64_aligned_t free_pages;
0164 vki_xen_uint64_aligned_t scrub_pages;
0165 vki_xen_uint64_aligned_t outstanding_pages;
0166 vki_uint32_t hw_cap[8];
0167
0168 vki_uint32_t capabilities;
0169 };
0170
0171 struct vki_xen_sysctl_physinfo_00000010 {
0172 vki_uint32_t threads_per_core;
0173 vki_uint32_t cores_per_socket;
0174 vki_uint32_t nr_cpus;
0175 vki_uint32_t max_cpu_id;
0176 vki_uint32_t nr_nodes;
0177 vki_uint32_t max_node_id;
0178 vki_uint32_t cpu_khz;
0179 vki_uint32_t capabilities;
0180 vki_xen_uint64_aligned_t total_pages;
0181 vki_xen_uint64_aligned_t free_pages;
0182 vki_xen_uint64_aligned_t scrub_pages;
0183 vki_xen_uint64_aligned_t outstanding_pages;
0184 vki_xen_uint64_aligned_t max_mfn;
0185 vki_uint32_t hw_cap[8];
0186
0187 };
0188
0189 struct vki_xen_sysctl_sched_id {
0190
0191 vki_uint32_t sched_id;
0192 };
0193
0194 struct vki_xen_sysctl {
0195 vki_uint32_t cmd;
0196 vki_uint32_t interface_version;
0197 union {
0198 struct vki_xen_sysctl_readconsole readconsole;
0199
0200 struct vki_xen_sysctl_physinfo_00000008 physinfo_00000008;
0201 struct vki_xen_sysctl_physinfo_0000000a physinfo_0000000a;
0202 struct vki_xen_sysctl_physinfo_00000010 physinfo_00000010;
0203 struct vki_xen_sysctl_topologyinfo topologyinfo;
0204 struct vki_xen_sysctl_numainfo numainfo;
0205 struct vki_xen_sysctl_sched_id sched_id;
0206
0207 struct vki_xen_sysctl_getdomaininfolist_00000008 getdomaininfolist_00000008;
0208 struct vki_xen_sysctl_getdomaininfolist_00000009 getdomaininfolist_00000009;
0209 struct vki_xen_sysctl_getdomaininfolist_0000000a getdomaininfolist_0000000a;
0210 struct vki_xen_sysctl_getdomaininfolist_00000010 getdomaininfolist_00000010;
0211 struct vki_xen_sysctl_debug_keys debug_keys;
0212
0213
0214
0215
0216
0217
0218
0219 struct vki_xen_sysctl_cpupool_op cpupool_op;
0220
0221
0222
0223 vki_uint8_t pad[128];
0224 } u;
0225 };
0226
0227 #endif
0228
0229
0230
0231