corpnewt / USBMap

Python script for mapping USB ports in macOS and creating a custom injector kext.
MIT License
1.03k stars 88 forks source link

wrong results #24

Closed roddy20 closed 3 years ago

roddy20 commented 3 years ago

Снимок экрана 2021-04-22 в 2 25 52 XHC1 is not detected here

Снимок экрана 2021-04-22 в 2 26 21 but XHCI ports are assigned to USB2

IORegistry.zip

USB are ICH9 and XHCI is FL1100 USBMap.kext.zip

corpnewt commented 3 years ago

Should be fixed in this commit. Thanks for letting me know.

-CorpNewt

roddy20 commented 3 years ago

Thanks seems to be much better now

Снимок экрана 2021-04-26 в 19 14 33

Снимок экрана 2021-04-26 в 19 15 00

roddy20 commented 3 years ago

USBMap.kext.zip USBMapLegacy.kext.zip but two ports are still SS not PRT Снимок экрана 2021-04-26 в 19 22 20

roddy20 commented 3 years ago

Снимок экрана 2021-04-26 в 19 26 10 and there is one more section in original Apple Kext about kUSB* wake and sleep current do we need to add it manually? thanks

corpnewt commented 3 years ago

The names are completely arbitrary. The OS does not interpret them at all. I've used the traditional HSxx and SSxx naming scheme to represent USB 2 and USB 3 personalities respectively on an XHCI controller and PRTx for EHCI, UHCI, and OHCI controllers as seen here. You could rename those entries to BOBx and they would show up in IOReg - the OS doesn't care what they are.

I took your IOReg.txt and ran USBMap.command with it - enabled all ports and generated the USBMap.kext - and the ports are all named correctly (including the same controller listed in your screenshot):

image

USBMap.kext.zip

As for the kUSBxxx values - those are expected to be setup in SSDT-USBX.aml (or SSDT-EC-USBX.aml) - so the values are not needed in the USBMap.kext.

-CorpNewt

roddy20 commented 3 years ago

USB-2021-04-26 19.45.plist.zip I understand..but it is strange USBE is not XHC*

Снимок экрана 2021-04-26 в 19 54 01

corpnewt commented 3 years ago

I'm betting it was some garbage data in the USB.plist from prior mapping when the XHCI controller was improperly skipped. You could try clearing that via R. Reset All Detected Ports at the main menu and map again.

-CorpNewt

roddy20 commented 3 years ago

Yes! Thanks again, it helps! now all the names are OK Снимок экрана 2021-04-26 в 20 16 20