Changeset 50008 in vbox for trunk/src/VBox/HostDrivers
- Timestamp:
- Dec 27, 2013 2:20:34 PM (11 years ago)
- Location:
- trunk/src/VBox/HostDrivers/Support
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostDrivers/Support/SUPDrv.c
r49965 r50008 4461 4461 supdrvLdrUnsetVMMR0EPs(pDevExt); 4462 4462 } 4463 SUPR0Printf("vboxdrv: %p %s\n", pImage->pvImage, pImage->szName); 4463 4464 4464 4465 if (RT_FAILURE(rc)) -
trunk/src/VBox/HostDrivers/Support/linux/Makefile
r49395 r50008 276 276 #KFLAGS += -DIPRT_DEBUG_SEMS 277 277 endif 278 ifdef VBOX_WITH_TEXT_MODMEM_HACK 279 KFLAGS += -DRTMEMALLOC_EXEC_HEAP -DVBOX_WITH_TEXT_MODMEM_HACK 280 endif 278 281 279 282 # 2.6 and later -
trunk/src/VBox/HostDrivers/Support/linux/SUPDrv-linux.c
r49767 r50008 153 153 #define DEVICE_NAME_USR "vboxdrvu" 154 154 155 #if defined(RT_ARCH_AMD64) && LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23)155 #if (defined(RT_ARCH_AMD64) && LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23)) || defined(VBOX_WITH_TEXT_MODMEM_HACK) 156 156 /** 157 157 * Memory for the executable memory heap (in IPRT). 158 158 */ 159 extern uint8_t g_abExecMemory[1572864]; /* 1.5 MB */ 159 # ifdef DEBUG 160 # define EXEC_MEMORY_SIZE 6291456 /* 6 MB */ 161 # else 162 # define EXEC_MEMORY_SIZE 1572864 /* 1.5 MB */ 163 # endif 164 extern uint8_t g_abExecMemory[EXEC_MEMORY_SIZE]; 165 # ifndef VBOX_WITH_TEXT_MODMEM_HACK 160 166 __asm__(".section execmemory, \"awx\", @progbits\n\t" 161 167 ".align 32\n\t" 162 168 ".globl g_abExecMemory\n" 163 169 "g_abExecMemory:\n\t" 164 ".zero 1572864\n\t"170 ".zero " RT_XSTR(EXEC_MEMORY_SIZE) "\n\t" 165 171 ".type g_abExecMemory, @object\n\t" 166 ".size g_abExecMemory, 1572864\n\t"172 ".size g_abExecMemory, " RT_XSTR(EXEC_MEMORY_SIZE) "\n\t" 167 173 ".text\n\t"); 174 # else 175 __asm__(".text\n\t" 176 ".align 4096\n\t" 177 ".globl g_abExecMemory\n" 178 "g_abExecMemory:\n\t" 179 ".zero " RT_XSTR(EXEC_MEMORY_SIZE) "\n\t" 180 ".type g_abExecMemory, @object\n\t" 181 ".size g_abExecMemory, " RT_XSTR(EXEC_MEMORY_SIZE) "\n\t" 182 ".text\n\t"); 183 # endif 168 184 #endif 169 185 … … 377 393 if (RT_SUCCESS(rc)) 378 394 { 379 #if defined(RT_ARCH_AMD64) && LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23) 395 #if (defined(RT_ARCH_AMD64) && LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23)) || defined(VBOX_WITH_TEXT_MODMEM_HACK) 396 # ifdef VBOX_WITH_TEXT_MODMEM_HACK 397 set_memory_x(&g_abExecMemory[0], sizeof(g_abExecMemory) / PAGE_SIZE); 398 set_memory_rw(&g_abExecMemory[0], sizeof(g_abExecMemory) / PAGE_SIZE); 399 # endif 380 400 rc = RTR0MemExecDonate(&g_abExecMemory[0], sizeof(g_abExecMemory)); 381 401 printk(KERN_DEBUG "VBoxDrv: dbg - g_abExecMemory=%p\n", (void *)&g_abExecMemory[0]);
Note:
See TracChangeset
for help on using the changeset viewer.