For example, let's say you have a USB-C hub with 4 downstream ports and two USB devices plugged in. At least one of these is a 10Gbps USB 3.1 device. You plug in a USB-C -> HDMI adapter. Which of the following happens (and how does your grandmother diagnose the problem)?
1. Nothing. 2. The three existing devices detach from the bus and re-enumerate as USB 2.0 at 0.480 Gbps 3. The three existing devices continue to run as 3.0 devices, but only at 5 Gbps 4. The three existing devices continue to run as 3.0 devices at 10 Gbps
Explanation:
1. The hub does not support USB alt modes, so when an HDMI dongle is plugged in, the dongle is ignored.
2. The HDMI dongle is a passive alt mode device, requiring the use of all 4 high speed lanes. The other downstream devices are routed the internal USB 2.0 hub.
3. The HDMI dongle has an active Displayport -> HDMI converter inside, and uses only 2 of the high speed lanes, leaving the other 2 for USB 3.0 data. Since the other peripherals use the 2x 5Gbps USB 3.1 mode and only 1 lane is available in each direction, they revert to 5Gbps
4. Same as #3, except that the peripherals use the 1x 10Gbps USB 3.1 mode, so they continue to operate at 10Gbps with a single lane.
Ok, now 3 ports are occupied and you plug in a pair of USB-C headphones. What happens now?
1. Nothing 2. Your HDMI dongle stops working 3. Everything Just Works
Explanation
1. USB alt modes don't cover the case of a USB Audio Accessory and a Displayport accessory. Since you can't have both, your drivers ignore the new device
2. Same as #1, but your drivers prioritize the new device
3. Maybe your hub secretly has an audio codec inside, and is able to sync and source analog audio to any downstream port.
Bonus points: Ok, now what happens when you chain USB-C hubs? What happens when you try to plug in multiple HDMI adapters? Multiple audio accessories? When things don't work, is the problem the hub, the peripheral, or the drivers?
1. Plug the HDMI adapter: almost nothing. The HDMI adapter enumerates as an USB 2.0 "billboard device". The operating system can read the descriptor from this device and present a pop-up explaining "you have to plug HDMI adapters directly". This is because, as far as I know, USB hubs can't pass through alternate modes (except for the new USB4 alternate mode, but that is less of "pass through" and more "the hub is a USB4 device itself").
2. Plug the USB-C headphones: it depends on whether they are analog headphones using the "audio accessory" mode, or digital headphones presenting as an USB audio device. If they are digital headphones, it's the "everything just works" case; if they are analog headphones, it's the "nothing" case (unless there's something in the specification I missed where a hub can detect the "audio accessory" and warn the host, in which case you might get the pop-up explaining "analog headphones are not supported by this computer, even if you had plugged them directly").
Things change a bit with USB4. In the particular case where the HDMI dongle is an active DP to HDMI converter (which is probably the most common case, since from what I've seen computer support for the DP alternate mode is more common than the HDMI alternate mode, so most dongles will cater to that case), and the hub is an USB4 hub, it'll work as if it had been connected directly, since USB4 can tunnel Displayport (together with PCI Express and USB 3).
I wanted to address your point about the "correct" answer, because it's actually not so simple:
The billboard spec allows for a device to be both a DisplayPort 4-lane and a USB 2.0 device (This isn't theoretical--I have such a device in front of me. It's a passive DisplayPort + 2 port USB2.0 + microSD "hub").
The HDMI adapter I hypothesized in my second scenario is a passive HDMI adapter. You're correct that passive HDMI + USB2.0 is not possible, but substitute a passive DisplayPort for passive HDMI here and the idea is the same.
In the third scenario I am hypothesizing an active 2-lane DisplayPort to HDMI adapter (These are also not theoretical--this is how the Apple "HDMI Multiport Adapter" works).
The hub I hypothesized for scenarios 2 through 4 (which does not exist) is one that would be smart enough to do the following:
1. Recognize the video dongle's billboard
2. Send the host a "fake" billboard for "DisplayPort 2 lane + USB 3.0" or "DisplayPort 4 lane + USB 2.0" (as appropriate)
3. Re-configure the downstream USB-C as USB 3.0 or 2.0-only ports (again as appropriate)
4. Route DP to the dongle (perhaps via an internal DP -> HDMI converter, if the hub has one), Route USB 2.0 or 3.0 to the internal hub, and route the hub to the downstream USB-C ports.
I don't recall if rewriting the billboard is allowed per the USB spec (I think it isn't). But you can see how it would be possible for a hub to support alt-mode routing, even if the spec doesn't formally define it.
The alternate mode discovery is initiated by the host, so the only way the hub could change which alternate modes it supports would be to disconnect from the host (unplugging all the devices on it, which would be particularly bad if some of them were storage devices).
(Also, I believe HDMI alternate mode with USB 2.0 is possible. The only alternate mode I know of which changes the meaning of the USB 2.0 pins is VirtualLink, which uses them for USB 3.x instead.)
Users (even technical users on Hacker News) keep asking for a "USB-C hub". What do you think they mean by that? "I want to plug in all my USB-C crap" or "I want to plug in all my USB-C crap, except video dongles and some[1] audio dongles"
All the use cases for an everything-except-alt-mode USB-C hub are already met by existing USB-A hubs[2].
[1] "And please don't give me an easy way to tell which headphone dongles will work ahead of time. The surprise and anticipation of seeing whether it works makes every plug-in event feel like my birthday."
[2] Okay, okay, you do need USB-C connectors for 20 Gbps USB bandwidth. But I've never actually seen a 20 Gbps USB host, device, or hub in the wild.
1) not that many people have four USB-C devices they need to plug in at once (unlike USB-A),
2) it'd probably be super expensive and in some cases impossible to support all the abilities of USB-C across 4 ports, leaving only some small subset of capabilities available on all four and maybe forcing you to not use some of the ports at all if one or two of them have higher-end capabilities and you're actually using them for that. Experience is probably confusing and frustrating at best—and expensive anyway.
https://www.amazon.com/Belkin-Linksys-B2B153-04-BLK-4-Port-D...
But I would point out that the linked device has 1 USB-C Power Delivery pass-through, 1 USB-C data port, and 2 USB-A ports.
Nobody has yet shipped a USB hub with more than 1 USB-C downstream data port.
It was bus-powered, so I'm pretty sure it was simply a bunch of USB-C ports that offered no more than USB 3.0 and that didn't support USB-PD.
Can't seem to find it anymore.
I guess negotiating the bandwidth and power delivery would be pretty complex
It is highly likely any such hub would be a USB-3.x hub only but wouldn't support power pass-through properly, you wouldn't be able to connect your monitor to it, etc.
Besides phones and laptops there are not many USB-C devices out there yet. And you don't connect phones and laptops to hubs (as a guest, not a host).
Apple has been shipping laptops with only USB-C since 2015. Many people rely heavily on dongles and breakout boxes. A USB-C hub would be welcome even at a steep premium.
My guess is that all of the tech that tunnels through USB-C would be really difficult to hub or to share. Which is why the closest thing I've seen to a hub is a passthrough plus a USB-C for power.