#
…

2022-11-25

00:08nicolas17 has joined #asahi-dev
01:11djorz has quit [Ping timeout: 480 seconds]
02:18riker77_ has joined #asahi-dev
02:23riker77 has quit [Ping timeout: 480 seconds]
02:23riker77_ is now known as riker77
02:48kenzie7 has quit []
02:49kenzie7 has joined #asahi-dev
03:38nicolas17 has quit [Ping timeout: 480 seconds]
03:41hjpm has joined #asahi-dev
03:42hjpm is now known as foton
03:45Mary has quit [Quit: The Lounge - https://thelounge.chat]
03:46Mary has joined #asahi-dev
03:47foton has quit [Remote host closed the connection]
05:22capta1nt0ad has quit [Quit: Konversation terminated!]
05:43Znullptr has quit []
05:46Gues__________________________ has joined #asahi-dev
05:49Dcow has joined #asahi-dev
05:50Dcow has quit []
05:53Gues__________________________I have no idea that why I am here. How can I start from beginning to support this. Background: I have been doing full-stack for last 5 years, worked with: C++, Go, Qt, Rust (learning), Frontend-Frameworks. I am really hyped for this project. Where can I start from?
06:02Gues__________________________ has quit [Quit: Textual IRC Client: www.textualapp.com]
06:15Dcow has joined #asahi-dev
06:41cylm has quit [Ping timeout: 480 seconds]
07:14pjakobsson has quit [Remote host closed the connection]
07:19mps_ has joined #asahi-dev
07:21mps has quit [Ping timeout: 480 seconds]
07:22capta1nt0ad has joined #asahi-dev
07:46Major_Biscuit has joined #asahi-dev
07:48capta1nt0ad has quit [Quit: Konversation terminated!]
08:22SSJ_GZ has joined #asahi-dev
09:02bgb has joined #asahi-dev
10:01svenjannau: I think it's a race between dwc3_set_mode and __dwc3_set_mode
10:02svenlocking dwc->mutex instead of dwc->lock in dwc3_set_mode seems to fix it for me
10:04___nick___ has joined #asahi-dev
10:23Gues__________________________ has joined #asahi-dev
10:25Gues__________________________ has quit []
10:34svenurgh. but we can't lock a mutex there because that function might be called from an extcon interrupt handler :/
10:56capta1nt0ad has joined #asahi-dev
10:57fugi has joined #asahi-dev
11:15cylm has joined #asahi-dev
11:26capta1nt0ad has quit [Quit: Konversation terminated!]
11:33sventhe race is also present in vanilla kernels. it’s incredibly tight but you can get dwc3 into a state where ptrcap is set to device but dwc3 sets up xhci
11:34svenwhich doesn’t go very well ;)
12:02capta1nt0ad has joined #asahi-dev
12:13Dcowguys, platform_profile is ACPI thing, right?
13:13bgb has quit [Remote host closed the connection]
13:13bgb has joined #asahi-dev
13:26millenialhacker has joined #asahi-dev
14:27_jannau_Dcow: in which ontext? but there shouldn't be any ACPI on apple silicon macs
14:29Dcowyeah, I know that AS is not ACPI. power-profiles-daemon maintainer asked about if it's possible to implement platform_profile interface fro those chips
14:30Dcowbut I guess it's not possible. But we might have similar thing for OF devices, no?
14:33Dcow_jannau_: ^
14:33svenis cpufreq already upstream? might be wise to wait for that before adding support to other software
14:34svenand are there even other things we can tweak? fans and all that is done by SMC anyway
14:34Dcowhm, I think it's not, but marcan was happy about it and he AFAIK was in touch with maintainers, so I think it's stable enough
14:35sveni'd still wait until it's at least in linux-next. i don't expect things to change but you never know
14:36DcowI am confident enough for draft pr :-D
14:36sven(for merging into tools it that is, not necessarily for starting to work on)
14:36svenyeah, draft pr sounds good
14:37svenwould just be annoying if it got merged and then the kernel interface unexpectedly changes
14:38Dcowbut since it's in stable asahi I want use it, because without patch it's uses NOP implementation and UI is confusing
14:39Dcowwe want everyone to feel like it's finished product (as possible) right? :)
14:40svenmy point really only is that the maintainer of that project should be aware that the driver isn't quite upstream yet
14:42DcowI'll made this more clear in next communication batch, but for now it's draft anyway
14:43svensounds good!
14:44Dcowso, the question, do we have similar to platfrom_profile interface for OF devices?
14:44svenno idea!
14:44svenbut that interface seems to be used when multiples knobs are to be turned together (cpufreq + fan speed + whatever else) - do we have anything except for cpufreq that can even be tweaked?
14:45svenI think most other things are controlled by SMC and I don't think we have control over them
14:45svenno idea if I'm missing anything though
14:46svenhrm, actually that interface seems to be about changing some "internal" policy so that something like SMC can tweak all these things together
14:47svennot sure if anything like that even exists and that also seems to be unrelated to cpufreq i think
14:49Dcowwell, this is daemon to tune device modes, not exactly cpufreq. If we can do more than cpufreq, why not?
14:50Dcowso, not that unrelated
15:14bgb has quit [Ping timeout: 480 seconds]
15:21millenialhacker has quit [Remote host closed the connection]
15:25mstephenson6 has joined #asahi-dev
15:39svenjannau: alright, looks like I can't reproduce the WARN anymore if I lock dwc->mutex around dwc->lock in dwc3_set_mode with that atcphy-WIP tree
15:40svennot 100% sure because reproducing it has always been flakey for me
15:42jannauI'll test later
15:48sventhanks. fixing that race correctly is going to be annoying
15:52jannauI find it surprising that dwc3_set_mode and __dwc3_set_mode can race each other
15:53mstephenson6 has quit [Quit: Konversation terminated!]
15:53svenyou need a very quick A->B->A role change event
15:53svenit's much easier to hit that race with the role switch reset quirk
15:54svenbut without it you can have one dwc->desired_dr_role value in dwc3_set_prtcap(dwc, dwc->desired_dr_role); and then three lines or so below a different one in switch (dwc->desired_dr_role)
15:54svenbut that thing is incredibly right. I only managed to trigger it twice
15:55svenbut you then end up with PRTCAP = host and dwc3 bringing up gadget or vice versa
16:05maria has quit [Quit: The Lounge - https://thelounge.chat]
16:06maria has joined #asahi-dev
16:11nomnomcookie has joined #asahi-dev
16:28amarioguy has quit [Remote host closed the connection]
17:53nicolas17 has joined #asahi-dev
18:25tpw_ruleshm, which device trees does the uefi-only-20221122-4.zip come with?
18:25tpw_rulesthe UEFI environment only installer option
18:53roxfan2 has joined #asahi-dev
18:58zzywysm has quit [Remote host closed the connection]
18:59zzywysm has joined #asahi-dev
19:00roxfan has quit [Ping timeout: 480 seconds]
19:07kettenislooks like it has something very similar to what's in the asahi-wip branch
19:08kettenisactually I suppose that's now the asahi branch
19:08kettenisof the linux repository
19:16zzywysmkettenis: i think marcan gave the asahi branch the same contents as the asahi-wip branch a day or two after asahi-wip finalized?
19:22zzywysm has quit [Quit: Textual IRC Client: www.textualapp.com]
19:27kettenislooks like it
19:30tpw_rulesis it the same as the regular asahi installer options then
19:35kettenisI think so
19:40Major_Biscuit has quit [Ping timeout: 480 seconds]
19:44roxfan2 is now known as roxfan
20:26zzywysm has joined #asahi-dev
20:31svenlooks like that additional muted also fixed the rare DP-altmode transition bugs I saw
20:33sven*mutex
20:36eiln has joined #asahi-dev
20:36eilnhello everyone! it's been 5 days and i'm *still* in github jail so i made a mirror on
20:37eilnso far i've got a prototype of 1D element-wise ADD/MUL/MIN/MAX, NCHW convolution, and (my fav, also the trickiest) 2D matrix multiplication working :D
20:37eilni haven't had much issues with the work interface (TaskManager in ane_tm.py, my main work), so i'm now studying the actual work, i.e. those magic numbers in the configuration registers
20:37eilnt8103s should be able to run the scripts in experiments/ane_*.py
20:38eilnplease let me know if there are issues
20:41jannausven: looking good here as well. m1n1 device is reliably detected and I haven't triggered the warning so far
20:43svenso then we just have to find a way to fix it properly even when dwc3_set_mode is called from atomic context
20:43jannaudmesg from m1n1 device detection to after powering the device off: https://paste.debian.net/1261876/
20:43svenlooks good to me
20:44svenI guess we could create a single threaded workqueue and defer it to there with a newly allocated work_struct each time but ugh :(
20:45kettenisisn't this the point where you start talking to the maintainer of the dwc3 driver?
20:45svenyeah, probably
20:57jluthra has quit [Remote host closed the connection]
20:57jluthra has joined #asahi-dev
21:08___nick___ has quit [Ping timeout: 480 seconds]
21:30roxfan has quit [Remote host closed the connection]
21:37poviknot sure how surprising this is but SIO requires the data section of its firmware DART-mapped for it to boot
21:37poviksegment-ranges= has the right values but maybe there's some other canonical source
21:38roxfan has joined #asahi-dev
21:39svendata section inside dart is pretty common
21:39svensegment ranges should be the source
21:40svenit’s only not used for DCP because that dart is locked and pre filled iirc
21:40povikah ok. AOP had it in the dedicated SRAM of its own
21:41svenI think AOP is the exception because it probably has to work even when RAM doesn’t
21:41povikbut how come grep for segment-ranges/segment_ranges has no hits in proxyclient?
21:41poviki would think there's other code already doing this
21:41svenwhy would it?
21:42svenfor DCP the PTEs already exist
21:42povikwell, what about the other ASC clients? don't they set up the mapping?
21:42svenand ANS has the data section mapped via SART
21:42svenSMC has everything in its internal RAM as well
21:42svenand I think that’s all we support
21:43povikfine, i get to parse it myself :)
21:45nomnomcookie has quit [Remote host closed the connection]
21:46jannauI have notes how to parse segment ranges
21:46poviki am looking at the right hardcoded indices for now
21:47nomnomcookie has joined #asahi-dev
21:47jannaudart-dcp has them as well but it's a little more complicated since some of the ranges have to be mapped to disp0-dart as well
21:49povikok, boots now
21:50povikok, boots now
21:50povikuh, bad window
21:53jannaupovik: "32 byte per segment, 8-byte physical addr, 8 bytes unknown, 8-byte device address, 4-byte size, remeining 4 bytes look like flags"
21:54povik4-byte size limit?
21:54povikwait, that's a lot, what am i thinking
21:55povikok, matches my understanding, except i was passing in the flags for top 4 bytes of size
21:58jannauare the top 4 bytes all zero? iirc for dcp it had bits set which didn't make sense as size
21:59povikall zero for data. flag bit 0 set for text
22:01jannauthere's a segment-range for text? dcp misses that on t8103/t600x
22:02povikseem to be. segment-names of dcp has __TEXT too
22:02svenit maps text via dart?
22:02poviki assume that matches the segment-ranges order
22:02povikno, at least the SIO doesn't get that mapped
22:03svenok, that would’ve been really surprising :)
22:03svenotherwise we could’ve just written out own fake-dma firmware :D
22:04povik"SmartIO"
22:05jannausven: dcp text seems to be mapped via dart on m2
22:05svenhuh, interesting.
22:05svenand that dart is still locked?
22:05svenpovik: maybe it’s tongue-in-cheek :D
22:06jannaupovik: dcp has text in segment-names but not in segment-ranges
22:06jannauyes, dart-dcp* are still locked
22:06svenweird.
22:06svenif text is mapped via dart I don’t get why they have to lock it anymore
22:06povikjannau: ah, seems to be there for SIO
22:08povikhm, on t8103 i see 6 entries in both names and ranges of dcp
22:11jannauah, I think my problem in understanding was that there were just 5 5 ranges mapped in the dart as set up by iboot
22:13povikflag bit 0 could be "this is TEXT" or "don't map this with DART"
22:14erik3424 has quit [Quit: erik3424]
22:14povikmatches the dcp segment-ranges too
22:22artemist has quit [Quit: artemist]
22:24jannauthe last 4 segments for dcp have bit(1) set
22:25povikon m2 does text have bit(0)?
22:31jannaucould be a executable flag
22:39Dcow has quit [Remote host closed the connection]
22:44Dcow has joined #asahi-dev
22:46Dcow has quit [Remote host closed the connection]
22:59Dcow has joined #asahi-dev
23:07jannauX11 works with https://www.jannau.net/asahi/30-modeset.conf in /etc/X11/xorg.conf.d/ - the modesetting driver apparently needs to be told to use /dev/dri/card2 although there are log messages which imply it is probed
23:07Dcow has quit [Ping timeout: 480 seconds]
23:08jannauplasma/x11 is broken though since it appears to require vblank events as well
23:11millenialhacker has joined #asahi-dev
23:20Major_Biscuit has joined #asahi-dev
23:22kettenisisn't there code to fake vblank events in the Linux drm code somewhere?
23:23pbsds0 has joined #asahi-dev
23:26millenialhacker has quit [Quit: Konversation terminated!]
23:26jannauI was under the impression drm was already doing it based on the refresh rate
23:26pbsds has quit [Ping timeout: 480 seconds]
23:28jannauemiting fake fblank events is not the problem, we are that already (on framebuffer swaps and in some error paths)
23:28SSJ_GZ has quit [Ping timeout: 480 seconds]
23:29jannauthe problem is deciding when fake fblank events needs to be emitted with adding to the vblank events from fb swaps
23:33Major_Biscuit has quit [Ping timeout: 480 seconds]
23:36amarioguy has joined #asahi-dev
23:42povikha! got SIO to speak up
23:42povikMessage 1: Invalid tunable size: 67108864
23:42poviknot sure what it means but progress anyway
…