diff -urN vbox-clean-bk\src\VBox\HostDrivers/Support/Makefile.kmk vbox-clean\src\VBox\HostDrivers/Support/Makefile.kmk
|
old
|
new
|
|
| 519 | 519 | SUPDrv.cpp \ |
| 520 | 520 | SUPDrvGip.cpp \ |
| 521 | 521 | SUPDrvSem.cpp \ |
| 522 | | SUPLibAll.cpp |
| | 522 | SUPLibAll.cpp \ |
| | 523 | SUPDrvTracerA.asm \ |
| | 524 | SUPDrvTracer.cpp |
| 523 | 525 | |
| 524 | 526 | endif # os2 |
| 525 | 527 | |
diff -urN vbox-clean-bk\src\VBox\HostDrivers/Support/os2/SUPDrv-os2.cpp vbox-clean\src\VBox\HostDrivers/Support/os2/SUPDrv-os2.cpp
|
old
|
new
|
|
| 221 | 221 | /* |
| 222 | 222 | * Close the session. |
| 223 | 223 | */ |
| 224 | | supdrvSessionRelease(pSession); |
| | 224 | if (pSession) |
| | 225 | supdrvSessionRelease(pSession); |
| | 226 | |
| 225 | 227 | return 0; |
| 226 | 228 | } |
| 227 | 229 | |
| … |
… |
|
| 244 | 246 | && ( pSession->sfn != sfn |
| 245 | 247 | || pSession->Process != Process)); |
| 246 | 248 | |
| 247 | | if (RT_LIKELY(pSession)) |
| 248 | | supdrvSessionRetain(pSession); |
| 249 | 249 | } |
| 250 | 250 | RTSpinlockRelease(g_Spinlock); |
| 251 | | if (RT_UNLIKELY(!pSession)) |
| | 251 | if (!pSession) |
| 252 | 252 | { |
| 253 | 253 | OSDBGPRINT(("VBoxDrvIoctl: WHUT?!? pSession == NULL! This must be a mistake... pid=%d\n", (int)Process)); |
| 254 | 254 | return VERR_INVALID_PARAMETER; |
| … |
… |
|
| 258 | 258 | * Dispatch the fast IOCtl. |
| 259 | 259 | */ |
| 260 | 260 | supdrvIOCtlFast(iFunction, 0, &g_DevExt, pSession); |
| 261 | | supdrvSessionRelease(pSession); |
| 262 | 261 | return 0; |
| 263 | 262 | } |
| 264 | 263 | |
| … |
… |
|
| 271 | 270 | const RTPROCESS Process = RTProcSelf(); |
| 272 | 271 | const unsigned iHash = SESSION_HASH(sfn); |
| 273 | 272 | PSUPDRVSESSION pSession; |
| | 273 | int rc = 0; |
| 274 | 274 | |
| 275 | 275 | RTSpinlockAcquire(g_Spinlock); |
| 276 | 276 | pSession = g_apSessionHashTab[iHash]; |
| … |
… |
|
| 280 | 280 | while ( pSession |
| 281 | 281 | && ( pSession->sfn != sfn |
| 282 | 282 | || pSession->Process != Process)); |
| 283 | | |
| 284 | | if (RT_LIKELY(pSession)) |
| 285 | | supdrvSessionRetain(pSession); |
| 286 | 283 | } |
| 287 | 284 | RTSpinlockRelease(g_Spinlock); |
| 288 | 285 | if (!pSession) |
| … |
… |
|
| 306 | 303 | PSUPREQHDR pHdr = (PSUPREQHDR)pvParm; |
| 307 | 304 | AssertReturn(*pcbParm == sizeof(*pHdr), VERR_INVALID_PARAMETER); |
| 308 | 305 | KernVMLock_t Lock; |
| 309 | | int rc = KernVMLock(VMDHL_WRITE, pHdr, *pcbParm, &Lock, (KernPageList_t *)-1, NULL); |
| | 306 | rc = KernVMLock(VMDHL_WRITE, pHdr, *pcbParm, &Lock, (KernPageList_t *)-1, NULL); |
| 310 | 307 | AssertMsgReturn(!rc, ("KernVMLock(VMDHL_WRITE, %p, %#x, &p, NULL, NULL) -> %d\n", pHdr, *pcbParm, &Lock, rc), VERR_LOCK_FAILED); |
| 311 | 308 | |
| 312 | 309 | /* |
| … |
… |
|
| 352 | 349 | * Unlock and return. |
| 353 | 350 | */ |
| 354 | 351 | int rc2 = KernVMUnlock(&Lock); |
| 355 | | AssertMsg(!rc2, ("rc2=%d\n", rc2)); NOREF(rc2);s |
| | 352 | AssertMsg(!rc2, ("rc2=%d\n", rc2)); NOREF(rc2); |
| 356 | 353 | } |
| 357 | 354 | else |
| 358 | 355 | rc = VERR_NOT_SUPPORTED; |
| 359 | 356 | |
| 360 | | supdrvSessionRelease(pSession); |
| 361 | 357 | Log2(("VBoxDrvIOCtl: returns %d\n", rc)); |
| 362 | 358 | return rc; |
| 363 | 359 | } |
| … |
… |
|
| 414 | 410 | |
| 415 | 411 | bool VBOXCALL supdrvOSAreTscDeltasInSync(void) |
| 416 | 412 | { |
| 417 | | NOREF(pDevExt); |
| | 413 | // NOREF(pDevExt); |
| 418 | 414 | return false; |
| 419 | 415 | } |
| 420 | 416 | |
diff -urN vbox-clean-bk\src\VBox\HostDrivers/Support/os2/SUPLib-os2.cpp vbox-clean\src\VBox\HostDrivers/Support/os2/SUPLib-os2.cpp
|
old
|
new
|
|
| 150 | 150 | int suplibOsIOCtlFast(PSUPLIBDATA pThis, uintptr_t uFunction, uintptr_t idCpu) |
| 151 | 151 | { |
| 152 | 152 | NOREF(idCpu); |
| 153 | | int32_t rcRet = VERR_INTERNAL_ERROR; |
| 154 | 153 | int rc = DosDevIOCtl((HFILE)pThis->hDevice, SUP_CTL_CATEGORY_FAST, uFunction, |
| 155 | 154 | NULL, 0, NULL, |
| 156 | 155 | NULL, 0, NULL); |
| 157 | | if (RT_LIKELY(rc == NO_ERROR)) |
| 158 | | rc = rcRet; |
| 159 | | else |
| 160 | | rc = RTErrConvertFromOS2(rc); |
| 161 | | return rc; |
| | 156 | |
| | 157 | return rc = RTErrConvertFromOS2(rc); |
| 162 | 158 | } |
| 163 | 159 | |
| 164 | 160 | |
diff -urN vbox-clean-bk\src\VBox\HostDrivers/Support/SUPDrv.cpp vbox-clean\src\VBox\HostDrivers/Support/SUPDrv.cpp
|
old
|
new
|
|
| 571 | 571 | g_aFunctions[2].pfn = (void *)(uintptr_t)ASMGetSS(); /* SUPR0Abs64bitKernelSS */ |
| 572 | 572 | g_aFunctions[3].pfn = (void *)(uintptr_t)ASMGetDS(); /* SUPR0Abs64bitKernelDS */ |
| 573 | 573 | # else |
| 574 | | g_aFunctions[0].pfn = g_aFunctions[1].pfn = g_aFunctions[2].pfn = g_aFunctions[4].pfn = (void *)0; |
| | 574 | g_aFunctions[0].pfn = g_aFunctions[1].pfn = g_aFunctions[2].pfn = g_aFunctions[3].pfn = (void *)0; |
| 575 | 575 | # endif |
| 576 | 576 | g_aFunctions[4].pfn = (void *)(uintptr_t)ASMGetCS(); /* SUPR0AbsKernelCS */ |
| 577 | 577 | g_aFunctions[5].pfn = (void *)(uintptr_t)ASMGetSS(); /* SUPR0AbsKernelSS */ |
diff -urN vbox-clean-bk\src\VBox\HostDrivers/Support/SUPR3HardenedVerify.cpp vbox-clean\src\VBox\HostDrivers/Support/SUPR3HardenedVerify.cpp
|
old
|
new
|
|
| 126 | 126 | { kSupIFT_Dll, kSupID_AppSharedLib, false, "VBoxVMM" SUPLIB_DLL_SUFF }, |
| 127 | 127 | { kSupIFT_Dll, kSupID_AppSharedLib, false, "VBoxREM" SUPLIB_DLL_SUFF }, |
| 128 | 128 | #if HC_ARCH_BITS == 32 |
| | 129 | #ifndef RT_OS_OS2 |
| 129 | 130 | { kSupIFT_Dll, kSupID_AppSharedLib, true, "VBoxREM32" SUPLIB_DLL_SUFF }, |
| 130 | 131 | { kSupIFT_Dll, kSupID_AppSharedLib, true, "VBoxREM64" SUPLIB_DLL_SUFF }, |
| | 132 | #else |
| | 133 | { kSupIFT_Dll, kSupID_AppSharedLib, true, "VBoxRM32" SUPLIB_DLL_SUFF }, |
| | 134 | { kSupIFT_Dll, kSupID_AppSharedLib, true, "VBoxRM64" SUPLIB_DLL_SUFF }, |
| | 135 | #endif |
| 131 | 136 | #endif |
| 132 | 137 | { kSupIFT_Dll, kSupID_AppSharedLib, false, "VBoxDD" SUPLIB_DLL_SUFF }, |
| 133 | 138 | { kSupIFT_Dll, kSupID_AppSharedLib, false, "VBoxDD2" SUPLIB_DLL_SUFF }, |
| … |
… |
|
| 148 | 153 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxDragAndDropSvc" SUPLIB_DLL_SUFF }, |
| 149 | 154 | //#endif |
| 150 | 155 | //#ifdef VBOX_WITH_GUEST_PROPS |
| | 156 | #ifndef RT_OS_OS2 |
| 151 | 157 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxGuestPropSvc" SUPLIB_DLL_SUFF }, |
| | 158 | #else |
| | 159 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxSIS" SUPLIB_DLL_SUFF }, |
| | 160 | #endif |
| 152 | 161 | //#endif |
| 153 | 162 | //#ifdef VBOX_WITH_GUEST_CONTROL |
| 154 | 163 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxGuestControlSvc" SUPLIB_DLL_SUFF }, |
| 155 | 164 | //#endif |
| | 165 | #ifndef RT_OS_OS2 |
| 156 | 166 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxHostChannel" SUPLIB_DLL_SUFF }, |
| | 167 | #else |
| | 168 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxHC" SUPLIB_DLL_SUFF }, |
| | 169 | #endif |
| 157 | 170 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxSharedCrOpenGL" SUPLIB_DLL_SUFF }, |
| 158 | 171 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxOGLhostcrutil" SUPLIB_DLL_SUFF }, |
| 159 | 172 | { kSupIFT_Dll, kSupID_AppPrivArch, true, "VBoxOGLhosterrorspu" SUPLIB_DLL_SUFF }, |