VirtualBox

Changeset 6397 in vbox


Ignore:
Timestamp:
Jan 21, 2008 7:26:27 AM (17 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
27346
Message:

vboxadd and clipboard cleanups.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest-solaris.c

    r6354 r6397  
    140140typedef struct
    141141{
    142     /** PCI handle of VMMDev. */
    143     ddi_acc_handle_t        PciHandle;
    144142    /** IO port handle. */
    145143    ddi_acc_handle_t        PciIOHandle;
     
    281279                 * Enable resources for PCI access.
    282280                 */
    283                 rc = pci_config_setup(pDip, &pState->PciHandle);
     281                ddi_acc_handle_t PciHandle;
     282                rc = pci_config_setup(pDip, &PciHandle);
    284283                if (rc == DDI_SUCCESS)
    285284                {
     
    287286                     * Check vendor and device ID.
    288287                     */
    289                     uint16_t uVendorID = pci_config_get16(pState->PciHandle, PCI_CONF_VENID);
    290                     uint16_t uDeviceID = pci_config_get16(pState->PciHandle, PCI_CONF_DEVID);
     288                    uint16_t uVendorID = pci_config_get16(PciHandle, PCI_CONF_VENID);
     289                    uint16_t uDeviceID = pci_config_get16(PciHandle, PCI_CONF_DEVID);
    291290                    if (   uVendorID == VMMDEV_VENDORID
    292291                        && uDeviceID == VMMDEV_DEVICEID)
     
    295294                         * Verify PCI class of the device (a bit paranoid).
    296295                         */
    297                         uint8_t uClass = pci_config_get8(pState->PciHandle, PCI_CONF_BASCLASS);
    298                         uint8_t uSubClass = pci_config_get8(pState->PciHandle, PCI_CONF_SUBCLASS);
     296                        uint8_t uClass = pci_config_get8(PciHandle, PCI_CONF_BASCLASS);
     297                        uint8_t uSubClass = pci_config_get8(PciHandle, PCI_CONF_SUBCLASS);
    299298                        if (   uClass == PCI_CLASS_PERIPH
    300299                            && uSubClass == PCI_PERIPH_OTHER)
     
    341340                                                    g_pDip = pDip;
    342341                                                    ddi_set_driver_private(pDip, pState);
    343                                                     pci_config_teardown(&pState->PciHandle);
     342                                                    pci_config_teardown(&PciHandle);
    344343                                                    ddi_report_dev(pDip);
    345344                                                    return DDI_SUCCESS;
     
    371370                    else
    372371                        Log((DEVICE_NAME ":PCI vendorID, deviceID does not match.\n"));
    373                     pci_config_teardown(&pState->PciHandle);
     372                    pci_config_teardown(&PciHandle);
    374373                }
    375374                else
     
    663662}
    664663
    665 /** @def IOCPARM_LEN
    666  * Gets the length from the ioctl number.
    667  * This is normally defined by sys/ioccom.h on BSD systems...
    668  */
    669 #ifndef IOCPARM_LEN
    670 # define IOCPARM_LEN(x)     ( ((x) >> 16) & IOCPARM_MASK )
    671 #endif
    672664
    673665/**
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette