Repository navigation
J773s: USB3 on the front USB-C ports (T6040 PHY behind an on-board hub) - #2361
RyanTheTide wants to merge 4 commits into
Conversation
The Mac mini M4 Pro (J773s) has two front USB-C ports behind an on-board USB2/USB3 hub on ATC3, with no PD controller. This PHY brought USB3 up only for a plug orientation from a Type-C orientation switch. Without that switch it skipped the USB3 setup entirely and was then taken for a DP-only (HDMI converter) PHY. Recognise such a port the way dwc3-apple already does: a "hub" child on the controller that the PHY's USB3 graph port (port 1) links to. The PHY then takes the connection as fixed and runs USB3 on the lanes of a normal plug orientation, with no orientation switch. The ADT gives every connector-less ATC PHY plug orientation 1, as it does the laptops' HDMI converter PHYs, which already run unflipped. PHYs with an orientation switch, and those without a hub, are unchanged. Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
The two front ports sit behind an on-board USB2/USB3 hub on ATC3, whose controller (ADT usb-drd3) is a fixed host. Enable atcphy3, its mailbox, the dwc3_3 DARTs and dwc3_3, and add: - the hub child on raw USB2 root port 1. It is the J773g's front hub: the ADT lists the same hub firmware (usb3hub-fw-gl3590, id 56) and the same hub port layout (usb-drd3-port-hs/-ss); - the link from the PHY's USB3 port to the controller's SuperSpeed port (raw port 2), by which the PHY finds the fixed hub; - the ATC3 power domains; - the hub's reset and SPI-flash output-enable lines (ADT usb3hub_rst 127, usb3hub_flash_oe 130), held high as the boot loader and macOS leave them, as on the J773g. The J614s, J616s and J616s-tether DTBs are unchanged. Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
|
Blockers: 1.
Checked and fine:
HW row: nothing has booted this. J773s (community tester, #1479) on this head:
Plus one J616s boot as a no-regression row: all Type-C ports reach USB3 SuperSpeed and HDMI is up. Assisted-by: LLM (Claude:Opus 5.5) |
Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
…ixed hub The J773s front USB-C ports sit behind an on-board hub on ATC3: the controller is a host with a hub child and no Type-C connector, and its T6040 PHY has only the SuperSpeed link to the controller (port@1), no connector port. Neither has a role or connector to describe. apple,dwc3: require usb-role-switch only on controllers that are not fixed to dr_mode = "host" (resets stay required). apple,t6040-atcphy: a ports node needs the connector port or the controller link, not always the connector port. Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
|
Forward-merged main f02bd68 (38bcb9c, clean) and fixed the 11-21 dt-checks blocker in cbabdb3 by describing the fixed-hub case in the bindings rather than adding fake nodes:
Local: |
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
There was a problem hiding this comment.
Verdict: MERGE at cbabdb3
Checked: The fixed-hub PHY follows port 1 to an available hub child using the same criterion as DWC3. The Type-C switch takes precedence, and a PHY with neither path stays on its prior route. The revised bindings admit the fixed graph and host topology, and exact hosted DT and DWC3/ATC checks passed. The exact Host Tests log has failures in sleep fixtures outside this diff. Host CI and the native J773s row remain open.
Problem
The Mac mini M4 Pro (J773s) front USB-C ports are disabled. They sit behind an on-board USB2/USB3 hub on ATC3, with no PD controller and no Type-C connector, and the T6040 PHY driver only brings USB3 up for a plug orientation reported by a Type-C orientation switch. Without that switch,
t6040_usb3_probe()also returned before the USB3 setup, so the PHY would have been treated as a DP-only (HDMI converter) PHY.Change
Two commits: the PHY change, then the J773s device tree.
phy: apple: t6040: a PHY whose USB3 graph port (port 1) links to a controller with ahubchild is wired to a fixed hub. This is the same hardware description dwc3-apple already uses to start such a controller as a host. That PHY runs USB3 on the lanes of a normal-orientation plug and registers no orientation switch. The ADT gives every connector-less ATC PHY plug orientation 1, the laptops' HDMI converter PHYs included, and Linux already drives those unflipped. PHYs withorientation-switch(every Type-C port) are unchanged.t6040-j773s-usb-front.dtsi: enable atcphy3, its mailbox, the dwc3_3 DARTs and dwc3_3. Add the hub child (usb5ac,800b: the J773g front hub, which has the same GL3590 firmware id in the ADT), the PHY to controller SuperSpeed link, the ATC3 power domains and the hub reset / flash-OE GPIO hogs (ADT usb3hub_rst = 127, usb3hub_flash_oe = 130; the loader leaves both high, as on the J773g).The J614s, J616s and J616s-tether DTBs are byte-identical. Only the J773s changes.
Details
setdid.t6040-j773s.dts(arm64: dts: apple: t6040: Thunderbolt/USB4 on the Mac mini M4 Pro, router enables shared by every M4 Pro #2284 adds an include there), the J773s rear ports.Testing
integration/aurora. dtc prints the same warning counts.drivers/phy/apple/t6040-usb2.ccompiled for arm64 with clang 22 and the W=1 warning set against a preparedintegration/auroratree (CONFIG_PHY_APPLE_T6040_USB2=m): 0 warnings, the same as before the change.Still to run
A J773s boot (community tester, #1479):
dmesg | grep 39aa90000showsUSB3 PIPE on the PHYand noUSB3: no plug orientation.lsusb -tshows the front hub on the usb@39a280000 bus at 480M and at 5000M or 10000M.