Changeset 82898 in vbox for trunk/src/VBox/Runtime/r0drv
- Timestamp:
- Jan 29, 2020 12:56:30 AM (5 years ago)
- Location:
- trunk/src/VBox/Runtime/r0drv/darwin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r0drv/darwin/memobj-r0drv-darwin.cpp
r82886 r82898 486 486 IOOptionBits fOptions = kIOMemoryKernelUserShared | kIODirectionInOut; 487 487 if (fContiguous) 488 { 488 489 fOptions |= kIOMemoryPhysicallyContiguous; 490 if ( version_major > 12 491 || (version_major == 12 && version_minor >= 2) /* 10.8.2 = Mountain Kitten */ ) 492 fOptions |= kIOMemoryHostPhysicallyContiguous; /* (Just to make ourselves clear, in case the xnu code changes.) */ 493 } 489 494 if (version_major >= 12 /* 12 = 10.8.x = Mountain Kitten */) 490 495 fOptions |= kIOMemoryMapperNone; … … 498 503 if (version_major >= 11 /* 11 = 10.7.x = Lion, could probably allow 10.5.0+ here if we really wanted to. */) 499 504 { 500 if (fContiguous || MaxPhysAddr < UINT64_MAX) 501 { 502 fOptions |= kIOMemoryPhysicallyContiguous; 503 // cannot find any evidence of this: uAlignmentActual = 1; /* PhysMask isn't respected if higher. */ 505 /* Starting with 10.6.x the physical mask is ignored if alignment is higher 506 than 1. The assumption seems to be that inTaskWithPhysicalMask() should 507 be used and the alignment inferred from the PhysMask argument. */ 508 if (MaxPhysAddr != UINT64_MAX) 509 { 510 Assert(RT_ALIGN_64(PhysMask, uAlignment) == PhysMask); 511 uAlignmentActual = 1; 504 512 } 505 513 -
trunk/src/VBox/Runtime/r0drv/darwin/the-darwin-kernel.h
r76585 r82898 108 108 /* This flag was added in 10.6, it seems. Should be harmless in earlier 109 109 releases... */ 110 #if MAC_OS_X_VERSION_MIN_REQUIRED < 1060110 #if __MAC_OS_X_VERSION_MAX_ALLOWED < 1060 111 111 # define kIOMemoryMapperNone UINT32_C(0x800) 112 #endif 113 114 /* This flag was added in 10.8.2, it seems. */ 115 #if __MAC_OS_X_VERSION_MAX_ALLOWED < 1082 116 # define kIOMemoryHostPhysicallyContiguous UINT32_C(0x00000080) 112 117 #endif 113 118
Note:
See TracChangeset
for help on using the changeset viewer.