Changeset 5525 in vbox
- Timestamp:
- Oct 26, 2007 6:03:37 PM (17 years ago)
- Location:
- trunk
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Config.kmk
r5501 r5525 199 199 # Enable the USB feature. 200 200 VBOX_WITH_USB = 1 201 # Enable the new PDM USB management code (work in progress). 202 VBOX_WITH_PDMUSB = 1 201 203 # Enable the ISCSI feature. 202 204 VBOX_WITH_ISCSI = 1 -
trunk/include/VBox/mm.h
r4688 r5525 43 43 * Normal MMIO may set it but that depends on whether the RAM range was 44 44 * created specially for the MMIO or not. 45 * 46 * @remarks The current implementation will always reserve backing 45 * 46 * @remarks The current implementation will always reserve backing 47 47 * memory for reserved ranges to simplify things. 48 48 */ … … 51 51 * The page have a HC physical address which contains the BIOS code. All write 52 52 * access is trapped and ignored. 53 * 54 * HACK: Writable shadow ROM is indicated by both ROM and MMIO2 being 53 * 54 * HACK: Writable shadow ROM is indicated by both ROM and MMIO2 being 55 55 * set. (We're out of bits.) 56 56 */ … … 108 108 * @{ 109 109 */ 110 typedef enum 110 typedef enum 111 111 { 112 112 /** Normal physical region (flags specify exact page type) */ … … 166 166 MM_TAG_PDM_DRIVER, 167 167 MM_TAG_PDM_DRIVER_USER, 168 MM_TAG_PDM_USB, 169 MM_TAG_PDM_USB_USER, 168 170 MM_TAG_PDM_LUN, 169 171 MM_TAG_PDM_QUEUE, … … 654 656 /** 655 657 * Reset notification. 656 * 657 * MM will reload shadow ROMs into RAM at this point and make 658 * 659 * MM will reload shadow ROMs into RAM at this point and make 658 660 * the ROM writable. 659 * 661 * 660 662 * @param pVM The VM handle. 661 663 */ … … 924 926 * This must be cbRange bytes big. 925 927 * It will be copied and doesn't have to stick around. 926 * It will be copied and doesn't have to stick around if fShadow is clear. 928 * It will be copied and doesn't have to stick around if fShadow is clear. 927 929 * @param fShadow Whether to emulate ROM shadowing. This involves leaving 928 930 * the ROM writable for a while during the POST and refreshing … … 938 940 /** 939 941 * Write-protects a shadow ROM range. 940 * 942 * 941 943 * This is called late in the POST for shadow ROM ranges. 942 * 944 * 943 945 * @returns VBox status code. 944 946 * @param pVM The VM handle. 945 * @param GCPhys Start of the registered shadow ROM range 947 * @param GCPhys Start of the registered shadow ROM range 946 948 * @param cbRange The length of the registered shadow ROM range. 947 949 * This can be NULL (not sure about the BIOS interface yet). -
trunk/include/VBox/pdmdev.h
r5040 r5525 385 385 386 386 /** 387 * PCI Bus regist aration structure.387 * PCI Bus registration structure. 388 388 * All the callbacks, except the PCIBIOS hack, are working on PCI devices. 389 389 */ … … 1791 1791 * @param pvBinary Pointer to the binary data backing the ROM image. 1792 1792 * This must be cbRange bytes big. 1793 * It will be copied and doesn't have to stick around if fShadow is clear. 1793 * It will be copied and doesn't have to stick around if fShadow is clear. 1794 1794 * @param fShadow Whether to emulate ROM shadowing. This involves leaving 1795 1795 * the ROM writable for a while during the POST and refreshing … … 1797 1797 * pvBinary has to stick around for the lifespan of the VM. 1798 1798 * @param pszDesc Pointer to description string. This must not be freed. 1799 * 1799 * 1800 1800 * @remark There is no way to remove the rom, automatically on device cleanup or 1801 1801 * manually from the device yet. At present I doubt we need such features... … … 2178 2178 /** 2179 2179 * Creates a PDM thread. 2180 * 2181 * This differs from the RTThreadCreate() API in that PDM takes care of suspending, 2180 * 2181 * This differs from the RTThreadCreate() API in that PDM takes care of suspending, 2182 2182 * resuming, and destroying the thread as the VM state changes. 2183 * 2183 * 2184 2184 * @returns VBox status code. 2185 2185 * @param pDevIns The device instance. … … 2549 2549 /** 2550 2550 * Write protects a shadow ROM mapping. 2551 * 2552 * This is intented for use by the system BIOS or by the device that 2551 * 2552 * This is intented for use by the system BIOS or by the device that 2553 2553 * employs a shadow ROM BIOS, so that the shadow ROM mapping can be 2554 2554 * write protected once the POST is over. 2555 * 2555 * 2556 2556 * @param pDevIns Device instance. 2557 2557 * @param GCPhysStart Where the shadow ROM mapping starts. -
trunk/include/VBox/pdmdrv.h
r5266 r5525 255 255 256 256 /** 257 * USB hub registration structure. 258 */ 259 typedef struct PDMUSBHUBREG 260 { 261 /** Structure version number. PDM_USBHUBREG_VERSION defines the current version. */ 262 uint32_t u32Version; 263 264 /** 265 * Request the hub to attach of the specified device. 266 * 267 * @returns VBox status code. 268 * @param pDrvIns The hub instance. 269 * @param pUsbIns The device to attach. 270 * @param piPort Where to store the port number the device was attached to. 271 * @thread EMT. 272 */ 273 DECLR3CALLBACKMEMBER(int, pfnAttachDevice,(PPDMDRVINS pDrvIns, PPDMUSBINS pUsbIns, uint32_t *piPort)); 274 275 /** 276 * Request the hub to detach of the specified device. 277 * 278 * The device has previously been attached to the hub with the 279 * pfnAttachDevice call. This call is not currently expected to 280 * fail. 281 * 282 * @returns VBox status code. 283 * @param pDrvIns The hub instance. 284 * @param pUsbIns The device to detach. 285 * @param iPort The port number returned by the attach call. 286 * @thread EMT. 287 */ 288 DECLR3CALLBACKMEMBER(int, pfnDetachDevice,(PPDMDRVINS pDrvIns, PPDMUSBINS pUsbIns, uint32_t iPort)); 289 290 /** Counterpart to u32Version, same value. */ 291 uint32_t u32TheEnd; 292 } PDMUSBHUBREG; 293 /** Pointer to a const USB hub registration structure. */ 294 typedef const PDMUSBHUBREG *PCPDMUSBHUBREG; 295 296 /** Current PDMUSBHUBREG version number. */ 297 #define PDM_USBHUBREG_VERSION 0xeb010000 298 299 300 /** 301 * USB hub helpers. 302 * This is currently just a place holder. 303 */ 304 typedef struct PDMUSBHUBHLP 305 { 306 /** Structure version. PDM_USBHUBHLP_VERSION defines the current version. */ 307 uint32_t u32Version; 308 309 /** Just a safety precaution. */ 310 uint32_t u32TheEnd; 311 } PDMUSBHUBHLP; 312 /** Pointer to PCI helpers. */ 313 typedef PDMUSBHUBHLP *PPDMUSBHUBHLP; 314 /** Pointer to const PCI helpers. */ 315 typedef const PDMUSBHUBHLP *PCPDMUSBHUBHLP; 316 /** Pointer to const PCI helpers pointer. */ 317 typedef PCPDMUSBHUBHLP *PPCPDMUSBHUBHLP; 318 319 /** Current PDMUSBHUBHLP version number. */ 320 #define PDM_USBHUBHLP_VERSION 0xea010000 321 322 323 324 /** 257 325 * Poller callback. 258 326 * … … 546 614 * @returns VBox status code. 547 615 * @param pDrvIns The driver instance. 548 * @param pvReserved Reserved for future inteface callback structure. 549 * @param ppvReservedHlp Reserved for future helper callback structure. 616 * @param fVersions Indicates the kinds of USB devices that can be attached to this HUB. 617 * @param cPorts The number of ports. 618 * @param pUsbHubReg The hub callback structure that PDMUsb uses to interact with it. 619 * @param ppUsbHubHlp The helper callback structure that the hub uses to talk to PDMUsb. 550 620 * 551 621 * @thread EMT. 552 622 */ 553 DECLR3CALLBACKMEMBER(int, pfnUSBRegisterHub,(PPDMDRVINS pDrvIns, void *pvReservedIn, void **ppvReservedHlp));623 DECLR3CALLBACKMEMBER(int, pfnUSBRegisterHub,(PPDMDRVINS pDrvIns, uint32_t fVersions, uint32_t cPorts, PCPDMUSBHUBREG pUsbHubReg, PPCPDMUSBHUBHLP ppUsbHubHlp)); 554 624 555 625 /** … … 716 786 * @copydoc PDMDRVHLP::pfnUSBRegisterHub 717 787 */ 718 DECLINLINE(int) PDMDrvHlpUSBRegisterHub(PPDMDRVINS pDrvIns, void *pvReservedIn, void **ppvReservedHlp)719 { 720 return pDrvIns->pDrvHlp->pfnUSBRegisterHub(pDrvIns, pvReservedIn, ppvReservedHlp);788 DECLINLINE(int) PDMDrvHlpUSBRegisterHub(PPDMDRVINS pDrvIns, uint32_t fVersions, uint32_t cPorts, PCPDMUSBHUBREG pUsbHubReg, PPCPDMUSBHUBHLP ppUsbHubHlp) 789 { 790 return pDrvIns->pDrvHlp->pfnUSBRegisterHub(pDrvIns, fVersions, cPorts, pUsbHubReg, ppUsbHubHlp); 721 791 } 722 792 -
trunk/include/VBox/pdmusb.h
r4071 r5525 99 99 * complicated failure paths. 100 100 * 101 * @returns VBox status. 102 * @param pUsbIns The USB device instance data. 103 * @remarks Optional. 104 */ 105 DECLR3CALLBACKMEMBER(int, pfnDestruct,(PPDMUSBINS pUsbIns)); 101 * @param pUsbIns The USB device instance data. 102 * @remarks Optional. 103 */ 104 DECLR3CALLBACKMEMBER(void, pfnDestruct,(PPDMUSBINS pUsbIns)); 106 105 107 106 /** … … 435 434 /** Pointer to device instance data. */ 436 435 R3PTRTYPE(void *) pvInstanceDataR3; 437 /* padding to make achInstanceData aligned at 32 byte boundrary. */ 438 uint32_t au32Padding[HC_ARCH_BITS == 32 ? 4 : 6]; 436 /** Pointer to the VUSB Device structure. 437 * The constructor sets this. 438 * @todo Integrate VUSBDEV into this structure. */ 439 R3PTRTYPE(void *) pvVUsbDev; 440 /** Padding to make achInstanceData aligned at 32 byte boundrary. */ 441 uint32_t au32Padding[HC_ARCH_BITS == 32 ? 3 : 4]; 439 442 /** Device instance data. The size of this area is defined 440 443 * in the PDMUSBREG::cbInstanceData field. */ … … 561 564 typedef DECLCALLBACK(int) FNPDMVBOXUSBREGISTER(PCPDMUSBREGCB pCallbacks, uint32_t u32Version); 562 565 566 567 /** 568 * Creates a USB proxy device instance. 569 * 570 * This will find an appropriate HUB for the USB device, create the necessary CFGM stuff 571 * and try instantiate the proxy device. 572 * 573 * @returns VBox status code. 574 * @param pVM The VM handle. 575 * @param pUuid The UUID thats to be associated with the device. 576 * @param fRemote Whether it's a remove or local device. 577 * @param pszAddress The address string. 578 * @param pvBackend Pointer to the backend. 579 * @param iUsbVersion The preferred USB version. 580 */ 581 PDMR3DECL(int) PDMR3USBCreateProxyDevice(PVM pVM, PCRTUUID pUuid, bool fRemote, const char *pszAddress, void *pvBackend, uint32_t iUsbVersion); 582 583 /** 584 * Detaches and destroys a USB device. 585 * 586 * @returns VBox status code. 587 * @param pVM The VM handle. 588 * @param pUuid The UUID associated with the device to detach. 589 * @thread EMT 590 */ 591 PDMR3DECL(int) PDMR3USBDetachDevice(PVM pVM, PCRTUUID pUuid); 592 593 /** 594 * Checks if there are any USB hubs attached. 595 * 596 * @returns true / false accordingly. 597 * @param pVM Pointer to the shared VM structure. 598 */ 599 PDMR3DECL(bool) PDMR3USBHasHub(PVM pVM); 600 601 563 602 /** @} */ 564 603 -
trunk/include/VBox/vusb.h
r5515 r5525 30 30 #define VUSB_BUS_HZ 12000000 31 31 32 /** @name USB Standard version flags. 32 /** @name USB Standard version flags. 33 33 * @{ */ 34 /** Indicates USB 1.1 support. */ 35 #define VUSB_STDVER_11 BIT(1) 36 /** Indicates USB 2.0 support. */ 37 #define VUSB_STDVER_20 BIT(2) 38 /** @} */ 39 40 /** @name USB Standard version 41 * @{ */ 42 typedef enum VUSBREVISION 43 { 44 /** Indicates USB 1.1 support. */ 45 VUSBREVISION_11 = 0x10, 46 /** Indicates USB 2.0 support. */ 47 VUSBREVISION_20 = 0x20 48 } VUSBREVISION; 34 /** Indicates USB 1.1 support. */ 35 #define VUSB_STDVER_11 BIT(1) 36 /** Indicates USB 2.0 support. */ 37 #define VUSB_STDVER_20 BIT(2) 49 38 /** @} */ 50 39 … … 58 47 59 48 /** Pointer to an USB request descriptor. */ 60 typedef struct vusb_urb*PVUSBURB;49 typedef struct VUSBURB *PVUSBURB; 61 50 62 51 … … 94 83 95 84 /** 96 * Get the supported USB revision97 * 98 * @returns The supported revision85 * Gets the supported USB versions. 86 * 87 * @returns The mask of supported USB versions. 99 88 * @param pInterface Pointer to this structure. 100 89 */ 101 DECLR3CALLBACKMEMBER( VUSBREVISION, pfnGetRevision,(PVUSBIROOTHUBPORT pInterface));90 DECLR3CALLBACKMEMBER(uint32_t, pfnGetUSBVersions,(PVUSBIROOTHUBPORT pInterface)); 102 91 103 92 /** … … 150 139 */ 151 140 DECLR3CALLBACKMEMBER(bool, pfnXferError,(PVUSBIROOTHUBPORT pInterface, PVUSBURB pUrb)); 141 142 /** Alignment dummy. */ 143 RTR3PTR Alignment; 152 144 153 145 } VUSBIROOTHUBPORT; … … 188 180 * @param pLed Pointer to USB Status LED 189 181 */ 190 DECLR3CALLBACKMEMBER(int, pfnSubmitUrb,(PVUSBIROOTHUBCONNECTOR pInterface, PVUSBURB pUrb, PPDMLEDpLed));182 DECLR3CALLBACKMEMBER(int, pfnSubmitUrb,(PVUSBIROOTHUBCONNECTOR pInterface, PVUSBURB pUrb, struct PDMLED *pLed)); 191 183 192 184 /** … … 245 237 246 238 /** @copydoc VUSBIROOTHUBCONNECTOR::pfnSubmitUrb */ 247 DECLINLINE(int) VUSBIRhSubmitUrb(PVUSBIROOTHUBCONNECTOR pInterface, PVUSBURB pUrb, PPDMLEDpLed)239 DECLINLINE(int) VUSBIRhSubmitUrb(PVUSBIROOTHUBCONNECTOR pInterface, PVUSBURB pUrb, struct PDMLED *pLed) 248 240 { 249 241 return pInterface->pfnSubmitUrb(pInterface, pUrb, pLed); … … 620 612 * Asynchronous USB request descriptor 621 613 */ 622 typedef struct vusb_urb614 typedef struct VUSBURB 623 615 { 624 616 /** URB magic value. */ … … 688 680 /** The device - NULL until a submit has been is attempted. 689 681 * This is set when allocating the URB. */ 690 struct vusb_dev*pDev;682 struct VUSBDEV *pDev; 691 683 /** The device address. 692 684 * This is set at allocation time. */ -
trunk/src/VBox/Devices/Makefile.kmk
r5518 r5525 90 90 ifdef VBOX_WITH_USB 91 91 VBoxDD_DEFS += VBOX_WITH_USB IN_USB_R3 92 ifdef VBOX_WITH_PDMUSB 93 VBoxDD_DEFS += VBOX_WITH_PDMUSB 94 endif 92 95 endif 93 96 ifdef VBOX_WITH_AHCI … … 203 206 ifdef VBOX_WITH_USB 204 207 DevicesR3_DEFS += VBOX_WITH_USB IN_USB_R3 208 ifdef VBOX_WITH_PDMUSB 209 DevicesR3_DEFS += VBOX_WITH_PDMUSB 210 endif 205 211 DevicesR3_SOURCES += \ 206 212 USB/DevOHCI.cpp \ … … 499 505 ifdef VBOX_WITH_USB 500 506 Drivers_DEFS += VBOX_WITH_USB IN_USB_R3 507 ifdef VBOX_WITH_PDMUSB 508 Drivers_DEFS += VBOX_WITH_PDMUSB 509 endif 501 510 Drivers_SOURCES += \ 502 511 USB/DrvVUSBRootHub.cpp \ -
trunk/src/VBox/Devices/testcase/tstDeviceStructSizeGC.cpp
r5516 r5525 797 797 GEN_CHECK_OFF(EHCI, pDevInsGC); 798 798 GEN_CHECK_OFF(EHCI, pLoad); 799 GEN_CHECK_OFF(EHCI, fAsyncTraversalTimerActive); 799 800 # ifdef VBOX_WITH_STATISTICS 800 801 GEN_CHECK_OFF(EHCI, StatCanceledIsocUrbs); -
trunk/src/VBox/Runtime/testcase/tstCritSect.cpp
r4071 r5525 24 24 #endif 25 25 #include <iprt/critsect.h> 26 #include <iprt/lock.h> 26 27 #include <iprt/thread.h> 27 28 #include <iprt/log.h> -
trunk/src/VBox/VMM/MMHeap.cpp
r4688 r5525 596 596 TAG2STR(PDM_DRIVER); 597 597 TAG2STR(PDM_DRIVER_USER); 598 TAG2STR(PDM_USB); 599 TAG2STR(PDM_USB_USER); 598 600 TAG2STR(PDM_LUN); 599 601 TAG2STR(PDM_QUEUE); -
trunk/src/VBox/VMM/PDMDevice.cpp
r5440 r5525 613 613 { 614 614 /* make filename */ 615 char *pszFilename = pdmR3FileR3("VBoxDD", /* fShared=*/true);615 char *pszFilename = pdmR3FileR3("VBoxDD", /* fShared = */ true); 616 616 if (!pszFilename) 617 617 return VERR_NO_TMP_MEMORY; … … 622 622 623 623 /* make filename */ 624 pszFilename = pdmR3FileR3("VBoxDD2", /* fShared=*/true);624 pszFilename = pdmR3FileR3("VBoxDD2", /* fShared = */ true); 625 625 if (!pszFilename) 626 626 return VERR_NO_TMP_MEMORY; … … 2422 2422 int rc = pdmR3ThreadCreateDevice(pDevIns->Internal.s.pVMHC, pDevIns, ppThread, pvUser, pfnThread, pfnWakeup, cbStack, enmType, pszName); 2423 2423 2424 LogFlow(("pdmR3DevHlp_PDMThreadCreate: caller='%s'/%d: returns %Vrc *ppThread=%RTthrd\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, 2424 LogFlow(("pdmR3DevHlp_PDMThreadCreate: caller='%s'/%d: returns %Vrc *ppThread=%RTthrd\n", pDevIns->pDevReg->szDeviceName, pDevIns->iInstance, 2425 2425 rc, *ppThread)); 2426 2426 return rc; -
trunk/src/VBox/VMM/PDMDriver.cpp
r5283 r5525 90 90 static DECLCALLBACK(void) pdmR3DrvHlp_STAMRegisterV(PPDMDRVINS pDrvIns, void *pvSample, STAMTYPE enmType, STAMVISIBILITY enmVisibility, STAMUNIT enmUnit, const char *pszDesc, const char *pszName, va_list args); 91 91 static DECLCALLBACK(int) pdmR3DrvHlp_SUPCallVMMR0Ex(PPDMDRVINS pDrvIns, unsigned uOperation, void *pvArg, unsigned cbArg); 92 static DECLCALLBACK(int) pdmR3DrvHlp_USBRegisterHub(PPDMDRVINS pDrvIns, void *pvReservedIn, void **ppvReservedHlp);92 static DECLCALLBACK(int) pdmR3DrvHlp_USBRegisterHub(PPDMDRVINS pDrvIns, uint32_t fVersions, uint32_t cPorts, PCPDMUSBHUBREG pUsbHubReg, PPCPDMUSBHUBHLP ppUsbHubHlp); 93 93 static DECLCALLBACK(int) pdmR3DrvHlp_PDMThreadCreate(PPDMDRVINS pDrvIns, PPPDMTHREAD ppThread, void *pvUser, PFNPDMTHREADDRV pfnThread, 94 94 PFNPDMTHREADWAKEUPDRV pfnWakeup, size_t cbStack, RTTHREADTYPE enmType, const char *pszName); … … 1004 1004 1005 1005 /** @copydoc PDMDRVHLP::pfnUSBRegisterHub */ 1006 static DECLCALLBACK(int) pdmR3DrvHlp_USBRegisterHub(PPDMDRVINS pDrvIns, void *pvReservedIn, void **ppvReservedHlp) 1007 { 1008 PDMDRV_ASSERT_DRVINS(pDrvIns); 1009 VM_ASSERT_EMT(pDrvIns->Internal.s.pVM); 1010 LogFlow(("pdmR3DrvHlp_USBRegisterHub: caller='%s'/%d: pvReservedIn=%p ppvReservedHlp=%p\n", 1011 pDrvIns->pDrvReg->szDriverName, pDrvIns->iInstance, pvReservedIn, ppvReservedHlp)); 1012 1013 /// @todo int rc = PDMUSBRegisterHub(pDrvIns->Internal.s.pVM, pvReservedIn, ppvReservedHlp); 1014 int rc = VINF_SUCCESS; 1006 static DECLCALLBACK(int) pdmR3DrvHlp_USBRegisterHub(PPDMDRVINS pDrvIns, uint32_t fVersions, uint32_t cPorts, PCPDMUSBHUBREG pUsbHubReg, PPCPDMUSBHUBHLP ppUsbHubHlp) 1007 { 1008 PDMDRV_ASSERT_DRVINS(pDrvIns); 1009 VM_ASSERT_EMT(pDrvIns->Internal.s.pVM); 1010 LogFlow(("pdmR3DrvHlp_USBRegisterHub: caller='%s'/%d: fVersions=%#x cPorts=%#x pUsbHubReg=%p ppUsbHubHlp=%p\n", 1011 pDrvIns->pDrvReg->szDriverName, pDrvIns->iInstance, fVersions, cPorts, pUsbHubReg, ppUsbHubHlp)); 1012 1013 int rc = pdmR3UsbRegisterHub(pDrvIns->Internal.s.pVM, pDrvIns, fVersions, cPorts, pUsbHubReg, ppUsbHubHlp); 1015 1014 1016 1015 LogFlow(("pdmR3DrvHlp_USBRegisterHub: caller='%s'/%d: returns %Vrc\n", pDrvIns->pDrvReg->szDriverName, pDrvIns->iInstance, rc)); -
trunk/src/VBox/VMM/PDMInternal.h
r4787 r5525 24 24 #include <VBox/cfgm.h> 25 25 #include <VBox/stam.h> 26 #include <VBox/vusb.h> 26 27 #include <iprt/critsect.h> 27 28 #ifdef IN_RING3 … … 115 116 typedef struct PDMUSBINSINT 116 117 { 118 /** The UUID of this instance. */ 119 RTUUID Uuid; 117 120 /** Pointer to the next instance. 118 121 * (Head is pointed to by PDM::pUsbInstances.) */ … … 123 126 124 127 /** Pointer to device structure. */ 125 R3PTRTYPE(PPDMUSB) pUsb ;128 R3PTRTYPE(PPDMUSB) pUsbDev; 126 129 127 130 /** Pointer to the VM this instance was created for. */ … … 131 134 /** The per instance device configuration. */ 132 135 R3PTRTYPE(PCFGMNODE) pCfg; 136 /** Same as pCfg if the configuration should be deleted when detaching the device. */ 137 R3PTRTYPE(PCFGMNODE) pCfgDelete; 133 138 /** The global device configuration. */ 134 139 R3PTRTYPE(PCFGMNODE) pCfgGlobal; 135 140 136 /** Pointer to the USB hub this device is connected to. */ 141 /** Pointer to the USB hub this device is attached to. 142 * This is NULL if the device isn't connected to any HUB. */ 137 143 R3PTRTYPE(PPDMUSBHUB) pHub; 138 144 /** The port number that we're connected to. */ … … 726 732 * Note that 1.1 hubs can take on 2.0 devices. */ 727 733 uint32_t fVersions; 728 /** The number of occupied ports. */ 734 /** The number of ports on the hub. */ 735 uint32_t cPorts; 736 /** The number of available ports (0..cPorts). */ 729 737 uint32_t cAvailablePorts; 738 /** The driver instance of the hub. */ 739 PPDMDRVINS pDrvIns; 740 /** Copy of the to the registration structure. */ 741 PDMUSBHUBREG Reg; 742 730 743 /** Pointer to the next hub in the list. */ 731 744 struct PDMUSBHUB *pNext; 732 /** The driver instance of the hub.. */733 PPDMDRVINS pDrvIns;734 735 745 } PDMUSBHUB; 736 746 … … 872 882 PPDMUSB pdmR3UsbLookup(PVM pVM, const char *pszName); 873 883 int pdmR3UsbFindLun(PVM pVM, const char *pszDevice, unsigned iInstance, unsigned iLun, PPDMLUN *ppLun); 884 int pdmR3UsbRegisterHub(PVM pVM, PPDMDRVINS pDrvIns, uint32_t fVersions, uint32_t cPorts, PCPDMUSBHUBREG pUsbHubReg, PPCPDMUSBHUBHLP ppUsbHubHlp); 874 885 875 886 int pdmR3DrvInit(PVM pVM); … … 897 908 int pdmR3ThreadSuspendAll(PVM pVM); 898 909 910 899 911 #endif /* IN_RING3 */ 900 912
Note:
See TracChangeset
for help on using the changeset viewer.