2022-03-05
00:24loki_val has joined #asahi-dev
00:27crabbedhaloablut has quit [Ping timeout: 480 seconds]
00:30phire has quit [Remote host closed the connection]
00:31phire has joined #asahi-dev
00:37gruetzkopf has quit [Server closed connection]
00:37gruetzkopf has joined #asahi-dev
01:13yuyichao_ has quit [Ping timeout: 480 seconds]
02:17user982492 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
02:20Emantor has quit [Quit: ZNC - http://znc.in]
02:20Emantor has joined #asahi-dev
03:31phiologe has joined #asahi-dev
03:34PhilippvK has quit [Ping timeout: 480 seconds]
03:59user982492 has joined #asahi-dev
05:06_alice is now known as arisu
05:11_alice has joined #asahi-dev
05:13ManuelQuinones[m] has joined #asahi-dev
06:29Gaelan_ has joined #asahi-dev
06:32Gaelan has quit [Ping timeout: 480 seconds]
06:50the_lanetly_052___ has joined #asahi-dev
06:59yuyichao_ has joined #asahi-dev
08:00j`eymaz: in the PCIe driver is this timeout a spec value, or just a reasonable timeout you chose https://github.com/torvalds/linux/blob/master/drivers/pci/controller/pcie-apple.c#L593 ?
08:26marcanfwiw, the power gpio stuff is using spec values, but yeah, I don't know about the link timeout
08:34___nick___ has joined #asahi-dev
08:34___nick___ has quit []
08:36___nick___ has joined #asahi-dev
08:53bisko has quit [Read error: Connection reset by peer]
08:55bisko has joined #asahi-dev
08:55user982492 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
09:32the_lanetly_052___ has quit [Ping timeout: 480 seconds]
09:32gladiac has joined #asahi-dev
09:46jannauthe keyboard controller get's at least told when the back light is switched on and off (binary)
09:53bisko has quit [Ping timeout: 480 seconds]
10:17kov has joined #asahi-dev
10:33trouter has quit [Quit: ZNC 1.8.2 - https://znc.in]
10:34trouter has joined #asahi-dev
10:55trouter has quit [Quit: ZNC 1.8.2 - https://znc.in]
10:56trouter has joined #asahi-dev
11:11j`eymarcan: disabling pcie and nvme, I get a resume from s2idle.. but then it appears unresponsive
11:12j`eythis is using the vuart with hv, so maybe there's an issue there, can try with the keyboard/fb in a bit
11:13marcan(there's no nice way to automate that right now due to the cpu switch command being a console exit behind the scenes... I just paste a pile of cpu(0)\nbt\ncpu(1)\n... )
11:13j`eyunresponsive in that when Im trying to type into picocom, no characters get written, which I think means the other end isnt accepting any?
11:15gtk2 has joined #asahi-dev
11:18j`eyok not the full output, but most of it https://paste.gg/p/anonymous/3a86c38b66f946cdac42a36b5f8fbb7e
11:20marcantry trace_device("/arm-io/aic", True) and see if you get activity when you send the first UART character after resume
11:20marcanif you only get one burst of activity and no more, then that means suspend/resume in the samsung uart driver is likely broken
11:21marcanwhich wouldn't be entirely surprising, especially since I mucked with that for the runtime-pm stuff and never tested it
11:23marcanif you want to trace vuart you have to do it in the C, since there's no way to trace it in python and still have the underlying emulation
11:27j`eyIm tempted to revert 0a11aa08f94fdb2b21429c7a5c5c83124b85250a tty: serial: samsung_tty: Support runtime PM
11:36svenbut even if you issue that identify ns list with nsid = 1 it replies different than what it's supposed to reply if it followed the nvme spec
11:37LuigyLeon[m] has joined #asahi-dev
11:42null has quit [Server closed connection]
11:42null has joined #asahi-dev
11:42marcan[ 5.110194] apple-dart b02f80000.iommu: translation fault: status:0x81000001 stream:1 code:0x1 (NO TTBR FOR IOVA) at 0xfffec000
11:47svennow I wonder what state is kept if you go through this real deep sleep thing (the one that's worse than non-retention wfi)
11:48svenbut i'd expect them to add the dart lock sequence to this hardware engine they have to restore some state like the boot vector at least
11:57svenaaaand time to recompile the entire kernel again because I changed a head file. I really need to move to compiling on the M1 :D
11:57mps has quit [Server closed connection]
11:58mps has joined #asahi-dev
12:07svenj`ey: yeah, it's just going to be annoying because i develop on macOs running on my macbook air and my target machine is the mini. so i'd have to reboot to the mini, sync files, compile there, sync files back, reboot again
12:17skrzyp has quit [Server closed connection]
12:17skrzyp has joined #asahi-dev
12:18marcansven: https://github.com/AsahiLinux/linux/commit/37da9b0065cb2cd40a1ddaaa7c27121db612a855
12:24Ziemas has quit [Server closed connection]
12:24Ziemas has joined #asahi-dev
12:31marcanj`ey: https://github.com/AsahiLinux/linux/commit/ea0cfdc040fec6f9100b0ee8d589364c330f2134
12:32marcanI looked at what resume was doing and noticed it was first restoring the IRQ flags in resume_noirq, then calling reset in resume which masked with ucon_mask
12:33marcanthose flags are apple-specific so it doesn't apply to other chips (though one other variant uses ucon_mask for something else)
12:34marcanwhich might be more painful, but maybe not *that* bad since all the scaffolding for suspend/resume should already be there?
12:38marcansven: if it does we can just stop powergating it for now, which we probably want to anyway for "normal" s2idle since people probably want wake-on-wlan?
12:40sventhough I think the main reason we wanted to avoid pulling all that crap into linux where tunables and fuses and well... we'll likely need those two for atcphy anyway
12:40svenI could *probably* get away without the fuses and some tunables but I feel like there's a reason why macOS also tears down the entire atcphy when a cable is unplugged just like usb
12:45svenbtw. regarding those tunables, I could either pass them through as apple,tunable-<apple-names> or merge some of those together. e.g. apple,tunable-ln1-usb which would contain USB_LN1_AUSPMA_TX_TOP, USB_LN1_AUSPMA_RX_TOP, USB_LN1_AUSPMA_RX_SHM and USB_LN1_AUSPMA_RX_EQ which are always applied in that order
12:48svenat least for the lane ones there isn't afaict. still need to check if the "always apply these after a reset" ones are applied in a different order for thunderbolt
12:53kaprests has quit [Server closed connection]
12:53kaprests has joined #asahi-dev
12:58marcanso I'm getting about 5W power draw in suspend, which is not great. I wonder how much of that is the CPUs...
12:59marcanso smp_start_secondaries makes *no* difference to power usage, which is using deep sleep, so at least now we know that's pretty good
13:00lewurm has quit [Server closed connection]
13:00lewurm has joined #asahi-dev
13:03marcanthat might make the case for doing an ugly hack in linux to support deep sleep for the time being, that's a significant win and should be trivial to just do as a throwaway patch
13:03_jannau_ has quit [Server closed connection]
13:03_jannau_ has joined #asahi-dev
13:05marcanand then of course there's the screen, can't do much about that until the DCP driver is in place, but I bet that'll save a bunch of power too
13:05marcansince putting 3K onto the screen all the time can't be cheap, and in FB mode it has to keep refreshing from RAM, it can't know you didn't touch it
13:07marcananyway, with the deep sleep hack I would expect at least 24h of sleep battery life, which is enough to get you through randomly putting the laptop away for a day
13:07marcanmaybe more since these are USB-C level measurements, there's going to be some loss and some power spent on trickle charging the battery
13:09Glanzmannmarcan: kettenis meassured the screen power to be aroung ~ 1 Watts. (that is by toggling the backlight gpio).
13:13jato has quit [Server closed connection]
13:13jato has joined #asahi-dev
13:25arctan95 has quit [Quit: Connection closed for inactivity]
13:37vitorbarth has joined #asahi-dev
13:38j`eysven: you might need something like 4ae85b2ba1debea2ce828ca24de73ce49e41e516 in the efuses driver
13:39svenoh, you mean https://github.com/AsahiLinux/linux/commit/b703677f341fa6eec75aea96c0847257cd21217c#diff-cf630c5ac133b89cb3f8430da9f0e91ddd58685cee59406d9770572d5493b873R45? :P
13:42marcananyway, turning stuff off I can get it down to 3.5W in m1n1, which is still kinda high but that's 21h battery runtime
13:45svenusb 3-1: new high-speed USB device number 2 using xhci-hcd <-- why doesn't atcphy like me :-(
13:49* alyssawonders why she can't find data on memory bandwidth / power consumption anymore grumble
13:49svenj`ey: added everything now hopefully https://github.com/AsahiLinux/linux/commit/dce2da78500b50ed35511fd0fc5a3f84732ad047#diff-cf630c5ac133b89cb3f8430da9f0e91ddd58685cee59406d9770572d5493b873R68
14:07Shiz has quit [Server closed connection]
14:07Shiz has joined #asahi-dev
14:11vitorbarth has quit [Read error: Connection reset by peer]
14:16marcanok, so the lowest I can get things is 3.3W, but there's like a whole 1W unaccounted for in the SPMU for some reason, so I don't know what that's about (assuming I guessed the SMC keys right, of course)
14:17marcanthen again, the way I brute force powered things down via PMGR and the PMU GPIOs may not be correct :p
14:21jannauthis sounds like I should make sure that the current dcp driver and m1n1 dcp changes are always on github
14:24marcanthere's about 1W going to the SoC CLVRs, which also doesn't sound right for mostly being idle
14:33marcananyway, dunno, will have to cross check this with osx and see if there's some magic that makes it use less power
14:35the_lanetly_052___ has joined #asahi-dev
14:46jix has quit [Server closed connection]
14:46jix has joined #asahi-dev
14:55psykose has quit [Remote host closed the connection]
14:55psykose has joined #asahi-dev
14:57psykose has quit [Remote host closed the connection]
14:57psykose has joined #asahi-dev
15:29akemin_dayo has quit [Remote host closed the connection]
15:30akemin_dayo has joined #asahi-dev
15:44XeR has quit [Server closed connection]
15:44XeR has joined #asahi-dev
16:10jannaualyssa: https://github.com/jannau/linux/tree/bits/200-dcp needs https://github.com/jannau/m1n1/tree/dcp
16:11jannauminor merge conflicts in dart/dts, merged into AsahiLinux/asahi in https://github.com/jannau/linux/tree/asahi-dcp
16:20maz has quit [Server closed connection]
16:23maz has joined #asahi-dev
16:31bisko has joined #asahi-dev
16:34the_lanetly_052__ has joined #asahi-dev
16:35jannauHV dcp tracing doesn't blow up on t600x. anyone willing to bet if the linux dcp driver will just work after adding the missing nodes to the device
16:39bisko has quit [Ping timeout: 480 seconds]
16:40the_lanetly_052___ has quit [Ping timeout: 480 seconds]
16:44j`ey has quit [Server closed connection]
16:44j`ey has joined #asahi-dev
17:09vup has quit [Server closed connection]
17:22bisko has joined #asahi-dev
17:24VinDuv has quit [Server closed connection]
17:25VinDuv has joined #asahi-dev
17:30jannaudcpep_cb_rt_bandwidth asks for the two missing registers and we map the disp0 mmio regs for dcp
17:32marcananyway, I need to get some sleep, and I think I'll disconnect for tomorrow... it's apartment cleanup day ;)
17:34vup has joined #asahi-dev
17:38Nspace has quit [Server closed connection]
17:38Nspace has joined #asahi-dev
17:39tanty has quit [Server closed connection]
17:40tanty has joined #asahi-dev
17:52os has quit [Server closed connection]
17:53os has joined #asahi-dev
17:56sandyriver[m] has joined #asahi-dev
18:04agraf has quit [Server closed connection]
18:04agraf has joined #asahi-dev
18:07_andy_t_ has quit [Server closed connection]
18:08_andy_t_ has joined #asahi-dev
18:18ar has quit [Server closed connection]
18:19ar has joined #asahi-dev
18:28user982492 has joined #asahi-dev
18:34bisko has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
18:35bisko has joined #asahi-dev
18:41chengsun has quit [Quit: Quit]
18:42chengsun has joined #asahi-dev
19:01jvsg[m] has joined #asahi-dev
19:01user982492 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
19:02sandyriver[m] is now known as peer[m]
19:09xerpi[m] has quit [Server closed connection]
19:09xerpi[m] has joined #asahi-dev
19:12bisko has quit [Remote host closed the connection]
19:13M1bn3mar[m] has quit [Server closed connection]
19:13M1bn3mar[m] has joined #asahi-dev
19:14bisko has joined #asahi-dev
19:18ella-0[m] has quit [Server closed connection]
19:18ella-0[m] has joined #asahi-dev
19:19jannaualyssa: still struggling with waking dcp up. even gone back to walking tables for dcp-dart
19:30bisko has quit [Ping timeout: 480 seconds]
19:41emilazy has quit [Server closed connection]
19:41emilazy has joined #asahi-dev
19:43HayashiEsme[m] has quit [Server closed connection]
19:43HayashiEsme[m] has joined #asahi-dev
19:48jevinskie[m] has quit [Server closed connection]
19:48jevinskie[m] has joined #asahi-dev
19:59kovX failed to come up, tried weston, then I noticed the device nodes were missing, after a bit of banging my head against menuconfig I realized the new dt had the backlight stuff and could it be gpio_backlight missing? that made it work
20:01j`eylooking at 46ff9b5bb0a48baba8bd69db3b53a6604fcae160 makes it looks like that case should be handled
20:16user982492 has joined #asahi-dev
20:26dhewg has quit [Server closed connection]
20:26dhewg has joined #asahi-dev
20:26bisko has joined #asahi-dev
20:40fridtjof[m] has quit [Server closed connection]
20:40fridtjof[m] has joined #asahi-dev
21:07___nick___ has quit [Ping timeout: 480 seconds]
21:23gladiac has quit [Quit: k thx bye]
21:32cde[m] has quit [Server closed connection]
21:32cde[m] has joined #asahi-dev
21:41svenouch. that essentially means “don’t powergate DCP” which is probably require because DCP isn’t completely shut down
22:59psykose has quit [Remote host closed the connection]
23:00psykose has joined #asahi-dev
23:01yuyichao has joined #asahi-dev
23:03yuyichao_ has quit [Ping timeout: 480 seconds]