#asahi-dev · 2022-11-13 18:40
svenalso not much fun though#asahi-dev · 2022-11-13 18:40
svenother alternative is to run the hv and intercept reads from the fuses and the atcphy regs and play with some patterns to figure out which bits go where#asahi-dev · 2022-11-13 18:40
svenbut still... not much fun to find those fuses#asahi-dev · 2022-11-13 18:40
svenmost of that is debug crap though#asahi-dev · 2022-11-13 18:39
sventhose are annoying because they’re not a table in a kext but a function that’s like 1k lines decompiled in ghidra #asahi-dev · 2022-11-13 18:38
svensure. I’ll also need to nerd snipe someone into reverse engineering the atc fuses for m2#asahi-dev · 2022-11-13 18:36
svenI’ll ping you once I’m ready #asahi-dev · 2022-11-13 18:35
svenat least usb3#asahi-dev · 2022-11-13 18:35
svennot yet, but soon #asahi-dev · 2022-11-13 15:55
svenoh.. true. we don't even have those yet#asahi-dev · 2022-11-13 15:43
svenlet me clean up tipd a bit, then ideally get confirmation that usb3 works on all machines out there (especially m2) and then I’ll prepare something for marcan to merge into asahi-dev to get usb3 up :>#asahi-dev · 2022-11-13 15:42
svenanyway, looks like doing the pipe handler dance inside power_on works just fine as well#asahi-dev · 2022-11-13 15:41
svendoesn’t even know what drm atomic commits are#asahi-dev · 2022-11-13 15:28
svennice!#asahi-dev · 2022-11-13 13:15
svennot at a computer right now anyway ;)#asahi-dev · 2022-11-13 13:14
svenbut it seems to be very stable here now#asahi-dev · 2022-11-13 13:14
svenwe can probably also soonish enable usb3 in asahi-dev at least. Just want to fix some minor things, move the pipehandler stuff to pwoer_on and test it a bit more #asahi-dev · 2022-11-13 13:14
svennice, let me start working on that#asahi-dev · 2022-11-13 12:55
svenno matter how thunderbolt eventually fits into this mess that role switch thing is good enough to bring dwc3 up/down whenever we need it#asahi-dev · 2022-11-13 12:54
svenlet me verify if my new role switch reset quirk still works without a phy present. Then I’ll just have to rework those apple,dwc3 bindings before trying to upstream it#asahi-dev · 2022-11-13 12:53
svendoing the pipehandler stuff in power_on also works fine #asahi-dev · 2022-11-13 12:50
sven\o/#asahi-dev · 2022-11-13 12:41
sveni may have accidentally switched pipehandler to either an invalid state or usb4 mode#asahi-dev · 2022-11-13 12:41
svenmaybe fixes that#asahi-dev · 2022-11-13 12:41
sven+#define PIPEHANDLER_CLK_DUMMY_PHY 4#asahi-dev · 2022-11-13 12:41
sven-#define PIPEHANDLER_CLK_DUMMY_PHY 2#asahi-dev · 2022-11-13 12:41
svenand#asahi-dev · 2022-11-13 12:41
sven+#define PIPEHANDLER_MUX_MODE_DUMMY_PHY 2#asahi-dev · 2022-11-13 12:41
sven-#define PIPEHANDLER_MUX_MODE_DUMMY_PHY 0#asahi-dev · 2022-11-13 12:36
sventhat’s new, usually when the pipehandler lock thing happens the port is dead #asahi-dev · 2022-11-13 12:36
svenuh oh#asahi-dev · 2022-11-13 12:16
svenit won’t work at boot time though since there’s still this race between drm and tipd probe#asahi-dev · 2022-11-13 12:15
svenbut it worked at least once#asahi-dev · 2022-11-13 12:15
svencould also be me, I didn’t test the DP hotplug very well#asahi-dev · 2022-11-13 12:09
svenso that's what we can use for HPD even with USB3+DP hubs#asahi-dev · 2022-11-13 12:09
svensee how the last byte there is 0 vs \x00? that's the DP SID Status changed interrupt#asahi-dev · 2022-11-13 12:08
svenalso, i'm blind. b'\x00\x00\x00\x000'#asahi-dev · 2022-11-13 11:45
svener.. *doing it before xhci init#asahi-dev · 2022-11-13 11:43
svenlet's see if I can move the pipehandler configuration into the phy power_on callback because apparently doing phy_set_mode after xhci init breaks some intel platform *sigh*#asahi-dev · 2022-11-13 11:36
svenand normal orientation is both_pma = true and UNK100#asahi-dev · 2022-11-13 11:36
svenokay, I think swapped is both_pma = false and UNK008#asahi-dev · 2022-11-13 11:33
svenso I guess even both_pma is only set for one of those two#asahi-dev · 2022-11-13 11:33
svenand [PhyTracer@/arm-io/atc-phy1] MMIO: W.4 ACIOPHY_CROSSBAR = 0x22014 (PROTOCOL_SWAPPED=0, PROTOCOL=0xa(DP), DPMODE=0x1100) for the other one#asahi-dev · 2022-11-13 11:33
svenso I see [PhyTracer@/arm-io/atc-phy1] MMIO: W.4 ACIOPHY_CROSSBAR = 0x114 (PROTOCOL_SWAPPED=0, PROTOCOL=0xa(DP), DPMODE=0x8) for one orientation#asahi-dev · 2022-11-13 11:33
svenhuh, nevermind. apparently it now negotiates four lanes again#asahi-dev · 2022-11-13 11:22
svenjannau: hrm, so I don't have a display that actually requires 4 lanes so both pma_single seem to work for me. would be great if you can figure out the right UNK008/UNK100 setting if you have some time!#asahi-dev · 2022-11-12 20:57
svenalright, so just one ACIOPHY_CROSSBAR_DP_SINGLE_PMA_UNK100 needs to be ACIOPHY_CROSSBAR_DP_SINGLE_PMA_UNK008 and then everything should be good#asahi-dev · 2022-11-12 20:55
svenbut I think it doesn't set ATCPHY_MISC_LANE_SWAP#asahi-dev · 2022-11-12 20:55
svenno, that's correct. I have 0 vs. 1.