I've got a 2012 11" i7 MBA. This is a great little machine but one thing has been driving be absolutely batty about it... The USB ports work well for the most part, but inevitably I will plug in a USB device (could be anything. Thumb drive, USB serial port, JTAG cable, USB2 or USB3 device, doesn't matter) and it will power up (LEDs blink, etc.) but the device is not recognized by the Mac.
Looking at dmesg, I see this:
USBF: 126826.226 AppleUSBXHCI[0xffffff80d5636000]::WaitForCMD (Enable Slot Command) - Command failed: -1009 (num interrupts: 93582187, num primary: 46791094, inactive:0, unavailable:0, is controller available:1)
USBF: 126826.226 AppleUSBXHCI[0xffffff80d5636000]::PrintInterrupter WaitForCMD IRQ:0 - IMAN: 00000002 IMOD: 000700a0 ERDP: 002043d0
USBF: 126826.226 AppleUSBXHCI[0xffffff80d5636000]::UIMCreateControlEndpoint 2 - Run out of device slots, returning: e0004045
USBF: 126826.226 AppleUSBHubPort[0xffffff8015ddce00]::DoConfigureDeviceZero Port 1 of hub at 0x14000000. Cannot create USB device (kIOUSBDeviceCountExceeded)
The USB stack is not able to enumerate the device at Port 1 of hub at 0x14000000 because the USB hardware ran out of device slots
At this point the USB port is kaput. Unpugging/replugging the same device or another will show similar messages. The only solution seems to be a reboot. Putting the Mac to sleep doesn't help.
I've got the USB logging driver installed to try to help diagnose the issue but I am not seeing anything that I could call a smoking gun, and trying to reload the USB kexts does not help either.
This issue was present on my old 2011 MBA as well, and the issue has persisted from 10.7 to 10.9. Both ports will eventually do this, which makes me believe that it isn't a physical port issue since one port is on a separate I/O board and the other is on the main logic board. I've tried to connect the device through an external USB2 and USB3 hub (tried both) and the problem will eventually occur in these situations as well.
I'm fairly technically savvy, but not necessarily at my best on OSX. I can gather more information if someone were to help me determine what data is appropriate to help debug the problem. I've also done the usual NVRAM/SMC resets, fix permissions, etc... doesn't help.
Has anyone else run into this? What information could I provide to help diagnose the issue? Does anyone know of a way to fully reset the XHCI controller in this situation to try and recover without needing the reboot?
Edit 20140217
Adding the bounty certainly got this question the attention I felt it needed! Thank you for all of the answers so far, but I think that there are some important misconceptions that I'd like to address:
- I didn't migrate my account from the older MacBook Air. Brand new install
- The problem occurs with pretty much any device. USB keys (no cables here!), JTAG adapters, USB3 drives
- The problem occurs with or without USB2 or USB3 hubs
- If the problem occurs with a device on a hub, unplugging the hub and plugging the device directly into the Mac doesn't help
- If the problem occurs without a hub, plugging the device into a USB2 or USB3 hub doesn't help
- Once the problem occurs, logging out / switching to a different (new) user doesn't make the problem go away for the new user or the old user.
I develop electronic hardware and software for a living, including USB 3.0 devices. I'm familiar with USB root port drivers, but not at all familiar with low level (kernel) development on OSX.
I'm fairly certain that this is a device driver problem simply due to the nature of how it manifests itself. From a clean boot, things work great. Unplug/replug and it might still work great. Unplug/replug will eventually cause the problem to show up, and at that point ANY USB device in that port will not work. Reboot and things work great again.