Changeset 16428 in vbox
- Timestamp:
- Jan 30, 2009 4:49:19 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 42292
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/PGM.cpp
r16422 r16428 685 685 #define PGM_BTH_NAME_R0_STR(name) PGM_BTH_NAME_R0_32BIT_REAL_STR(name) 686 686 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_32BIT_PT_FOR_PHYS 687 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS _REAL687 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS 688 688 #include "PGMBth.h" 689 689 #include "PGMGst.h" … … 707 707 #define PGM_BTH_NAME_R0_STR(name) PGM_BTH_NAME_R0_32BIT_PROT_STR(name) 708 708 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_32BIT_PT_FOR_PHYS 709 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS _PROT709 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS 710 710 #include "PGMBth.h" 711 711 #include "PGMGst.h" … … 769 769 #define PGM_BTH_NAME_R0_STR(name) PGM_BTH_NAME_R0_PAE_REAL_STR(name) 770 770 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_PAE_PT_FOR_PHYS 771 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS _REAL771 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS 772 772 #include "PGMBth.h" 773 773 #undef BTH_PGMPOOLKIND_PT_FOR_PT … … 790 790 #define PGM_BTH_NAME_R0_STR(name) PGM_BTH_NAME_R0_PAE_PROT_STR(name) 791 791 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_PAE_PT_FOR_PHYS 792 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS _PROT792 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS 793 793 #include "PGMBth.h" 794 794 #undef BTH_PGMPOOLKIND_PT_FOR_PT -
trunk/src/VBox/VMM/PGMInternal.h
r16419 r16428 57 57 * Enable to use the PGM pool for all levels in the paging chain in all paging modes. 58 58 */ 59 //#define VBOX_WITH_PGMPOOL_PAGING_ONLY59 #define VBOX_WITH_PGMPOOL_PAGING_ONLY 60 60 61 61 /** … … 1514 1514 /** Shw: 32-bit page directory. Gst: 32-bit page directory. */ 1515 1515 PGMPOOLKIND_32BIT_PD, 1516 /** Shw: 32-bit page directory. Gst: real mode. */ 1517 PGMPOOLKIND_32BIT_PD_PHYS_REAL, 1518 /** Shw: 32-bit page directory. Gst: protected mode without paging. */ 1519 PGMPOOLKIND_32BIT_PD_PHYS_PROT, 1516 /** Shw: 32-bit page directory. Gst: no paging. */ 1517 PGMPOOLKIND_32BIT_PD_PHYS, 1520 1518 /** Shw: PAE page directory; Gst: 32-bit page directory. */ 1521 1519 PGMPOOLKIND_PAE_PD_FOR_32BIT_PD, 1522 1520 /** Shw: PAE page directory; Gst: PAE page directory. */ 1523 1521 PGMPOOLKIND_PAE_PD_FOR_PAE_PD, 1524 /** Shw: PAE page directory; Gst: real mode. */ 1525 PGMPOOLKIND_PAE_PD_PHYS_REAL, 1526 /** Shw: PAE page directory; Gst: protected mode without paging. */ 1527 PGMPOOLKIND_PAE_PD_PHYS_PROT, 1522 /** Shw: PAE page directory; Gst: no paging. */ 1523 PGMPOOLKIND_PAE_PD_PHYS, 1528 1524 1529 1525 /** Shw: PAE page directory pointer table (legacy, 4 entries); Gst 32 bits paging. */ … … 1531 1527 /** Shw: PAE page directory pointer table (legacy, 4 entries); Gst PAE PDPT. */ 1532 1528 PGMPOOLKIND_PAE_PDPT, 1533 /** Shw: PAE page directory pointer table (legacy, 4 entries); Gst: real mode. */ 1534 PGMPOOLKIND_PAE_PDPT_PHYS_REAL, 1535 /** Shw: PAE page directory pointer table (legacy, 4 entries); Gst: protected mode without paging. */ 1536 PGMPOOLKIND_PAE_PDPT_PHYS_PROT, 1529 /** Shw: PAE page directory pointer table (legacy, 4 entries); Gst: no paging. */ 1530 PGMPOOLKIND_PAE_PDPT_PHYS, 1537 1531 1538 1532 /** Shw: 64-bit page directory pointer table; Gst: 64-bit page directory pointer table. */ -
trunk/src/VBox/VMM/VMMAll/PGMAll.cpp
r16321 r16428 90 90 #define PGM_BTH_NAME(name) PGM_BTH_NAME_32BIT_REAL(name) 91 91 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_32BIT_PT_FOR_PHYS 92 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS _REAL92 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS 93 93 #include "PGMAllGst.h" 94 94 #include "PGMAllBth.h" … … 104 104 #define PGM_BTH_NAME(name) PGM_BTH_NAME_32BIT_PROT(name) 105 105 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_32BIT_PT_FOR_PHYS 106 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS _PROT106 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_32BIT_PD_PHYS 107 107 #include "PGMAllGst.h" 108 108 #include "PGMAllBth.h" … … 146 146 #define PGM_BTH_NAME(name) PGM_BTH_NAME_PAE_REAL(name) 147 147 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_PAE_PT_FOR_PHYS 148 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS _REAL148 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS 149 149 #include "PGMAllBth.h" 150 150 #undef BTH_PGMPOOLKIND_PT_FOR_PT … … 159 159 #define PGM_BTH_NAME(name) PGM_BTH_NAME_PAE_PROT(name) 160 160 #define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_PAE_PT_FOR_PHYS 161 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS _PROT161 #define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PDPT_PHYS 162 162 #include "PGMAllBth.h" 163 163 #undef BTH_PGMPOOLKIND_PT_FOR_PT … … 216 216 # define PGM_BTH_NAME(name) PGM_BTH_NAME_AMD64_PROT(name) 217 217 # define BTH_PGMPOOLKIND_PT_FOR_PT PGMPOOLKIND_PAE_PT_FOR_PHYS 218 # define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PD_PHYS _PROT218 # define BTH_PGMPOOLKIND_ROOT PGMPOOLKIND_PAE_PD_PHYS 219 219 # include "PGMAllBth.h" 220 220 # undef BTH_PGMPOOLKIND_PT_FOR_PT … … 877 877 PPGMPOOL pPool = pVM->pgm.s.CTX_SUFF(pPool); 878 878 bool fNestedPaging = HWACCMIsNestedPagingActive(pVM); 879 bool fPaging = !!(CPUMGetGuestCR0(pVM) & X86_CR0_PG); 879 880 PPGMPOOLPAGE pShwPage; 880 881 int rc; … … 893 894 else 894 895 { 895 /* AMD-V nested paging . (Intel EPT never comes here)*/896 /* AMD-V nested paging or real/protected mode without paging */ 896 897 RTGCPTR64 GCPdPt = (RTGCPTR64)iPdPt << EPT_PDPT_SHIFT; 897 898 898 rc = pgmPoolAlloc(pVM, GCPdPt + RT_BIT_64(62) /* hack: make the address unique */, PGMPOOLKIND_PAE_PD_PHYS _PROT, pVM->pgm.s.CTX_SUFF(pShwPageCR3)->idx, iPdPt, &pShwPage);899 rc = pgmPoolAlloc(pVM, GCPdPt + RT_BIT_64(62) /* hack: make the address unique */, PGMPOOLKIND_PAE_PD_PHYS, pVM->pgm.s.CTX_SUFF(pShwPageCR3)->idx, iPdPt, &pShwPage); 899 900 } 900 901 -
trunk/src/VBox/VMM/VMMAll/PGMAllPool.cpp
r16427 r16428 1278 1278 case PGMPOOLKIND_EPT_PD_FOR_PHYS: 1279 1279 case PGMPOOLKIND_EPT_PT_FOR_PHYS: 1280 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 1281 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 1282 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 1283 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 1284 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 1285 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 1280 case PGMPOOLKIND_PAE_PD_PHYS: 1281 case PGMPOOLKIND_PAE_PDPT_PHYS: 1282 case PGMPOOLKIND_32BIT_PD_PHYS: 1286 1283 return true; 1287 1284 … … 1572 1569 case PGMPOOLKIND_EPT_PT_FOR_PHYS: 1573 1570 case PGMPOOLKIND_ROOT_NESTED: 1574 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 1575 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 1576 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 1577 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 1578 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 1579 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 1571 case PGMPOOLKIND_PAE_PD_PHYS: 1572 case PGMPOOLKIND_PAE_PDPT_PHYS: 1573 case PGMPOOLKIND_32BIT_PD_PHYS: 1580 1574 break; 1581 1575 default: … … 1640 1634 1641 1635 #ifdef VBOX_WITH_PGMPOOL_PAGING_ONLY 1642 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 1643 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 1644 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 1645 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 1646 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 1647 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 1636 case PGMPOOLKIND_32BIT_PD_PHYS: 1637 case PGMPOOLKIND_PAE_PDPT_PHYS: 1638 case PGMPOOLKIND_PAE_PD_PHYS: 1648 1639 /* Nothing to monitor here. */ 1649 1640 return VINF_SUCCESS; … … 1740 1731 case PGMPOOLKIND_EPT_PT_FOR_PHYS: 1741 1732 case PGMPOOLKIND_ROOT_NESTED: 1742 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 1743 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 1744 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 1745 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 1746 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 1747 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 1733 case PGMPOOLKIND_PAE_PD_PHYS: 1734 case PGMPOOLKIND_PAE_PDPT_PHYS: 1735 case PGMPOOLKIND_32BIT_PD_PHYS: 1748 1736 /* Nothing to monitor here. */ 1749 1737 return VINF_SUCCESS; … … 2462 2450 #ifdef VBOX_WITH_PGMPOOL_PAGING_ONLY 2463 2451 case PGMPOOLKIND_32BIT_PD: 2464 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 2465 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 2452 case PGMPOOLKIND_32BIT_PD_PHYS: 2466 2453 #else 2467 2454 case PGMPOOLKIND_ROOT_32BIT_PD: … … 2490 2477 case PGMPOOLKIND_EPT_PD_FOR_PHYS: 2491 2478 case PGMPOOLKIND_EPT_PT_FOR_PHYS: 2492 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 2493 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 2494 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 2495 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 2479 case PGMPOOLKIND_PAE_PD_PHYS: 2480 case PGMPOOLKIND_PAE_PDPT_PHYS: 2496 2481 return 8; 2497 2482 … … 2549 2534 case PGMPOOLKIND_EPT_PT_FOR_PHYS: 2550 2535 case PGMPOOLKIND_ROOT_NESTED: 2551 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 2552 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 2553 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 2554 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 2555 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 2556 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 2536 case PGMPOOLKIND_PAE_PD_PHYS: 2537 case PGMPOOLKIND_PAE_PDPT_PHYS: 2538 case PGMPOOLKIND_32BIT_PD_PHYS: 2557 2539 /** @todo can we return 0? (nobody is calling this...) */ 2558 2540 AssertFailed(); … … 2888 2870 # ifdef VBOX_WITH_PGMPOOL_PAGING_ONLY 2889 2871 case PGMPOOLKIND_32BIT_PD: 2890 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 2891 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 2872 case PGMPOOLKIND_32BIT_PD_PHYS: 2892 2873 Assert(iUserTable < X86_PG_ENTRIES); 2893 2874 break; … … 2906 2887 # ifdef VBOX_WITH_PGMPOOL_PAGING_ONLY 2907 2888 case PGMPOOLKIND_PAE_PDPT: 2908 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 2909 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 2889 case PGMPOOLKIND_PAE_PDPT_PHYS: 2910 2890 # else 2911 2891 case PGMPOOLKIND_ROOT_PDPT: … … 2916 2896 case PGMPOOLKIND_PAE_PD_FOR_32BIT_PD: 2917 2897 case PGMPOOLKIND_PAE_PD_FOR_PAE_PD: 2918 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 2919 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 2898 case PGMPOOLKIND_PAE_PD_PHYS: 2920 2899 Assert(iUserTable < X86_PG_PAE_ENTRIES); 2921 2900 break; … … 2960 2939 #ifdef VBOX_WITH_PGMPOOL_PAGING_ONLY 2961 2940 case PGMPOOLKIND_32BIT_PD: 2962 case PGMPOOLKIND_32BIT_PD_PHYS_REAL: 2963 case PGMPOOLKIND_32BIT_PD_PHYS_PROT: 2941 case PGMPOOLKIND_32BIT_PD_PHYS: 2964 2942 #else 2965 2943 case PGMPOOLKIND_ROOT_32BIT_PD: … … 2971 2949 case PGMPOOLKIND_PAE_PD_FOR_32BIT_PD: 2972 2950 case PGMPOOLKIND_PAE_PD_FOR_PAE_PD: 2973 case PGMPOOLKIND_PAE_PD_PHYS_PROT: 2974 case PGMPOOLKIND_PAE_PD_PHYS_REAL: 2975 case PGMPOOLKIND_PAE_PDPT_PHYS_REAL: 2976 case PGMPOOLKIND_PAE_PDPT_PHYS_PROT: 2951 case PGMPOOLKIND_PAE_PD_PHYS: 2952 case PGMPOOLKIND_PAE_PDPT_PHYS: 2977 2953 case PGMPOOLKIND_64BIT_PD_FOR_64BIT_PD: 2978 2954 case PGMPOOLKIND_64BIT_PDPT_FOR_64BIT_PDPT:
Note:
See TracChangeset
for help on using the changeset viewer.