#asahi · 2021-09-23 13:21
marcanwho wants to bet they're the same die :p#asahi · 2021-09-23 13:21
marcansven: so the public TI part has the i2c pins of the apple part as "reserved"#asahi · 2021-09-23 13:14
marcanwell apple is first...#asahi · 2021-09-23 13:13
marcanwho came up with this pile of fail?#asahi · 2021-09-23 13:13
marcan... I think I have a FS hub lying around, I should test this#asahi · 2021-09-23 13:13
marcanand only *two* at FS?#asahi · 2021-09-23 13:12
marcandoes... does the M1 support one fewer hub at HS than every other computer?#asahi · 2021-09-23 13:12
marcanhttps://mrcn.st/t/Screenshot_20210923_221232.png#asahi · 2021-09-23 13:12
marcanwait what#asahi · 2021-09-23 13:11
marcanno wonder weird impossible interactions can happen#asahi · 2021-09-23 13:10
marcanand on the other, talks to the M1 PHY#asahi · 2021-09-23 13:10
marcanthere's a whole pile of cursed USB mess that is driven, on one side, by i2c from tipd#asahi · 2021-09-23 13:10
marcanwell, at least now we know how this kind of fail is possible#asahi · 2021-09-23 13:09
marcanpsykose: and a 158 page spec, yes#asahi · 2021-09-23 13:04
marcanit never ends, does it#asahi · 2021-09-23 13:04
marcanwhy did I just discover a whole new cursed aspect of USB#asahi · 2021-09-23 13:03
marcanso wait, how does eUSB work#asahi · 2021-09-23 13:02
marcanhttps://www.ti.com/product/TUSB2E22 this is the redriver that's on the USB2 path#asahi · 2021-09-23 12:59
marcanbut this is getting real smelly in this direction#asahi · 2021-09-23 12:59
marcanwell, that's one i2c bus I need to poke then#asahi · 2021-09-23 12:59
marcanthe CD3217 is the i2c *master* for those other chips#asahi · 2021-09-23 12:58
marcanwait no, it's on the CD3217#asahi · 2021-09-23 12:57
marcanand firmware#asahi · 2021-09-23 12:57
marcanwhich is a whole separate big thing with JTAG etc#asahi · 2021-09-23 12:57
marcanand *that* is driven by the retimer chip#asahi · 2021-09-23 12:56
marcanand it has i2c too, and a reset line#asahi · 2021-09-23 12:56
marcansven: also there is some other chip in the way, some kind of level shifter#asahi · 2021-09-23 12:51
marcananyway, dinner first#asahi · 2021-09-23 12:50
marcanso there's something else here#asahi · 2021-09-23 12:50
marcanreset the controller and it does#asahi · 2021-09-23 12:50
marcani.e. if I replug, then switch to high-speed mode without a reset (which normally does turn on the pullups immediately), it doesn't#asahi · 2021-09-23 12:49
marcanah, but this is interesting. if I set it to SuperSpeed mode it turns off the pull-ups, but still wedges#asahi · 2021-09-23 12:45
marcan(it's possible we're dealing with two different problems here, of course)#asahi · 2021-09-23 12:45
marcanthe other half of the story is what about host mode; that uses pull-*downs* so what's up with that?#asahi · 2021-09-23 12:45
marcanonly problem is if I fix this now, what will happen with the teardown? T_T#asahi · 2021-09-23 12:45
marcandinner first though#asahi · 2021-09-23 12:45
marcanso the next plan of attack is dumping not dwc/phy regs, but *tipd* regs during this mess#asahi · 2021-09-23 12:44
marcansince the tipd would have to notice#asahi · 2021-09-23 12:44
marcanyou probably want some delay there too#asahi · 2021-09-23 12:43
marcan(stops the controller)#asahi · 2021-09-23 12:43
marcanand that does, indeed, kill the pullups.#asahi · 2021-09-23 12:43
marcansven: that fixes gadget mode for me.#asahi · 2021-09-23 12:42
marcan>>> set32(0x38228c704, 1<<31)#asahi · 2021-09-23 12:42
marcan>>> clear32(0x38228c704, 1<<31)#asahi · 2021-09-23 12:28
marcanso where's the pullup enable bit...#asahi · 2021-09-23 12:28
marcan:D#asahi · 2021-09-23 12:27
marcan(consider: software people figured out how to make this work and never talked to hardware people)#asahi · 2021-09-23 12:27
marcanif I'm right, I'm going to say apple themselves haven't debugged this properly, and are convinced it's a dwc/phy problem, and are doing all that shit for nothing#asahi · 2021-09-23 12:27
marcanand the whole phy/dwc3 reset dance? all just to turn the pullups off and on again enough for tipd to not hate it.#asahi · 2021-09-23 12:26
marcanit's possible that it sees the pullup voltage and hates it for some reason (maybe because it considers vbus not ready yet?)