diff options
author | bz <bz@FreeBSD.org> | 2008-12-27 17:19:16 +0000 |
---|---|---|
committer | bz <bz@FreeBSD.org> | 2008-12-27 17:19:16 +0000 |
commit | 7d22a18291d067d3da7a6361c52a1cd68fbeab7b (patch) | |
tree | 0ad7dab81d79af2cd7a0ceeca6c58010e4c18cb1 /sys/kern/subr_param.c | |
parent | ea5aab52c3f9cdd965b5c2d65f88114f68c669d1 (diff) | |
download | FreeBSD-src-7d22a18291d067d3da7a6361c52a1cd68fbeab7b.zip FreeBSD-src-7d22a18291d067d3da7a6361c52a1cd68fbeab7b.tar.gz |
Hide detect_virtual() along with the accompanying string
arrays under #ifndef XEN to make XEN config compile again.
In case of Xen vm_guest is hard coded.
Move the list for the vm_guest sysctl out of the restictive
bounds as the sysctl is there in either case.
Diffstat (limited to 'sys/kern/subr_param.c')
-rw-r--r-- | sys/kern/subr_param.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/sys/kern/subr_param.c b/sys/kern/subr_param.c index 6a0745f..67fe14d 100644 --- a/sys/kern/subr_param.c +++ b/sys/kern/subr_param.c @@ -126,6 +126,14 @@ SYSCTL_PROC(_kern, OID_AUTO, vm_guest, CTLFLAG_RD | CTLTYPE_STRING, */ struct buf *swbuf; +static const char *const vm_guest_sysctl_names[] = { + "none", + "generic", + "xen", + NULL +}; + +#ifndef XEN static const char *const vm_bnames[] = { "QEMU", /* QEMU */ "Plex86", /* Plex86 */ @@ -141,13 +149,6 @@ static const char *const vm_pnames[] = { NULL }; -static const char *const vm_guest_sysctl_names[] = { - "none", - "generic", - "xen", - NULL -}; - /* * Detect known Virtual Machine hosts by inspecting the emulated BIOS. @@ -178,6 +179,7 @@ detect_virtual(void) } return (VM_GUEST_NO); } +#endif /* * Boot time overrides that are not scaled against main memory |