aboutsummaryrefslogtreecommitdiff
path: root/sys/amd64/include
diff options
context:
space:
mode:
authorRodney W. Grimes <rgrimes@FreeBSD.org>2019-04-25 22:51:36 +0000
committerRodney W. Grimes <rgrimes@FreeBSD.org>2019-04-25 22:51:36 +0000
commita488c9c99a65f4bc75c25465d7adf6b21718cf7c (patch)
tree2c71f825c127fb820dfdeab889191a0624664bb8 /sys/amd64/include
parent20105d31eeef01e5c5322726bd966a825ca9639d (diff)
downloadsrc-a488c9c99a65f4bc75c25465d7adf6b21718cf7c.tar.gz
src-a488c9c99a65f4bc75c25465d7adf6b21718cf7c.zip
Add accessor function for vm->maxcpus
Replace most VM_MAXCPU constant useses with an accessor function to vm->maxcpus which for now is initialized and kept at the value of VM_MAXCPUS. This is a rework of Fabian Freyer (fabian.freyer_physik.tu-berlin.de) work from D10070 to adjust it for the cpu topology changes that occured in r332298 Submitted by: Fabian Freyer (fabian.freyer_physik.tu-berlin.de) Reviewed by: Patrick Mooney <patrick.mooney@joyent.com> Approved by: bde (mentor), jhb (maintainer) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D18755
Notes
Notes: svn path=/head/; revision=346714
Diffstat (limited to 'sys/amd64/include')
-rw-r--r--sys/amd64/include/vmm.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/amd64/include/vmm.h b/sys/amd64/include/vmm.h
index b66eda0f4768..3f08939ca09f 100644
--- a/sys/amd64/include/vmm.h
+++ b/sys/amd64/include/vmm.h
@@ -186,6 +186,7 @@ int vm_create(const char *name, struct vm **retvm);
void vm_destroy(struct vm *vm);
int vm_reinit(struct vm *vm);
const char *vm_name(struct vm *vm);
+uint16_t vm_get_maxcpus(struct vm *vm);
void vm_get_topology(struct vm *vm, uint16_t *sockets, uint16_t *cores,
uint16_t *threads, uint16_t *maxcpus);
int vm_set_topology(struct vm *vm, uint16_t sockets, uint16_t cores,