Changeset 8318 in vbox for trunk/src/VBox/Additions/common
- Timestamp:
- Apr 23, 2008 8:56:36 AM (17 years ago)
- svn:sync-xref-src-repo-rev:
- 30080
- Location:
- trunk/src/VBox/Additions/common/VBoxGuest
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest-solaris.c
r8155 r8318 35 35 36 36 #include "VBoxGuestInternal.h" 37 #include <VBox/VBoxDev.h> /* for VMMDEV_GUEST_SUPPORTS_GRAPHICS */ 37 38 #include <VBox/log.h> 38 39 #include <iprt/assert.h> … … 331 332 if (RT_SUCCESS(rc)) 332 333 { 333 rc = ddi_create_minor_node(pDip, DEVICE_NAME, S_IFCHR, instance, DDI_PSEUDO, 0); 334 if (rc == DDI_SUCCESS) 334 /* 335 * Disable graphics capability explicitly for Solaris guests. 336 */ 337 rc = VBoxGuestSetGuestCapabilities(0, VMMDEV_GUEST_SUPPORTS_GRAPHICS); 338 if (RT_SUCCESS(rc)) 335 339 { 336 g_pDip = pDip; 337 ddi_set_driver_private(pDip, pState); 338 pci_config_teardown(&PciHandle); 339 ddi_report_dev(pDip); 340 return DDI_SUCCESS; 340 rc = ddi_create_minor_node(pDip, DEVICE_NAME, S_IFCHR, instance, DDI_PSEUDO, 0); 341 if (rc == DDI_SUCCESS) 342 { 343 g_pDip = pDip; 344 ddi_set_driver_private(pDip, pState); 345 pci_config_teardown(&PciHandle); 346 ddi_report_dev(pDip); 347 return DDI_SUCCESS; 348 } 349 350 LogRel((DEVICE_NAME ":ddi_create_minor_node failed.\n")); 341 351 } 342 343 LogRel((DEVICE_NAME ":ddi_create_minor_node failed.\n"));352 else 353 LogRel((DEVICE_NAME ":VBoxGuestSetGuestCapabilities failed. rc=%d\n", rc)); 344 354 } 345 355 else -
trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest.cpp
r8155 r8318 518 518 VBoxGuestWaitFreeLocked(pDevExt, pWait); 519 519 RTSpinlockReleaseNoInts(pDevExt->WaitSpinlock, &Tmp); 520 } 521 522 523 /** @todo XXX: This should later be done as a proper IOCtl request. Currently we call this from Ring-0. */ 524 int VBoxGuestSetGuestCapabilities(uint32_t u32OrMask, uint32_t u32NotMask) 525 { 526 int rc; 527 VMMDevReqGuestCapabilities2 *pReq; 528 rc = VbglGRAlloc((VMMDevRequestHeader **)&pReq, sizeof(*pReq), VMMDevReq_SetGuestCapabilities); 529 if (RT_FAILURE(rc)) 530 { 531 Log(("VBoxGuestSetGuestCapabilities: failed to allocate %u (%#x) bytes to cache the request. rc=%d!!\n", 532 sizeof(*pReq), sizeof(*pReq), rc)); 533 return rc; 534 } 535 536 pReq->u32OrMask = u32OrMask; 537 pReq->u32NotMask = u32NotMask; 538 539 rc = VbglGRPerform(&pReq->header); 540 if (RT_FAILURE(rc)) 541 Log(("VBoxGuestSetGuestCapabilities:VbglGRPerform failed, rc=%Rrc!\n", rc)); 542 else if (RT_FAILURE(pReq->header.rc)) 543 { 544 Log(("VBoxGuestSetGuestCapabilities: The request failed; VMMDev rc=%Rrc!\n", pReq->header.rc)); 545 rc = pReq->header.rc; 546 } 547 548 VbglGRFree(&pReq->header); 549 return rc; 520 550 } 521 551 -
trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuestInternal.h
r8155 r8318 152 152 void VBoxGuestDeleteDevExt(PVBOXGUESTDEVEXT pDevExt); 153 153 bool VBoxGuestCommonISR(PVBOXGUESTDEVEXT pDevExt); 154 int VBoxGuestSetGuestCapabilities(uint32_t u32OrMask, uint32_t u32NotMask); 154 155 155 156 int VBoxGuestCreateUserSession(PVBOXGUESTDEVEXT pDevExt, PVBOXGUESTSESSION *ppSession);
Note:
See TracChangeset
for help on using the changeset viewer.