#
#asahi-dev · 2023-04-17 13:05
svenbah
#asahi-dev · 2023-04-17 13:05
svenit had some reference about some
#asahi-dev · 2023-04-17 13:04
sventrue, maybe that was full sleep
#asahi-dev · 2023-04-17 13:04
marcanI did just find at least one power-related bit we're not setting properly
#asahi-dev · 2023-04-17 13:04
marcanI don't think macOS uses that in normal system idle, otherwise the hypervisor would go nuts
#asahi-dev · 2023-04-17 13:03
marcanI thought that was outright system sleep
#asahi-dev · 2023-04-17 13:02
svenI vaguely remember seeing something about that in I think some xnu source code they forgot to censor
#asahi-dev · 2023-04-17 13:01
kettenisfor cpu0 that will require assistence from m1n1
#asahi-dev · 2023-04-17 13:00
kettenisand you need to bring them back up starting from rvbar
#asahi-dev · 2023-04-17 13:00
kettenisyes, there should be a state where the cores lose all state
#asahi-dev · 2023-04-17 12:59
marcanapple definitely does something to let clusters fully power down, otherwise I wouldn't get 100+ hours of idle battery
#asahi-dev · 2023-04-17 12:58
kettenisThis "deep" wfi state is probably designed to allow boosting of one of the other cores in the cluster
#asahi-dev · 2023-04-17 12:57
kettenisThis can't power off the cluster completely since the cores still maintain some state
#asahi-dev · 2023-04-17 12:57
kettenisregarding the power savings for deep wfi; I didn't get much savings with that when I played with it under OpenBSD
#asahi-dev · 2023-04-17 12:54
marcanplus with the linux timekeeping mess we really need cpuidle anyway
#asahi-dev · 2023-04-17 12:54
marcanno worries, not blaming it on you :)
#asahi-dev · 2023-04-17 12:53
kettenismarcan: sorry, I started writing things down, but got distracted by other stuff again
#asahi-dev · 2023-04-17 12:46
marcanI should pull down some newer xnu sources and see if there's anything interesting, haven't looked in ages
#asahi-dev · 2023-04-17 12:45
robhermarcan: I'll look into it.
#asahi-dev · 2023-04-17 12:42
marcanthis is on t6021 btw, maybe there's something else broken here
#asahi-dev · 2023-04-17 12:41
chadmedits gotta be more than that surely, at least on this machine the thing is stone cold now idling and watching 1080p30 video barely warms it
#asahi-dev · 2023-04-17 12:41
marcan1.5W of CLVR power usage suggests something is still wrong though, I would expect that to drop to ~0 if things were properly and fully shutting down
#asahi-dev · 2023-04-17 12:40
marcanwhich isn't... great but it's not nothing
#asahi-dev · 2023-04-17 12:40
marcanso testing with the smc debug print thing, it drops about 1W of power when I enable the idle states
#asahi-dev · 2023-04-17 12:39
chadmedi had some patches that added enough hwmon to get the key that measures that
#asahi-dev · 2023-04-17 12:39
chadmedi want to look at how much power the cores are pulling down without the noise of the rest of the system
#asahi-dev · 2023-04-17 12:36
marcanthe debug mode thing I have isn't enough?
#asahi-dev · 2023-04-17 12:35
chadmedive lost my smc power meter patches so ill rebuild those and do some more testing later
#asahi-dev · 2023-04-17 12:35
chadmedi mean its doing something so thats good
#asahi-dev · 2023-04-17 12:34
marcanyeah something is not quite right, I think
#asahi-dev · 2023-04-17 12:33
chadmedinterestingly the hitching on various animations around the desktop with EAS is now gone with no other kernel changes so... neat
#asahi-dev · 2023-04-17 12:31
chadmedthe part of the keyboard over the soc is nice and cold now though so it must be other stuff sucking down juice
#asahi-dev · 2023-04-17 12:30
chadmedi think its a little bit down but not by a meaningful amount
#asahi-dev · 2023-04-17 12:30
chadmedmarcan: system idle on j314 is ~5.5-6.1 W which still seems kinda high
#asahi-dev · 2023-04-17 12:26
_jannau_connected to i2c5. aqc-a on the mac studio
#asahi-dev · 2023-04-17 12:24
_jannau_might be i2c
#asahi-dev · 2023-04-17 12:23
_jannau_I think there was something in the ADT which hinks how the aqantia nic is connected for the lights out management
#asahi-dev · 2023-04-17 12:20
marcanbut I would expect this to be eventually fired from the Aqantia NICs so... how would that work? do they have an outright SMC sidechannel via i2c or something?
#asahi-dev · 2023-04-17 12:20
marcanit's an outright SMC key though, so... who writes it? it would have to be another coprocessor via SMC sidechannel I think...
#asahi-dev · 2023-04-17 12:19
marcanoooh this is interesting, there's an SMC key for remote management that can trigger system actions (boot, reboot, and even ask the OS to sleep)
#asahi-dev · 2023-04-17 12:13
marcanI'm going to pull up the old SMC disasm and see if I find anything useful... though I kind of doubt it, there aren't many event sources to begin with
#asahi-dev · 2023-04-17 12:10
marcanalternatively I'm sure the RTC or watchdog could be used for this but ugh, if this is going to be cross-driver we might as well figure out how to do it with core timekeeping and the arch timer
#asahi-dev · 2023-04-17 12:09
marcanit would be nice if we had a way to make SMC annoy us periodically some way, then it could all be done within the driver
#asahi-dev · 2023-04-17 12:09
marcanyeah, the problem is actually setting up some kind of periodic timer
#asahi-dev · 2023-04-17 12:01
_jannau_CLOCK_BOOTTIME is supposed run during suspend if you can use that there. doesn't help of course for the battery state control when the system is actually suspended
#asahi-dev · 2023-04-17 11:56
marcanthat also means the battery charge state control won't work unfortunately... we need to figure out something for that
#asahi-dev · 2023-04-17 11:50
marcanlol, implementing proper cpuidle also caused timekeeping to stop properly during suspend now, which means the SMC power logging doesn't work :D
#asahi-dev · 2023-04-17 11:48
marcanjannau: got some splat on suspend: https://mrcn.st/p/3e6l4HU2 (still worked though)
#asahi-dev · 2023-04-17 11:46
marcanhaven't tested actual idle power consumption yet :)
#asahi-dev · 2023-04-17 11:45
marcanpushed t602x/bringup with jannau's DCP 13.3 conversion (tested working) and a cpuidle driver

plus ›