Changeset 28012 in vbox for trunk/src/VBox/VMM/VMMR0
- Timestamp:
- Apr 6, 2010 2:52:25 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 59719
- Location:
- trunk/src/VBox/VMM/VMMR0
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMR0/GMMR0.cpp
r27999 r28012 2992 2992 2993 2993 /** 2994 * Return the total amount of ballooned pages for all VMs2994 * Return the total amount of free pages 2995 2995 * 2996 2996 * @returns VBox status code: … … 2998 2998 * @param pReq The request packet. 2999 2999 */ 3000 GMMR0DECL(int) GMMR0QueryTotal BalloonSizeReq(PVM pVM, PGMMBALLOONQUERYREQ pReq)3000 GMMR0DECL(int) GMMR0QueryTotalFreePagesReq(PVM pVM, PGMMFREEQUERYREQ pReq) 3001 3001 { 3002 3002 /* … … 3005 3005 AssertPtrReturn(pVM, VERR_INVALID_POINTER); 3006 3006 AssertPtrReturn(pReq, VERR_INVALID_POINTER); 3007 AssertMsgReturn(pReq->Hdr.cbReq == sizeof(GMM BALLOONQUERYREQ),3008 ("%#x < %#x\n", pReq->Hdr.cbReq, sizeof(GMM BALLOONQUERYREQ)),3007 AssertMsgReturn(pReq->Hdr.cbReq == sizeof(GMMFREEQUERYREQ), 3008 ("%#x < %#x\n", pReq->Hdr.cbReq, sizeof(GMMFREEQUERYREQ)), 3009 3009 VERR_INVALID_PARAMETER); 3010 3010 … … 3014 3014 PGMM pGMM; 3015 3015 GMM_GET_VALID_INSTANCE(pGMM, VERR_INTERNAL_ERROR); 3016 pReq->c BalloonedPages = pGMM->cBalloonedPages;3016 pReq->cFreePages = (pGMM->cChunks << GMM_CHUNK_SHIFT) - pGMM->cAllocatedPages; 3017 3017 GMM_CHECK_SANITY_UPON_LEAVING(pGMM); 3018 3018 -
trunk/src/VBox/VMM/VMMR0/VMMR0.cpp
r27999 r28012 910 910 return GMMR0FreeLargePageReq(pVM, idCpu, (PGMMFREELARGEPAGEREQ)pReqHdr); 911 911 912 case VMMR0_DO_GMM_QUERY_TOTAL_FREE_PAGES: 913 if (u64Arg) 914 return VERR_INVALID_PARAMETER; 915 return GMMR0QueryTotalFreePagesReq(pVM, (PGMMFREEQUERYREQ)pReqHdr); 916 912 917 case VMMR0_DO_GMM_BALLOONED_PAGES: 913 918 if (u64Arg) 914 919 return VERR_INVALID_PARAMETER; 915 920 return GMMR0BalloonedPagesReq(pVM, idCpu, (PGMMBALLOONEDPAGESREQ)pReqHdr); 916 917 case VMMR0_DO_GMM_QUERY_TOTAL_BALLOON_SIZE:918 if (u64Arg)919 return VERR_INVALID_PARAMETER;920 return GMMR0QueryTotalBalloonSizeReq(pVM, (PGMMBALLOONQUERYREQ)pReqHdr);921 921 922 922 case VMMR0_DO_GMM_MAP_UNMAP_CHUNK:
Note:
See TracChangeset
for help on using the changeset viewer.