GMMR0Internal.h revision 9347f1987dfb760943aba5a9ef094c6066901be3
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync * GMM - The Global Memory Manager, Internal Header.
e64031e20c39650a7bc902a3e1aba613b9415deevboxsync * Copyright (C) 2007 Oracle Corporation
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync * available from http://www.virtualbox.org. This file is free software;
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync * you can redistribute it and/or modify it under the terms of the GNU
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * General Public License (GPL) as published by the Free Software
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
a16eb14ad7a4b5ef91ddc22d3e8e92d930f736fcvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
1dc25926f76c463686b66fb6adec583eef0717advboxsync * The allocation sizes.
1dc25926f76c463686b66fb6adec583eef0717advboxsynctypedef struct GMMVMSIZES
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The number of pages of base memory.
1dc25926f76c463686b66fb6adec583eef0717advboxsync * This is the sum of RAM, ROMs and handy pages. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The number of pages for the shadow pool. (Can be sequeezed for memory.) */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The number of pages for fixed allocations like MMIO2 and the hyper heap. */
209c11e4b5dbb310116c99a42d773163928e002bvboxsync/** Pointer to a GMMVMSIZES. */
b2def6ea46868a11f7fd2857874e46c51932223avboxsync * Shared module registration info (per VM)
e4d7b580d72e968d3753363ab36e196a968c1947vboxsync /** Tree node. */
e4d7b580d72e968d3753363ab36e196a968c1947vboxsync /** Pointer to global shared module info. */
e4d7b580d72e968d3753363ab36e196a968c1947vboxsync /** Set if another VM registered a different shared module at the same base address. */
e4d7b580d72e968d3753363ab36e196a968c1947vboxsync /** Alignment. */
9347f1987dfb760943aba5a9ef094c6066901be3vboxsync /** Number of included region descriptors */
9347f1987dfb760943aba5a9ef094c6066901be3vboxsync /** Shared region descriptor(s). */
b2def6ea46868a11f7fd2857874e46c51932223avboxsync/** Pointer to a GMMSHAREDMODULEPERVM. */
b2def6ea46868a11f7fd2857874e46c51932223avboxsynctypedef GMMSHAREDMODULEPERVM *PGMMSHAREDMODULEPERVM;
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync * The per-VM GMM data.
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsynctypedef struct GMMPERVM
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The reservations. */
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync /** The actual allocations.
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync * This includes both private and shared page allocations. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The current number of private pages. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The current number of shared pages. */
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync /** The current over-comitment policy. */
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync /** The VM priority for arbitrating VMs in low and out of memory situation.
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync * Like which VMs to start sequeezing first. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The current number of ballooned pages. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** The max number of pages that can be ballooned. */
1d5596b941d86a014c20420b73ad7be2de35cf9dvboxsync /** The number of pages we've currently requested the guest to give us.
1d5596b941d86a014c20420b73ad7be2de35cf9dvboxsync * This is 0 if no pages currently requested. */
1d5596b941d86a014c20420b73ad7be2de35cf9dvboxsync /** The number of pages the guest has given us in response to the request.
1d5596b941d86a014c20420b73ad7be2de35cf9dvboxsync * This is not reset on request completed and may be used in later decisions. */
1d5596b941d86a014c20420b73ad7be2de35cf9dvboxsync /** The number of pages we've currently requested the guest to take back. */
b2def6ea46868a11f7fd2857874e46c51932223avboxsync /** Shared module tree (per-vm). */
3cc114d9c84cf4a1e3b5225e81527614c30f1d83vboxsync /** Whether ballooning is enabled or not. */
5e31c5b77713d7c61de5f65f1c3d057dddaa27f3vboxsync /** Whether shared paging is enabled or not. */
1dc25926f76c463686b66fb6adec583eef0717advboxsync /** Whether the VM is allowed to allocate memory or not.
1dc25926f76c463686b66fb6adec583eef0717advboxsync * This is used when the reservation update request fails or when the VM has
1dc25926f76c463686b66fb6adec583eef0717advboxsync * been told to suspend/save/die in an out-of-memory case. */
1205f5a22a14de7b9cf3055d6f914eac690c1715vboxsync/** Pointer to the per-VM GMM data. */