#asahi · 2021-04-01 10:51
marcanjust mostly as-is?#asahi · 2021-04-01 10:51
marcanffs it's been one thing after the other the past few weeks, personal things, then stallman...#asahi · 2021-04-01 10:50
marcananyway, enough distractions, let me do one final change to AIC and push v4 out already now#asahi · 2021-04-01 10:50
marcansince i need to port over that pasemi driver#asahi · 2021-04-01 10:50
marcanand yes, I was planning on looking at those i2c pins to measure the clock and other i2c behavior#asahi · 2021-04-01 10:49
marcanbut I'd be happy to do the riskier bits :)#asahi · 2021-04-01 10:48
marcanI'd be surprised if you could bork something permanently by touching clocks#asahi · 2021-04-01 09:36
marcanthough presumably one of the baud clock options could be shared with the core clock#asahi · 2021-04-01 09:36
marcanyes, AIUI nominally the UART peripheral has one core clock and N baud clocks#asahi · 2021-04-01 08:54
marcanI think the UART has at least two clocks (the current driver patch does not attempt to support that; we can start to experiment now that we have non-UART channels)#asahi · 2021-03-30 00:47
marcanheh, no surprise there#asahi · 2021-03-29 15:39
marcanit would be something very simple that binds to the port registers too, and chains IRQs to AIC#asahi · 2021-03-29 15:39
marcanIIRC from last time I had to model this kind of nonsense (MSIs on PS4...), the sane way to do this is with another irqchip driver#asahi · 2021-03-29 15:37
marcanso clearly AIC isn't doing the MSI handling here, it just takes a pile of discrete IRQ lines (or some other out of band signaling mechanism) from the ports#asahi · 2021-03-29 15:37
marcanyes#asahi · 2021-03-29 15:37
marcanwhich implies the decoding is done at the ports, not by AIC#asahi · 2021-03-29 15:36
marcanand yet the MSIs do not overlap#asahi · 2021-03-29 15:36
marcankettenis1: but apple always sets them to the same address#asahi · 2021-03-29 15:29
marcanso the hardware is most likely an address compare in the PCIe root port that then sends discrete edge-triggered IRQ signals out to AIC#asahi · 2021-03-29 15:28
marcanarnd: it can't be passed through, because they use the same address for all controllers, yet they allocate different MSI ranges#asahi · 2021-03-29 08:28
marcanwe're just basing our "bleeding edge/early adopter" style distro on ALARM#asahi · 2021-03-29 08:28
marcanbut the goal of the project is to have the installer set up a useful boot environment for any distro to work, and to upstream things so other distros will work too#asahi · 2021-03-29 08:27
marcantsujp: the "official" distro will be Arch linux ARM + add-on repo and installer#asahi · 2021-03-29 08:27
marcanthe only hard dependency is the FIQ series, and the samsung stuff only if people care about transiently non-validating devicetrees depending on merge order#asahi · 2021-03-29 08:26
marcanthey are not a dependency for arnd's merge anyway#asahi · 2021-03-29 08:26
marcanmaz: since I have a weirdo merge base branch to make this all work anyway, I'll keep them there and won't submit them#asahi · 2021-03-28 13:41
marcanmaz: should I send out those two VHE fix patches at the head of v4, or do you want to keep discussion of those to your thread?#asahi · 2021-03-28 13:38
marcanmaz: np, it was my bug after all. thanks!#asahi · 2021-03-28 11:50
marcanalso, the register name was wrong; it's _EL2, not _EL1#asahi · 2021-03-28 11:50
marcanpushed a fix to the v4 branch#asahi · 2021-03-28 11:42
marcanthat's a bug#asahi · 2021-03-28 11:42
marcanand... yeah, the AIC code should not be dispatching guest IRQs if the masks are set, should it#asahi · 2021-03-28 11:41
marcanI tried actually firing a FIQ (DAIF clear) and just reading (not writing) the timer registers there, and I still get a FIQ storm#asahi · 2021-03-28 11:31
marcanmaybe I'm confusing myself#asahi · 2021-03-28 11:31
marcanactually, I'm not even seeing them fire when masked if TGE=1 either#asahi · 2021-03-28 11:29
marcanthey just don't raise a FIQ#asahi · 2021-03-28 11:29
marcanof course the timers fire in the timer registers#asahi · 2021-03-28 11:29
marcanwell, firing as in ISR_EL1 is zero#asahi · 2021-03-28 11:29
marcanof course, if you restore the timers with TGE=1, that will cause them to fire#asahi · 2021-03-28 11:29
marcan*iff* TGE=0#asahi · 2021-03-28 11:29
marcancorrect#asahi · 2021-03-28 11:24
marcanI'm definitely not seeing the ISR cleared when I read the CTL register#asahi · 2021-03-28 11:24
marcanhttps://mrcn.st/p/AYXJ2jlI here is some exhaustive testing#asahi · 2021-03-28 11:24
marcananyway, that aside#asahi · 2021-03-28 11:23
marcanso we can at least mask a firing timer, but we still can't inject a non-firing one#asahi · 2021-03-28 11:23
marcanI just realized at at least it *does* listen to the mask register#asahi · 2021-03-28 11:22
marcanremember we had the vGIC issue with not being able to control the hardware state when using the funny list register, right?#asahi · 2021-03-28 11:22
marcanmaz: wait, I just found something#asahi · 2021-03-28 11:11
marcanthough that's about the masking, I certainly can't explain any kind of edge-triggered-like behavior for the HV timers#asahi · 2021-03-28 11:10
marcanmaz: is it possible that TGE gets flipped to 1 at some point with the guest timers still firing? in that case you would get FIQs delivered to EL2