#
…

2023-04-26

00:11kesslerdupont has quit [Ping timeout: 480 seconds]
00:11psykose_ has quit [Remote host closed the connection]
00:12psykose has joined #asahi-dev
00:12kesslerdupont has joined #asahi-dev
00:13kesslerdupont has quit []
00:30abd has joined #asahi-dev
00:37nsklaus has quit [Ping timeout: 480 seconds]
00:45nsklaus has joined #asahi-dev
00:53nsklaus has quit [Ping timeout: 480 seconds]
01:02nsklaus has joined #asahi-dev
01:03bps has joined #asahi-dev
01:04bluetail has quit [Quit: The Lounge - https://thelounge.chat]
01:10nsklaus has quit [Ping timeout: 480 seconds]
01:18i509vcb has joined #asahi-dev
01:19nsklaus has joined #asahi-dev
01:27nsklaus has quit [Ping timeout: 480 seconds]
01:36nsklaus has joined #asahi-dev
01:44nsklaus has quit [Ping timeout: 480 seconds]
01:45bps has quit [Ping timeout: 480 seconds]
01:47axboejannau: yep using xfce4, but seems like that should not be related here. pretty normal setup I think, debian testing. using the lid to suspend/resume, yep
01:48axboekernel .config was posted in case there's something there, I can also try the asahi one just in case?
01:49axboehadn't had time to further fiddle with this today :/
01:51nsklaus has joined #asahi-dev
02:00gabuscus has quit []
02:01nsklaus has quit [Ping timeout: 480 seconds]
02:02axboejannau: tested without lid, same issue
02:10nsklaus has joined #asahi-dev
02:13chadmed_ has joined #asahi-dev
02:14gabuscus has joined #asahi-dev
02:18nsklaus has quit [Ping timeout: 480 seconds]
02:22axboemarcan: tried the "default boot into osx, boot linux and trigger it"
02:22axboedidn't get anything out of osx
02:22axboeused the mem > state way to suspend, and on the third suspend, screen went dark as usual, but then rebooted
02:22axboeso definitely suspend related, not resume - unless the previous resume messed something up...
02:23axboealso enabled always-on for basically anything I saw in that trace I posted in here
02:23axboeand still triggers
02:24axboethis is on top of pmgr-stuff added to the mix
02:25axboeeven updated mesa since I needed to do that anyway
02:25axboeas far as I know I'm fully current on m1n1/u-boot/mesa
02:25axboeosx shows my debian/asahi boot as 12.3 fwiw
02:26nsklaus has joined #asahi-dev
02:28axboeall of /proc/device-tree/ in case there's anything useful in there
02:29axboecat git/m1n1/build/m1n1.bin git/asahi-linux/arch/arm64/boot/dts/apple/t6001-j316c.dtb git/u-boot/u-boot-nodtb.bin
02:29axboethat's my payload
02:34nsklaus has quit [Ping timeout: 480 seconds]
02:38ncopa has quit [Remote host closed the connection]
02:42nsklaus has joined #asahi-dev
02:50nsklaus has quit [Ping timeout: 480 seconds]
02:58nsklaus has joined #asahi-dev
03:08nsklaus has quit [Ping timeout: 480 seconds]
03:12nsklaus has joined #asahi-dev
03:21nsklaus has quit [Ping timeout: 480 seconds]
03:30nsklaus has joined #asahi-dev
03:38nsklaus has quit [Ping timeout: 480 seconds]
03:40bluetail has joined #asahi-dev
03:46nsklaus has joined #asahi-dev
03:54nsklaus has quit [Ping timeout: 480 seconds]
04:02nsklaus has joined #asahi-dev
04:10nsklaus has quit [Ping timeout: 480 seconds]
04:19nsklaus has joined #asahi-dev
04:27nsklaus has quit [Ping timeout: 480 seconds]
04:36nsklaus has joined #asahi-dev
04:44nsklaus has quit [Ping timeout: 480 seconds]
04:52nsklaus has joined #asahi-dev
04:59abd has quit [Remote host closed the connection]
05:01nsklaus has quit [Ping timeout: 480 seconds]
05:08nsklaus has joined #asahi-dev
05:16jannauovernight suspend/resume worked as well, not surprising if the issue is triggered by suspend
05:17nsklaus has quit [Ping timeout: 480 seconds]
05:18jannaudifference is kernel config and m1n1 payload. I boot kernel and initrd directly instead of u-boot
05:19jannauI don't see how userspace would make a difference unless it arms the watchdog
05:25nsklaus has joined #asahi-dev
05:27jannauaxboe: you want to compress the u-boot payload. unrelated to the suspend issue but if you switch to the standard chainloading setup a compressed u-boot is required to allow reading appended variables
05:32salimterryli has quit [Quit: ZNC - https://znc.in]
05:34nsklaus has quit [Ping timeout: 480 seconds]
05:34salimterryli has joined #asahi-dev
05:38jannaususpend doesn't seem to work at all with axboe's config (+ samsung serial)
05:42nsklaus has joined #asahi-dev
05:44jannauaxboe: if you want to have wlan ready at boot instead of waiting for it a couple of minutes you need to disable CONFIG_FW_LOADER_USER_HELPER
05:48jannauthe ongoing wifi firmware loading appears to break suspend here
05:50nsklaus has quit [Ping timeout: 480 seconds]
05:51jannauor at least delays entering suspend
05:59nsklaus has joined #asahi-dev
06:00jannauI hit however a SError, unsure if it strictly is suspend + CONFIG_FW_LOADER_USER_HELPER in progress related or if it was something I did because it stopped after file system sync
06:01ncopa has joined #asahi-dev
06:07nsklaus has quit [Ping timeout: 480 seconds]
06:11jannaususpend/resume is rock solid after disabling CONFIG_FW_LOADER_USER_HELPER but I'm not sure how that would explain issues after more than a few minutes of uptime
06:16pthariensflame has joined #asahi-dev
06:16pthariensflame has quit []
06:16nsklaus has joined #asahi-dev
06:20bps has joined #asahi-dev
06:25nsklaus has quit [Ping timeout: 480 seconds]
06:32chadmed_ has quit [Quit: Page closed]
06:36nsklaus has joined #asahi-dev
06:36MajorBiscuit has quit [Ping timeout: 480 seconds]
06:44nsklaus has quit [Ping timeout: 480 seconds]
06:52nsklaus has joined #asahi-dev
07:01nsklaus has quit [Ping timeout: 480 seconds]
07:02i509vcb has quit [Quit: Connection closed for inactivity]
07:07jannaunot sure that is the same issue though given that axboe used ssh
07:09nsklaus has joined #asahi-dev
07:17nsklaus has quit [Ping timeout: 480 seconds]
07:25nsklaus has joined #asahi-dev
07:33nsklaus has quit [Ping timeout: 480 seconds]
07:44nsklaus has joined #asahi-dev
07:45kaazoo has joined #asahi-dev
07:52nsklaus has quit [Ping timeout: 480 seconds]
08:00nsklaus has joined #asahi-dev
08:08nsklaus has quit [Ping timeout: 480 seconds]
08:08MajorBiscuit has joined #asahi-dev
08:17nsklaus has joined #asahi-dev
08:25nsklaus has quit [Ping timeout: 480 seconds]
08:31kaazooHI, did anybody look into MTP support with FW 13.3 on j414s / M2 Pro 14" yet? U-boot complains about not being able to reserve some fdt memory regions: https://pasteboard.co/nI0QZsaCGQzJ.jpg
08:31kaazoodockchannel-hid gets loaded but MTP fails with 'rtkit-helper 2a9400000.mtp: error -ETIME: Failed to wake up coprocessor'
08:33nsklaus has joined #asahi-dev
08:34_jannau_I think nobody has looked so far at the u-boot mtp code. it works with linux as direct linux payload
08:35_jannau_the kernel has at least one change which needs to be done on u-boot side as well: adjusting/fixing rtkit oslog handling
08:38MajorBiscuit has quit [Ping timeout: 480 seconds]
08:40MajorBiscuit has joined #asahi-dev
08:40MajorBiscuit has quit []
08:42nsklaus has quit [Ping timeout: 480 seconds]
08:44kaazooYes, I guess that 'apple_rtkit_poll: unexpected endpoint 8' means oslog from https://github.com/AsahiLinux/m1n1/blob/t602x/bringup/src/rtkit.c#L27
08:44kaazooAre there any details documented about oslog messages? What should u-boot do with those? Just ack them the same way as m1n1 does?: https://github.com/AsahiLinux/m1n1/blob/t602x/bringup/src/rtkit.c#L448
08:48jannauno, m1n1 doesn't use mtp, it needs to do the same as the linux driver. see 612cb2861e4c ("soc: apple: rtkit: Implement OSLog buffers properly")
08:52nsklaus has joined #asahi-dev
09:01nsklaus has quit [Ping timeout: 480 seconds]
09:01nyilas has joined #asahi-dev
09:06bps has quit [Ping timeout: 480 seconds]
09:10nsklaus has joined #asahi-dev
09:18nsklaus has quit [Ping timeout: 480 seconds]
09:22kaazoojannau: OK, thanks. I will try to add that into u-boot.
09:26nsklaus has joined #asahi-dev
09:32Jamie has joined #asahi-dev
09:32rhysmdnz has joined #asahi-dev
09:33Jamie is now known as Guest12222
09:34nsklaus has quit [Ping timeout: 480 seconds]
09:37Guest12142 has quit [Ping timeout: 480 seconds]
09:37rhysmdnz1 has quit [Ping timeout: 480 seconds]
09:38bps has joined #asahi-dev
09:41nsklaus has joined #asahi-dev
11:59cylm has joined #asahi-dev
12:19mkurz has quit [Ping timeout: 480 seconds]
12:26gladiac has joined #asahi-dev
12:30gladiac has quit []
12:31gladiac has joined #asahi-dev
12:48gladiac has quit [Quit: k thx bye]
13:24mkurz has joined #asahi-dev
13:33axboejannau: wlan is ready at boot as it is, but I killed LOADER_USER_HELPER but it doesn't change any wrt suspend/resume
13:33axboesuspended twice this morning before heading to the office, just 10 second ones, and it was fine
13:34axboesuspended and drove to the office, open the laptop to a rebooted state...
13:35axboejannau: what's your .config, I could give that a whirl just in case it's some weird interaction
13:37nyilas has quit [Remote host closed the connection]
13:39nyilas has joined #asahi-dev
13:40nyilas has quit [Remote host closed the connection]
13:44nyilas has joined #asahi-dev
13:44nyilas has quit [Remote host closed the connection]
13:52jannauaxboe: https://www.jannau.net/asahi/suspend.config derived from your config, mostly toolchain induced changes. enabled serial for debugging
13:52jannauhaven't tried yet to boot through u-boot
14:02hightower2 has joined #asahi-dev
14:05axboeyeah that's basically identical outside of adding serial
14:07axboepresumably the m2 max is going to be useful soon, so might just be worth scrapping spending any time on this if it's specific to some weirdness with my setup
14:07axboeI can just run the previous kernel until then
14:12mkurz has quit [Ping timeout: 480 seconds]
14:50cylm has quit [Ping timeout: 480 seconds]
14:56mkurz has joined #asahi-dev
15:45bps has quit [Ping timeout: 480 seconds]
15:48c10l has quit [Quit: Bye o/]
15:55c10l has joined #asahi-dev
16:06stickytoffee has quit [Read error: Connection reset by peer]
16:08stickytoffee has joined #asahi-dev
16:17Tomdownsouth has joined #asahi-dev
16:49Guest12222 has quit [Ping timeout: 480 seconds]
16:49rhysmdnz has quit [Ping timeout: 480 seconds]
17:10mazoops, I may have "accidentally" ended-up with a m2 pro mini... oh well...
17:34Tomdownsouth has quit [Remote host closed the connection]
17:41mazj`ey: quite. I sense trouble...
17:46povikok, upping both LMB_MAX_REGIONS and LMB_RESERVED_REGIONS to 64 doesn't make the SIO reservation errors go away
17:59povik^ that's in u-boot
18:00povikhere are the relevant devicetree nodes: https://tpaste.us/wxa5
18:01povikit complains about the four sio-firmware-data@... reserved nodes
18:01povikwhich seem to be the only ones that fall within the span of the memory@80000000 node
18:11povikand i guess moving dt_set_memory in m1n1's kboot.c behind the sio setup is all one needs to do to cut out the sio reserved regions from the memory@ node...
18:11roxfan2 is now known as roxfan
18:11jannaupovik: the memory@80000000 should not cover the reserved mem
18:11povikok, that's easy then :)
18:12jannauat least not in the setup we use
18:12povikare the semantics of the memory@ node documented somewhere?
18:12jannaubut adjusting top_of_memory should take care of that
18:13jannauDocumentation/devicetree/bindings/reserved-memory/reserved-memory.yaml
18:14jannaunot sure if what I started doing for dcp is as intended/correct
18:15marcankaazoo: FYI all the t802x bringup stuff is already merged into the regular m1n1/linux branches (except the GPU stuff lina is working on), so disregard the bringup ones
18:17povikah, of course the devicetree spec itself discusses /memory
18:19povikthough there doesn't seem to be anything that prohibits the overlap of the /memory node and the reserved regions, the devicetree spec even has an example that's overlapping, so still not sure what the u-boot error is about
18:21jannauaxboe: if you're (un)lucky the suspend issue reproduces on on the m2 max. I still think it's useful to find out what causes it but can understand if you don't can/want spend time on it
18:23jannaupovik: I think I tested sio with u-boot after I bumped LMB_MAX_REGIONS and didn't see any errors
18:24axboejannau: yeah agree, would love to know what it is, just trying to proportion the time spent on this particular issue...
18:38povikjannau: i might be messing something up in the installation of a patched u-boot version (this is on a nixos install), but it's unlikely, i tried changing the font size and that took effect
18:38povikon the other hand this made the errors go away
18:43jannaumakes sense, allocation for the display happens (if it happens) is at m1n1's init
18:44povikah, i was wondering about that, right
18:45jannauI must have either overlooked the errors, didn't test it or something else
18:48poviknow if only we could figure out those :/
18:48povik[ 2.335642] apple-sio 236400000.sio: error -ETIME: SIO did not boot
18:48poviki only get them on a full-fledged OS install which makes debugging hard
18:49povikjannau: do you have a .config that might be worth trying? see if i can reproduce it?
18:49povikanything that's similar to the one you were getting boot failures with, if it isn't too bloated
18:50poviki will see try flipping on SIO and see if i can reproduce
18:50povikit doesn't seem to be a power-domain thing after all, at least the failures still occur without turning off any domains, and with resets disabled
18:59jannauaxboe: reproduced when booting via u-boot
19:00povikhappy about the other thing getting reproduced :)
19:02hightower2 has quit [Ping timeout: 480 seconds]
19:03jannaupovik: config with most of the non-essential drivers (including sio) as modules. so probably close to your full-fledged OS install
19:03jannauI use https://github.com/AsahiLinux/m1n1/pull/268 with a few tricks to still boot from frommy dev system
19:04axboejannau: wll then!
19:13marcanjannau: now I wonder what u-boot does that somehow affects linux down the line, that's... bizarre
19:13marcanit's not supposed to touch any HID stuff etc, is it? I wonder if it does anything interesting to any other sysregs...
19:14marcanis this with PCIe enabled in u-boot?
19:14jannauit shouldn't have PCIe enabled but linux complains about "pcie-apple 590000000.pcie: invalid resource"
19:15jannauand fails to create device links for 2920a1300.spmi:pmu@f:rtc_nvmem@1400 and 2920a1300.spmi:pmu@f:legacy_nvmem@6000
19:16marcanlong shot: we should write an AMCC error handler driver
19:16marcanreal-time memory requests to stuff the CPU has cached are illegal (macOS panics if that happens)
19:16marcanwe've never bothered with that because it worked anyway
19:16marcanbut it's entirely possible something about deep idle breaks it much more badly
19:16jannauPCIE_APPLE is not set in u-boot's config
19:17axboeI do have it set in mine fwiw
19:20marcanalready getting AMCC errors on a simple boot on j314 without u-boot
19:20marcanneed to sleep, will look at this angle tomorrow
19:21marcanpretty sure this has been broken forever and it wouldn't be surprising if deep idle makes it actually matter for real
19:22* povikgoogles AMCC
19:23povikah apple memory cache controller probably
19:23ChaosPrincessdoes anything we currently support use the "t8020" DART?
19:25hightower2 has joined #asahi-dev
19:27jannaueverything we support on t8113
19:27bps has joined #asahi-dev
19:28ChaosPrincessok, then that might be the wrong name
19:28ChaosPrincessthere is some weird dart with 4 io areas used for ave, ane and isp
19:29ChaosPrincessis this the same as everything else?
19:29ChaosPrincessdts claims its t8020
19:29marcanDARTs are instanced
19:29marcanyou need to look at the instances stuff to figure out what the io areas are
19:29ChaosPrincesswhats instance
19:29povikinstances stuff meaning some constant register imprint in silicon?
19:29jannauinstance property
19:29povikor ADT subnodes?
19:30marcanthey mushed together a pile of drivers into one and called it all dart
19:30marcanthen they specify what the IO areas mean in that property
19:30marcanit's a horrible stupid hack
19:30ChaosPrincessinstance = 465041444350554441525400545241444441525400000000554d4d53534d4d5500000000 - this?
19:30marcan(just like the rest of ADT)
19:30marcanit's ASCII
19:31marcansecond io area should be a regular dart
19:31marcanaccording to that
19:32ChaosPrincessare those fourccs
19:32marcanthey are eightccs
19:32marcanwell really just null-padded 8-character ascii strings
19:33marcanoh more than 8 even, nice
19:33marcanso just a pile of strings really
19:33marcan4byte aligned
19:33marcanFPADCPUDART TRADDART UMMSSMMU
19:33marcanso two DARTs of some sort and the SMMU thing we don't care about
19:33poviklooks like a DNA sequence :D
19:33jannaumisses 'G's
19:34ChaosPrincessthere are 'U's, its a RNA :P
19:34povikok then, you seem to know your microbiology better than me :p
19:34marcan"just dump the registers and pick out the ones that look like DARTs" is my recommendation
19:34ChaosPrincessand 'darts of some sort' - means those are different for each ip block?
19:34ChaosPrincess*"dart per ip block"
19:35marcanthe DARTs should all be t8020 compatible or if not at least *very* similar
19:35marcanoh also FPAD=DAPF?
19:35marcanI don't know why half the things are backwards only
19:35marcanthis thing is cursed
19:35marcanas I said, just dump the regs and eyeball it
19:35svendidn’t we have this exact same discussion a week or two ago? :D
19:35marcanprobably :p
19:36marcanI'm going to sleep, someone else can explain DAPF :D
19:36ChaosPrincesseasy for you to say, i have no idea whats what suposed to look like :P
19:36povik21:35 < ChaosPrincess> whats dapf
19:36marcandump a known good DART and compare? :p
19:36povikah remember myself asking the same question
19:36svenDAPF is a weird filter like thing on top of dart
19:36sventhere’s a reg map in m1n1 iirc
19:37sventl;dr is to either ignore it or replay some property from the ADT to it and then ignore it
19:37jannautry experiments/dart_dump.py $name and see if it makes sense
19:41povikChaosPrincess: that instance= value you copied seems to be from dart-ave
19:41povikthat node has filter-data-instance-0 and dapf.c in m1n1 will know how to set the DAPF according to that
19:41kaazoo has left #asahi-dev [#asahi-dev]
19:42povikso it will get set by dapf_init_all() probably and you don't need to care about it
19:42povikthough you might want to inspect the DAPF entries just to see what gets mapped
19:42jannaupovik: short description how I boot kernels with modules tethered https://gist.github.com/jannau/24089ca9dd93cdcbb712a95d5ef83803
19:42povikjannau: thanks!
19:43kaazoo has joined #asahi-dev
19:49jannauI have the feeling it is just the watchdog, armed by u-boot, feeded by linux and not disarmed on suspend
19:50povikChaosPrincess: typically data that's shared between the application processor and the coproc will be mapped by DART, data that's for the coproc only, and the foreign mmio regions it accesses, will be mapped by DAPF
19:50poviksomeone can correct me on that
19:51povikdepending on the coprocessor some mmio regions might be visible to it without mapping by DART nor DAPF
19:53povikbut e.g. the data section of SIO's firmware is mapped by DART
19:53povikso don't take the above absolutely
19:54ChaosPrincessi guess ill just see what macos does
19:55povikmacos will most likely set the DAPF according to that ADT property
19:55povikand you should let m1n1 do the same
19:55Jamie has joined #asahi-dev
19:56rhysmdnz has joined #asahi-dev
19:56Jamie is now known as Guest12262
20:05maximbaz has quit [Quit: bye]
20:07maximbaz has joined #asahi-dev
20:43bps has quit [Ping timeout: 480 seconds]
20:44jannauif the system stays 60 seconds in suspend without it's fixed
20:47bps has joined #asahi-dev
20:55A_L_I_C_E has joined #asahi-dev
21:03A_L_I_C_E has quit [Quit: Quit]
21:16maximbaz has quit [Quit: bye]
21:18maximbaz has joined #asahi-dev
21:20axboejannau: sweet! I'll give it a spin
21:35axboejannau: looks good! I'll do a longer suspend later, but did 2+ min just now and it's fine
21:54bps has quit [Ping timeout: 480 seconds]
21:59alyssa has joined #asahi-dev
22:00alyssajannau: so, I heard $FEATURE for the gl driver is going to be released at the same time as dcpext support
22:00alyssaI also heard that every time someone asks when dcpext support is done, it's delayed
22:00alyssaSo, since if I need more time for $FEATURE, it follows I should ask about dcpext support, right? ;-P
22:01ChaosPrincessis $feature == cursed geometry shader emulation?
22:04alyssaOpenGL 3.1 and OpenGL ES 3.0 and maybe OpenGL ES 3.1 too, we'll see how May goes
22:06alyssakinda depends on whether I can get funding
22:06* alyssawhistles
22:07jannauI've had hoped to get the m2 mini to light something up this weekend which is dcpext(int)UINT32_MAX support, that's of course != released
22:07ChaosPrincessif you want to get funding dont whistle innocently :P go full hustle culture and promote your patreon or whatever in every post.
22:10alyssaChaosPrincess: *sweats*
22:17axboeagree, you don't get what you don't ask for :)
23:20cylm has joined #asahi-dev
23:33cylm_ has joined #asahi-dev
23:35cylm has quit [Ping timeout: 480 seconds]
…