Changeset View
Changeset View
Standalone View
Standalone View
head/sys/kern/subr_param.c
Show First 20 Lines • Show All 140 Lines • ▼ Show 20 Lines | SYSCTL_PROC(_kern, OID_AUTO, vm_guest, CTLFLAG_RD | CTLTYPE_STRING, | ||||
NULL, 0, sysctl_kern_vm_guest, "A", | NULL, 0, sysctl_kern_vm_guest, "A", | ||||
"Virtual machine guest detected?"); | "Virtual machine guest detected?"); | ||||
/* | /* | ||||
* The elements of this array are ordered based upon the values of the | * The elements of this array are ordered based upon the values of the | ||||
* corresponding enum VM_GUEST members. | * corresponding enum VM_GUEST members. | ||||
*/ | */ | ||||
static const char *const vm_guest_sysctl_names[] = { | static const char *const vm_guest_sysctl_names[] = { | ||||
"none", | [VM_GUEST_NO] = "none", | ||||
"generic", | [VM_GUEST_VM] = "generic", | ||||
"xen", | [VM_GUEST_XEN] = "xen", | ||||
"hv", | [VM_GUEST_HV] = "hv", | ||||
"vmware", | [VM_GUEST_VMWARE] = "vmware", | ||||
"kvm", | [VM_GUEST_KVM] = "kvm", | ||||
"bhyve", | [VM_GUEST_BHYVE] = "bhyve", | ||||
"vbox", | [VM_GUEST_VBOX] = "vbox", | ||||
NULL | [VM_GUEST_PARALLELS] = "parallels", | ||||
[VM_LAST] = NULL | |||||
}; | }; | ||||
CTASSERT(nitems(vm_guest_sysctl_names) - 1 == VM_LAST); | CTASSERT(nitems(vm_guest_sysctl_names) - 1 == VM_LAST); | ||||
/* | /* | ||||
* Boot time overrides that are not scaled against main memory | * Boot time overrides that are not scaled against main memory | ||||
*/ | */ | ||||
void | void | ||||
init_param1(void) | init_param1(void) | ||||
▲ Show 20 Lines • Show All 152 Lines • Show Last 20 Lines |