#
…

2023-02-05

00:27hertz has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
00:33seeeath has joined #asahi-dev
00:34chadmed has joined #asahi-dev
00:35seeeath has quit []
00:39chadmedjeffmiw: can i suggest making the dt binding an array of elements which contain a key and label? that should be a little nicer to read too
00:41chadmedalso the smc core driver has its own float conversion function now with scaling support so its probably best to use that instead of duplicating that functionality in the hwmon driver
00:44seeeath has joined #asahi-dev
00:46seeeath has quit []
00:59qyliss has quit [Remote host closed the connection]
01:01qyliss has joined #asahi-dev
01:10bisko has joined #asahi-dev
01:12seeeath has joined #asahi-dev
01:15seeeath has quit []
01:15seeeath has joined #asahi-dev
01:15seeeath has quit []
01:18bisko has quit [Ping timeout: 480 seconds]
01:26amarioguy has quit [Remote host closed the connection]
01:53bisko has joined #asahi-dev
02:01bisko has quit [Ping timeout: 480 seconds]
02:21salimterryli has quit [Ping timeout: 480 seconds]
02:31chadmed has quit [Remote host closed the connection]
02:32chadmed has joined #asahi-dev
03:06hertz has joined #asahi-dev
03:14bluetail has quit [Quit: The Lounge - https://thelounge.chat]
03:24eiln has joined #asahi-dev
03:25eilnwhat's the preferred way to send a mini patch? would like to send the power/dpe tunables
03:50eiln has quit [Remote host closed the connection]
04:22Keyaedisa has joined #asahi-dev
04:23Keyaedisahello, i have experience with arch linux and have jus got a 2023 M2 Mac Macbook Pro. i'd like to know if i could be of any help as id like to get arch running on this macbook
04:40bluetail has joined #asahi-dev
04:46mini0n has quit [Remote host closed the connection]
05:05Keyaedisa has quit [Remote host closed the connection]
05:18Keyaedisa has joined #asahi-dev
05:30bisko has joined #asahi-dev
05:30Keyaedisa has quit [Remote host closed the connection]
05:43Keyaedisa has joined #asahi-dev
05:51marcanchadmed, povik: what's the status for the visense/speaker safety stuff? I'm thinking I want to work on that myself soon
05:51bisko has quit [Ping timeout: 480 seconds]
05:51marcannot sure if this should be part of the production daemon or a separate research thing in Python, but we need a way to play test tones and do temperature measurements to validate the models
05:52Keyaedisa has quit [Ping timeout: 480 seconds]
05:52marcan(temperature can be estimated from VI data if the signal is a well-behaved test tone)
05:52marcanand then I want to use that to derive models for the M1 laptops that don't have them
05:52bisko has joined #asahi-dev
05:53cylm_ has quit [Ping timeout: 480 seconds]
05:55Keyaedisa has joined #asahi-dev
05:56marcanpovik: I think you asked and I'm not sure if I ever answered, but I just checked and at least j313 does have feedback from the speaker amps wired up back to the SoC
06:00bisko has quit [Ping timeout: 480 seconds]
06:12maor26 has joined #asahi-dev
06:13chadmedim waiting for povik to wire up the kernel driver so i can fix the daemon and then validate things
06:14eiln has joined #asahi-dev
06:15chadmedthe rust bindings for alsa-lib's PCM interface are far more complete than CTL was and getting samples seems pretty simple to do so once the kernel side is done it shouldnt take much to rejig the daemon and then we can get testing
06:17Keyaedisa has quit [Remote host closed the connection]
06:17bisko has joined #asahi-dev
06:17chadmedi dont think we landed on a way to gate full output unless the daemon is running so it might be time to have that discussion in earnest too
06:25marcanI'm happy to come up with something while I hack on it, it shouldn't be too difficult
06:25bisko has quit [Ping timeout: 480 seconds]
06:30bisko has joined #asahi-dev
06:38bisko has quit [Ping timeout: 480 seconds]
06:39eilnmarcan: an engine failure can only be recovered via power domain reset, how would i go about this?
06:39eilntakes only a single bit off in the convolution param descriptor (i guess microcode equivalent?)
06:40eilnive seen it from apple's own compiler
06:41eilnthe SYS pd shared with dart isn't needed for recovery, so no ctx/parents involved
06:42marcaneiln: what do you mean? how to actually trigger the reset?
06:42marcanif this is a pmgr power domain, it's hooked up as a reset provider so you can use the reset API
06:43marcansee nvme/ANS which uses that feature
06:43marcanyou need to declare resets = <> in the DT and then use the standard APIs
06:44eilntheyre all pmgr pds but aren't described in the dt
06:44eilnthanks, looking into it rn
06:45marcanoh, you're directly poking the PDs? if it's something the driver has to do they need to be added to the DT and you should use the standard APIs for that
06:45marcanwe don't want drivers poking PDs directly (yes apple does it, because their drivers are a mess)
06:48eilnthey're like sub-power domains w/ burst-style mgmt @ the kext level
06:49Keyaedisa has joined #asahi-dev
06:51marcanburst-style?
06:51marcanif the registers are part of the pmgr area and follow the same rules as the regular PDs they should be regular PD instances in the DT
06:51eilnshut off after every firmware call w/ 0.5sec-ish delay
06:52marcanin Linux land that's called runtime PM with autosuspend delay
06:52marcanso you *definitely* want to use the pmgr driver and hook it up like that then
06:52marcanDCP does the same thing
06:52eilni've added them as normal PDs https://github.com/eiln/linux.git
06:53marcanyeah, that looks right :)
06:53marcanso if you need resets on those, just also add them into a resets = <> prop
06:54marcanand then the reset APIs should just work
06:54marcanare the 6 PDs arbitrarily numbered?
06:57marcanyou might want to add power-domain-names / reset-names and label them, so future bindings don't depend on strict ordering (you don't have to *use* that today, as long as the binding specifies a strict ordering today the driver can just use integer indices, it's more for future-proofing)
06:57marcangrep around othe DTs for examples
07:00Keyaedisa has quit [Ping timeout: 480 seconds]
07:11Keyaedisa has joined #asahi-dev
07:13eiln has quit [Remote host closed the connection]
07:19Keyaedisa has quit [Ping timeout: 480 seconds]
07:27Keyaedisa has joined #asahi-dev
07:46povikmarcan: i did ask and you haven't answered, but since then i started getting samples on j274 so indeed it looks like it's wired up on all models!
07:46povikthe status is that it's pretty much ready in https://github.com/povik/linux/tree/ivsense
07:46povik(at least on j314)
07:46poviki have been sitting on it as i still want to polish a few things
07:46marcanthink it's good enough to start doing experiments at least?
07:47marcan(we need to do a bunch of modeling/validation/etc before we can ship this anyway)
07:47povikwell, i have been doing some experiments myself :p
07:47povikthis counts joules...
07:48povikmarcan: that repo is where the research you may need to do can go as well :)
07:51marcanlet's go with that then, calibration stuff in that repo and the Rust stuff chadmed is working on for production
07:52marcanmight start poking at this tomorrow
07:53marcanfirst step is to replicate the expected model Apple uses and plug in their numbers and see if we come up with sensible temperature estimates that match reality
07:53marcanthen come up with some sensible governor algorithm for the volume and prove it works
07:54marcanthen port it to Rust and figure out how we want to do the safety interlock
07:54povikbtw to bring it up on a new model, you need to: 1. describe the sense data slots in DT; 2. uncomment the ISENSE/VSENSE switches being disabled in macaudio
07:55marcanand finally I'll have to do some ad-hoc "oven" tests on the M1 laptops to get a calibration for the temperature measurement we can then use to derive a model
07:55marcanpovik: got it :)
07:55povikerr, i mean you need to *comment out* disabling of the switches
07:58chadmedas a toy implementation ive just been using the thermal resistance of the voice coil as provided by apple to estimate temperature from a given power level but if we can get something more accurate then it shouldnt be too much effort to use that instead
07:58marcanin principle it's a 2-stage model (voice coil and magnet temp)
07:58marcanwhich is what I intend to implement
07:59marcanfor temperature measurement we need the voice coil resistance and tempco, which is known for the 14"+ laptops but not the 13" ones. resistance can just be measured with visense, tempco needs doing that at a few temperatures
08:00marcanI'll try to come up with something sensible for that (probably involving a thermocouple, running the tests immediately after power-on for an ambient-temperature laptop, and sticking it in a few environments for an hour before each test
08:00marcanat this time of the year, outdoors vs. my shower room with the clothes drying heater fan turned on should give decent range :p
08:01povikmeasurements on a laptop that's initially freezing might be the most accurate
08:01povikfor estimating the parameters of the model
08:01marcanfreezing as in sub-zero?
08:01chadmedthatll be great for the battery :P
08:01poviknot necessarily, just very cold :p
08:01marcanI mean I can certainly do a fridge test :p
08:02marcanI just need to get myself some kind of logging setup to make sure whatever environment I pick the temperature is stable enough to guarantee it reaches equilibrium
08:13marcanhttps://www.amazon.co.jp/dp/B088H5KFT9/ that looks sensible, they have the (trivial) USB-serial protocol on their website
08:16marcanmeh, I think it ships from china, no prime and expensive shipping...
08:18Keyaedisa has quit [Remote host closed the connection]
08:18Keyaedisa has joined #asahi-dev
08:18Keyaedisa has quit [Remote host closed the connection]
08:19Keyaedisa has joined #asahi-dev
08:26marcanaliexpress it is, less than half the price for something similar and not much slower
08:26bisko has joined #asahi-dev
08:35Keyaedisa has quit [Ping timeout: 480 seconds]
08:44Keyaedisa has joined #asahi-dev
08:45bisko has quit [Ping timeout: 480 seconds]
08:56bisko has joined #asahi-dev
09:03nullroute has quit [Read error: Connection reset by peer]
09:08bisko has quit [Ping timeout: 480 seconds]
09:14nullroute has joined #asahi-dev
09:16bisko has joined #asahi-dev
09:16bisko has quit []
09:20nullroute has quit [Read error: Connection reset by peer]
09:29nullroute has joined #asahi-dev
09:36jluthra_ has quit [Remote host closed the connection]
09:36jluthra_ has joined #asahi-dev
09:37nullroute has quit [Ping timeout: 480 seconds]
09:47nullroute has joined #asahi-dev
09:59hexafox has joined #asahi-dev
10:13Keyaedisa has quit [Ping timeout: 480 seconds]
10:23Keyaedisa has joined #asahi-dev
10:46Keyaedisa has quit [Ping timeout: 480 seconds]
11:26roxfan has joined #asahi-dev
11:28maor26 has quit [Read error: Connection reset by peer]
11:29maor26 has joined #asahi-dev
12:01Keyaedisa has joined #asahi-dev
12:09Keyaedisa has quit [Ping timeout: 480 seconds]
12:18Keyaedisa has joined #asahi-dev
12:26Keyaedisa has quit [Ping timeout: 480 seconds]
12:29hexafox has quit [Ping timeout: 480 seconds]
12:40Keyaedisa has joined #asahi-dev
12:50Keyaedisa has quit [Ping timeout: 480 seconds]
13:01Keyaedisa has joined #asahi-dev
13:12Keyaedisa has quit [Ping timeout: 480 seconds]
13:18svenIOMFBStatus VideoInterfaceIOAV::plug_gated(IOAVVideoInterface *): display HPD asserted
13:18sven*almost*
13:19svendoesn't get any modes yet, either it needs additional DPTX calls or I'm missing something inside NHI
13:23Keyaedisa has joined #asahi-dev
13:33Keyaedisa has quit [Ping timeout: 480 seconds]
13:42Keyaedisa has joined #asahi-dev
13:50Keyaedisa has quit [Ping timeout: 480 seconds]
13:51Keyaedisa has joined #asahi-dev
13:58bcrumb has joined #asahi-dev
14:01Keyaedisa has quit [Ping timeout: 480 seconds]
14:03Keyaedisa has joined #asahi-dev
14:13bcrumb has quit [Quit: WeeChat 3.8]
14:15Keyaedisa has quit [Ping timeout: 480 seconds]
14:20maor has joined #asahi-dev
14:23Keyaedisa has joined #asahi-dev
14:26maor has quit [Read error: Connection reset by peer]
14:27maor26 has quit [Ping timeout: 480 seconds]
14:28maor26 has joined #asahi-dev
14:43maor26 has quit [Read error: Connection reset by peer]
14:45maor26 has joined #asahi-dev
14:54cylm has joined #asahi-dev
14:54nela has quit [Ping timeout: 480 seconds]
15:02maor has joined #asahi-dev
15:09maor26 has quit [Ping timeout: 480 seconds]
15:17maor has quit [Read error: Connection reset by peer]
15:18maor has joined #asahi-dev
15:19maor26 has joined #asahi-dev
15:26maor has quit [Ping timeout: 480 seconds]
15:34maor26 has quit [Read error: Connection reset by peer]
15:35maor26 has joined #asahi-dev
15:49kit_ty_kate1 has joined #asahi-dev
15:50kit_ty_kate has quit [Remote host closed the connection]
15:58Keyaedisa has quit [Ping timeout: 480 seconds]
16:05Keyaedisa has joined #asahi-dev
16:14nela has joined #asahi-dev
16:23Keyaedisa has quit [Ping timeout: 480 seconds]
16:30bcrumb has joined #asahi-dev
16:32Keyaedisa has joined #asahi-dev
16:32roxfan has quit [Ping timeout: 480 seconds]
16:34hertz has quit [Ping timeout: 480 seconds]
16:37hertz has joined #asahi-dev
16:44bcrumb has quit [Quit: WeeChat 3.8]
16:54bcrumb has joined #asahi-dev
17:01bcrumb has quit [Quit: WeeChat 3.8]
17:04bcrumb has joined #asahi-dev
17:10Keyaedisa has quit [Ping timeout: 480 seconds]
17:11bcrumb has quit [Quit: WeeChat 3.8]
17:13bcrumb has joined #asahi-dev
17:14bcrumb has quit []
17:16Keyaedisa has joined #asahi-dev
17:24Keyaedisa has quit [Ping timeout: 480 seconds]
17:34Keyaedisa has joined #asahi-dev
17:44Keyaedisa has quit [Ping timeout: 480 seconds]
17:45bcrumb has joined #asahi-dev
18:06jeffmiwchamed: why not, do you have an example of such example of dt binding with array of 2 elements ? I will look for it but if you have something handy that will help. I'll check for the float conversion function in smc
18:07jeffmiwI was working from an old tag. I'm planning to move to the edge one as a next step
18:15bcrumb has quit [Quit: WeeChat 3.8]
18:53bcrumb has joined #asahi-dev
18:55Illya is now known as jdek
18:56seeeath has joined #asahi-dev
18:56jdek is now known as illya
18:56illya is now known as jdek
18:58jdek has left #asahi-dev [#asahi-dev]
19:06seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
19:08Keyaedisa has joined #asahi-dev
19:08bcrumb has quit [Quit: WeeChat 3.8]
19:16Keyaedisa has quit [Ping timeout: 480 seconds]
19:19amarioguy has joined #asahi-dev
19:23Keyaedisa has joined #asahi-dev
19:25zjstraus has joined #asahi-dev
19:31Keyaedisa has quit [Ping timeout: 480 seconds]
19:42Keyaedisa has joined #asahi-dev
19:55Keyaedisa has quit [Remote host closed the connection]
19:56Keyaedisa has joined #asahi-dev
19:57Keyaedisa has quit [Remote host closed the connection]
19:58Keyaedisa has joined #asahi-dev
20:07Keyaedisa has quit [Ping timeout: 480 seconds]
20:17seeeath has joined #asahi-dev
20:50chadmedjeffmiw: have a look at the opp table for a good example of what i mean
20:52Keyaedisa has joined #asahi-dev
21:01Keyaedisa has quit [Ping timeout: 480 seconds]
21:06seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
21:06seeeath has joined #asahi-dev
21:14seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
21:14seeeath has joined #asahi-dev
21:18povikprobable fix for the stuck ADMAC IRQs: https://tpaste.us/Vqbz
22:40mkurz has quit [Ping timeout: 480 seconds]
22:57seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
22:58seeeath has joined #asahi-dev
23:00yrlf has quit [Quit: The Lounge - https://thelounge.chat]
23:27maor26 has quit [Quit: Leaving]
23:38Keyaedisa has joined #asahi-dev
…