#asahi-dev · 2022-10-30 02:31
chadmedhttps://github.com/AsahiLinux/docs/wiki/Installing-Gentoo-with-LiveCD#Updating-U-Boot-and-m1n1#asahi-dev · 2022-10-30 02:28
chadmedyou dont need to rebuild it, just run update-m1n1#asahi-dev · 2022-10-29 12:32
chadmedok i fixed some obvious issues, https://chadmed.github.io/res/opp2.patch#asahi-dev · 2022-10-29 12:19
chadmedoh hang on i left a debug print in there#asahi-dev · 2022-10-29 12:16
chadmeddo you mind having a look at this? it works, the EM is registered but as you could probably tell with my bumbling around macaudio im not very good at this :P#asahi-dev · 2022-10-29 12:15
chadmedmarcan, kazuki: https://chadmed.github.io/res/opp.patch #asahi-dev · 2022-10-29 11:03
chadmedlet me reboot into linux#asahi-dev · 2022-10-29 10:46
chadmedyeah i might make the _of_has_opp_microwatt_property thing actually check for the property instead of what happens now #asahi-dev · 2022-10-29 10:46
chadmedyeah i see whats wrong, they have a function that looks for the property BUT it only finds the property if it finds opp-microvolt first, the check is nested inside an if statement that is false if theres no opp-microvolt #asahi-dev · 2022-10-29 10:45
chadmedoh i see whats happened#asahi-dev · 2022-10-29 10:41
chadmedso i have no idea why it got tangled up with all this VRM crap, it was specifically added to NOT do that...#asahi-dev · 2022-10-29 10:41
chadmedthe opp-microwatt property was specifically added so that DT platforms could just provide opp-microwatt in the opp table and have the kernel do everything else without intervention by using that register_em_with_opp function as the callback for .register_em#asahi-dev · 2022-10-29 10:40
chadmedno clue how the actual scheduler makes decisions, but the cpufreq driver registers the device with the energy model system, and then schedutil can use that power information along with capacity-dmips-mhz to optimise for J/inst or something like that#asahi-dev · 2022-10-29 10:38
chadmedyeah i dont really know why opp-microwatt got tied to all of this#asahi-dev · 2022-10-29 10:33
chadmedidk what assumptions other arches make about the size of these dt properties, i dont really want to start going through changing shared code willy-nilly :( #asahi-dev · 2022-10-29 10:33
chadmedargh#asahi-dev · 2022-10-29 10:32
chadmedoh its the same on the cpu cores too?#asahi-dev · 2022-10-29 10:30
chadmedfwiw we dont actually need to describe the VRMs in their entirety for this to work, i confirmed that just having opp-microvolt in the pstates is fine last night (see logs)#asahi-dev · 2022-10-29 10:27
chadmedive been looking at changing that behaviour so if there are no VRMs associated && opp-microwatt is present, it still works. however, the core OPP code uses arch-native unsigned longs in all the relevant structs and functions, so using of_property_read_{u32,u64} makes the compiler very sad#asahi-dev · 2022-10-29 10:25
chadmedthe code that registers the energy model via the opp table does so by assuming there are VRMs associated with the core linked to the opp table in question. VRMs are enumerated by looking for the number of opp-microvolt props in the DT. if no VRMs are found, the energy model is not registered#asahi-dev · 2022-10-29 10:18
chadmedi think the best solution to the energy model thing long term is going to be to specify the voltages in the DT#asahi-dev · 2022-10-29 09:09
chadmedbut then youd need to figure out how to call in to the installer, or modify it so that you can just run it externally with some parameters fed to it#asahi-dev · 2022-10-29 09:08
chadmedyeah id assume youd at least have swiftui #asahi-dev · 2022-10-29 08:52
chadmedid suggest tkinter so you could run it in 1tr but i wouldnt wish tkinter on my worst enemy #asahi-dev · 2022-10-29 08:51
chadmedif you use pyqt5 you probably wouldnt need to change much in the current installer since you could probably just import its methods and call into them#asahi-dev · 2022-10-29 08:16
chadmedmillenialhacker: someone was working on implementing one in qt but thats vapourware now #asahi-dev · 2022-10-29 04:07
chadmedi should note that i bumped the codec gain limits to 15 instead of 9 since i have no intention of ever using this machine without pipewire. the curve is pretty much identical at the normal limit though, just quieter by a few dB#asahi-dev · 2022-10-29 04:04
chadmedbump at 50hz is just mains hum#asahi-dev · 2022-10-29 04:03
chadmedhttps://chadmed.github.io/res/linux.png <-- SotA via pipewire at the moment, just gotta smooth out the mids a bit#asahi-dev · 2022-10-29 04:02
chadmedif that phase/delay data is accurate thats... very fun#asahi-dev · 2022-10-29 04:02
chadmedtook the time to grab a freq-response curve from macos on j314: https://chadmed.github.io/res/macos.png, made the right decision to not copy this imo#asahi-dev · 2022-10-28 11:18
chadmedi kinda wanna tweak of.c to register regulators with just opp-microwatt present but that whole system is just a house of cards and i feel like many things will explode if theres no opp-microvolt #asahi-dev · 2022-10-28 11:14
chadmedif youre using a source tree thats not where update-m1n1 expects it to be then they still wont be updated, nano $(which update-m1n1) and point the DTBS variable to where your DTs are#asahi-dev · 2022-10-28 11:13
chadmedyeah#asahi-dev · 2022-10-28 11:13
chadmedmachine stays noticeably cooler which is lovely, but it kinda slaughters sw rendering performance lmao #asahi-dev · 2022-10-28 11:12
chadmedthe kernel doesnt load the DT at runtime, m1n1 puts it into memory and it is forwarded to the kernel by u-boot #asahi-dev · 2022-10-28 11:11
chadmedif you make changes to the DTs you need to run update-m1n1, which concatenates the new ones into the boot payload #asahi-dev · 2022-10-28 11:11
chadmedthatll do it :P #asahi-dev · 2022-10-28 11:11
chadmeddid you update m1n1#asahi-dev · 2022-10-28 11:10
chadmedDT convention is to link VRMs to the cores, then describe the voltage and current at each opp in the opp table #asahi-dev · 2022-10-28 10:37
chadmedi wonder if it will fly upstream to have core.c check for opp-microwatt if it doesnt find opp-microvolt and only give up if _neither_ are present#asahi-dev · 2022-10-28 10:34
chadmedopp-microvolt = <1>; in every opp makes the em register successfully#asahi-dev · 2022-10-28 10:34
chadmedok yep that is precisely what the problem was#asahi-dev · 2022-10-28 10:08
chadmedthats very silly#asahi-dev · 2022-10-28 10:07
chadmedit might be because we havent any power regulators associated with the cpus/clusters, and the function assumes you do #asahi-dev · 2022-10-28 09:36
chadmedif im reading correctly, for some reason it just unconditionally fails if theres no opp-microvolt regardless of other props being present? #asahi-dev · 2022-10-28 09:35
chadmedkazuki: any idea why it would be failing on opp-microvolt? it should pass over that because theres no opp-microvolt prop#asahi-dev · 2022-10-28 07:54
chadmedseems to definitely be whatever pipewire does to get asoc to mute the stream. jack has significantly less clicking even at absolutely abhorrent volumes#asahi-dev · 2022-10-28 07:14
chadmedinteresting#asahi-dev · 2022-10-28 07:13
chadmedso i think its definitely something outside of the driver's remit