#asahi-dev · 2022-02-08 12:22
marcanfault detection/etc? but those could just come from scratchpad regs since presumably faults cause the system to shut down#asahi-dev · 2022-02-08 12:22
marcanit's mostly RTC, a few scratchpad/etc registers for boot/shutdown mode, and that's about it I think?#asahi-dev · 2022-02-08 12:21
marcanhonestly though, I don't think macOS does much with the PMU#asahi-dev · 2022-02-08 12:20
marcanyeah#asahi-dev · 2022-02-08 12:18
marcanthey do have some public datasheets but at least the RTC doesn't match#asahi-dev · 2022-02-08 12:18
marcanfwiw, it seems these chips are by Dialog, but I can't find any references to public SPMI PMUs by them#asahi-dev · 2022-02-08 12:17
marcan*claiming#asahi-dev · 2022-02-08 12:17
marcanwho do they think they are, claining they're the only MFD SPMI PMICs :p#asahi-dev · 2022-02-08 12:16
marcanannoyingly, they decided to name the config CONFIG_MFD_SPMI_PMIC#asahi-dev · 2022-02-08 12:16
marcanjust has a list of supported devices and reads a device ID, but other than that, it's just the regmap#asahi-dev · 2022-02-08 12:16
marcanfwiw, qcom-spmi-pmic.c does much the same thing#asahi-dev · 2022-02-08 12:15
marcanit does support multiple masters, and they well might implement multiple logical masters over one set of pins for this purpose#asahi-dev · 2022-02-08 12:15
marcanapple has them in the adt, I think it might actually be a multi-master thing?#asahi-dev · 2022-02-08 12:14
marcansince they need to be poked for DVFS#asahi-dev · 2022-02-08 12:14
marcanthe CLVRs are autonomously managed by, I'm guessing, logic in PMGR for one#asahi-dev · 2022-02-08 12:14
marcanon m1pro machines there's two Mavericks, one Viper (with multiple buck controllers controlled by it), and three Monacos (CLVRs)#asahi-dev · 2022-02-08 12:13
marcanyes#asahi-dev · 2022-02-08 12:12
marcanthe CLVRs are on separate SPMI buses#asahi-dev · 2022-02-08 12:12
marcanthey'd be subnodes of the SPMI controller#asahi-dev · 2022-02-08 12:12
marcannot of the PMU#asahi-dev · 2022-02-08 12:12
marcanbut those wouldn't be subnodes anyway#asahi-dev · 2022-02-08 12:12
marcanI think for the *most* part we probably don't need to use them#asahi-dev · 2022-02-08 12:09
marcanand "Viper" which is the 1.8V regulator#asahi-dev · 2022-02-08 12:09
marcanmultiple CLVRs for the main compute power rails#asahi-dev · 2022-02-08 12:09
marcanthere's more things too#asahi-dev · 2022-02-08 12:07
marcanI have that node commented out right now#asahi-dev · 2022-02-08 12:07
marcanit's on another spmi bus#asahi-dev · 2022-02-08 12:07
marcanit can#asahi-dev · 2022-02-08 12:06
marcana master and a slave#asahi-dev · 2022-02-08 12:06
marcanactually there's two of them#asahi-dev · 2022-02-08 12:06
marcanyes#asahi-dev · 2022-02-08 12:01
marcanI'd think so#asahi-dev · 2022-02-08 12:01
marcanregister bases just moved#asahi-dev · 2022-02-08 12:01
marcanso at least for n=2 platforms, it looks like it should be future-proof#asahi-dev · 2022-02-08 12:01
marcanit seems apple does it all in one big kext and I don't even see the hardware name strings anywhere#asahi-dev · 2022-02-08 12:01
marcanyes#asahi-dev · 2022-02-08 11:57
marcanyeah#asahi-dev · 2022-02-08 11:56
marcanso clearly this needs to be a bunch of child nodes of the PMU regmap with base offsets#asahi-dev · 2022-02-08 11:56
marcanand the RTC also moved which is why it didn't work for me#asahi-dev · 2022-02-08 11:55
marcankettenis: ok, so the magic SPMI register is actually the info-leg_scrpad offset from the ADT, plus 0xf#asahi-dev · 2022-02-08 11:20
marcanjust want to make sure we don't miss some obvious forward-compat mechanism#asahi-dev · 2022-02-08 11:20
marcanI need to look into how apple's driver handles discrepancies; it's supposedly one driver but it might just have a big table or something#asahi-dev · 2022-02-08 11:19
marcanat least not with the right date#asahi-dev · 2022-02-08 11:19
marcanno#asahi-dev · 2022-02-08 11:17
marcanI want to split off the SMC stuff for maz too#asahi-dev · 2022-02-08 11:17
marcanwill do in a bit, after dinner#asahi-dev · 2022-02-08 11:14
marcanlet me grab some dinner first though :)#asahi-dev · 2022-02-08 11:14
marcanyeah#asahi-dev · 2022-02-07 03:06
marcanok, going to grab a bite and stream a bit after that#asahi-dev · 2022-02-07 03:04
marcanoh and v6 even: https://lore.kernel.org/linux-m68k/20220130233718.21544-1-digetx@gmail.com/