Contribute
Register

The New Beginner's Guide to USB Port Configuration

XHC5 and XHC are two separate controllers, so you can have 15 ports for each controller.

You should include the XHC5 ports in any USBPorts.kext you create, otherwise your USB Type-C/thunderbolt ports won't function.

The XHC controller can only have 15/24 ports active in macOS.
 
You can manually create a USB SSDT configuration file and use that instead. Once done you can actually export a new USBPorts.kext from Hackintool and swap to that. A good idea.
After 5 weeks I just decided to get back to it.

Thanks again for all your info!
I just checked your link and if that's really a solution/workaround to my problem, I'd gladly give it a try.

However the guide also requires xhciportlimit = true (even though it's a clover equivalent, I'm using OC) + usbinjectall.kext.
Problem is, 5 weeks later it's still the case that if both are present, my ports stop working entirely (except for two on the back panel). Hackintool doesn't recognize the rest of the ports (including BT, which stops working too).
So honestly I still have no idea what to do no matter which guide I stick to.

Shouldn't I get rid of this issue first?

I've become so desperate, I'm close to installing some old macOS (prior to 11.3) on another partition just to get my port mapping done, as some people suggest.
 
Installing macOS Catalina on a separate Drive may be a better option for you to follow, if you are still struggling after all this time.
 
Since I don't have anymore internal SSDs and I don't want to mess with my current setup, I think I'll try installing Catalina on my external HDD.
If that works, I'll try the port mapping once more.

Will keep you guys posted, thanks!
 
I installed Catalina on my flashdrive yesterday and tried to map the ports again.
This time I could finally enable xhciportlimit and add usbinjectall without breaking all my ports.
On Big Sur, having both at the same time made my ports stop working.
So that's a good thing so far.

When I rebooted into Catalina with xhciportlimit = true and usbinjectall, I could see all of my ports in Hackintool.

However, I followed this guide and when I got to step 3, I still had the same problem as in the past. When I plug in a USB 3 device, only HS ports respond. I can see my SS ports in the Hackintool list as being present, but they never get highlighted when I plug anything in (the flashdrive I'm booting Catalina from is a USB 3 device for example).

Since I know which of my motherboards ports are USB 2 and USB 3, I decided to proceed "blindly", which means: I plug in a device into let's say HS01, which I know is supposed to be a USB 3 port, Hackintool highlights HS01, but when it comes to removing unused ports, I kept SS01.

I don't know if this is the right way to do? Or is there anything faulty and needs to be fixed?

I finished the guide and with the newly generated usbports.kext and the ssdt files, I disabled xhciportlimit again, removed usbinjectall, made a new OC snapshot and rebooted. When I now open up Hackintool, I only see the ports I decided to keep (see screenshot). It wasn't working that way with my old usbmap.kext, which is cool.

Screen Shot 2021-09-06 at 09.08.05.png


But still, the fact that none of my SS ports respond is bugging me and I'm not sure if everything is right, maybe macOS is only using USB 2 ports now? My shut down issue hasn't been solved either (while shutting down from macOS works perfectly fine, shutting down from OC and Windows results in a restart), which was the initial reason to do all this.
If someone wants to take a look, here's also my ioreg, usbports.kext and config.plist.

Thanks!
 

Attachments

  • 10tacle.zip
    750.6 KB · Views: 36
Check your Bios settings to ensure you haven’t disabled the USB3 controller.
 
I have a Z370m Mortar and couldn't find anything related to USB 3 in the BIOS, just checked. :(

Only thing I just tried was disabling USB legacy support, but no difference except that the OC bootloader doesn't show my flashdrive anymore.
 
You should be using the following Bios settings when running macOS:
  1. Virtualization : Enabled
  2. VT-d : Disabled
  3. XHCI Hand-Off : Enabled
  4. Legacy USB Support: Auto/Enabled
  5. IO SerialPort : Disabled
  6. Network Stack : Disabled
  7. XMP Profile : Auto / Profile 1/Enabled
  8. UEFI Booting set to Enabled and set Priority over Legacy
  9. Secure Boot : Disabled
  10. Fast Boot : Disabled
  11. OS Type: Other OS
  12. Wake on LAN : Disabled
Dedicated Graphics + Integrated graphics card:
  1. Integrated Graphics : Enabled
  2. Graphics: PEG/PCIe Slot 1
  3. Initial Display Output : PCIe 1 Slot
  4. DVMT Pre-Allocated : 128M or higher
There are two USB entries that are required, one being Legacy USB Support, the other being XHCI Hand-Off. Both need to be enabled for our USB ports to work correctly in macOS.

Your MIS Z370m Mortar motherboard has the following section in your BIOS.

ADVANCED > USB Configuration, with the three sub-sections shown below in the screenshot form your MB manual:

Screenshot 2021-09-06 at 15.16.41.png MSI Z370m Mortar BIOS USB section

Check that XHCI Hand-Off is ENABLED, as the default setting is DISABLED.
 
I just checked and everything was already set accordingly, except USB legacy support, which I disabled this morning for testing purposes (it was enabled before, now it’s enabled again).
XHCI handoff is enabled also. :(
 
What does your IOReg show when you install a USB3 pen drive in to a USB3 port?

While looking in the IOReg, see which port the installed USB3 drive connects against. When a USB drive is inserted, the port should flash with Green coloured text for a second. Then it will display the drive attributes against the port. In the example below I have installed a USB3 pen drive, named 'NO NAME' in to the front case top left USB3 port. The USB port on the case corresponds with port SS02 in my IOReg, as seen in the screenshot below.

Screenshot 2021-09-06 at 17.11.31.png SS02 containing USB3 pen drive named 'NO NAME'

When you eject a USB pen drive, the text in IOReg will flash RED in colour. It will then show the device as being removed, by using the StrikeThrough text, as seen in the screenshot below.

Screenshot 2021-09-06 at 17.13.13.png SS02 when Pen Drive has been ejected.

You probably need to check in your IOReg for each USB3 port, with both a USB2 and a USB3 pen drive, to ensure you identify all your USB ports correctly. You can then edit the list of ports in Hackintool to match the IOReg port discovery. So you can export a USBPorts.kext that will work with your motherboard.
 
Back
Top