ChanServ changed the topic of #asahi-dev to: Asahi Linux: porting Linux to Apple Silicon macs | Non-development talk: #asahi | General development | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Logs: https://alx.sh/l/asahi-dev
amarioguy has quit [Ping timeout: 480 seconds]
off^ has joined #asahi-dev
cylm has quit [Ping timeout: 480 seconds]
foxtrot has quit [Remote host closed the connection]
vup has quit [Remote host closed the connection]
___nick___ has joined #asahi-dev
___nick___ has quit []
vup has joined #asahi-dev
___nick___ has joined #asahi-dev
foxtrot has joined #asahi-dev
zef_ has joined #asahi-dev
zef has quit [Ping timeout: 480 seconds]
bluetail8 has quit [Read error: Connection reset by peer]
<jannau>
povik: I'd say it should be at least assert 'rptr <= rb->bufsz'. I don't think I saw wraparound though yet
<povik>
yeah, <= makes sense
annie444 has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
<marcan>
povik, jannau: 10k IRQ/s is either an IRQ for each byte of SPI, or a bug
<marcan>
and SPI has a FIFO depth of 16 so that's a bug
<marcan>
it should be on the order of 256 / 16 * update rate (let's say 100Hz) = ~1.6k IRQ/s
leitao has joined #asahi-dev
<marcan>
jeffmiw: which module? I'm not in the least surprised that there's bad OF refcounting somewhere, as far as I can tell ~everyone gets OF refcounting wrong, all the time. it's impossible to get right.
<marcan>
(unless you're lina and you use Rust and it takes care of that for you)
annie444 has quit [Ping timeout: 480 seconds]
<jannau>
marcan: that's total system irqs as reported by `vmstat 1` not just the touchpad alone
<marcan>
jannau: everything else has no excuse to have more than ~1 IRQ per update on top of that, SPI is really the worst case bit
<marcan>
so I maintain there's a bug :)
<jannau>
there are 60 display updates with multiple mailbox messages for dcp on touchpad input
<marcan>
60 display updates per *second*, no?
<marcan>
being generous and saying 10 mailbox messages, that's no more than 600 on top
<marcan>
there's also the fact that mailbox is stupid, of course
<marcan>
maybe I should finally fix that next week
<marcan>
e.g. all the TX IRQs are completely unnecessary and burning power for zero reason
<marcan>
but still, even with all that silliness, there's no way you add up to 10k without something being broken
<jannau>
~2k SPI irqs per second on continuous trackpad movement. the rest is something else. is "Function call interrupts" just system calls or context switches as well?
<j`ey>
IPIs it looks like?
<marcan>
yeah that's not right
<jannau>
probably not the best idea to use the threaded irqs _and_ the async SPI interface in spi_hid
<marcan>
jannau: no, this can't be the SPI-HID interface using threading because it (if it's not broken) can't be causing more than single-digit IRQs per update give or take
<marcan>
the only thing that should see the IRQ bloat is the SPI host driver itself, since it has to IRQ every 8 bytes (current threshold)
<marcan>
if that is triggering IPIs we need to fix that
<kettenis>
in other news, I just booted OpenBSD on the m2 pro m1n1
<jannau>
trackpad update rate seems to be 150Hz
annie444 has joined #asahi-dev
<marcan>
kettenis: nice! :D
cylm has joined #asahi-dev
annie444 has quit [Remote host closed the connection]
annie444 has joined #asahi-dev
<kettenis>
this is with a fairly bare-bones device tree that only enables the dwc3 controllers
annie444 has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
Puto has quit [Read error: Connection reset by peer]
Puto has joined #asahi-dev
<robher>
marcan, jeffmiw: Doubtful it is related to DT refcounting. refcounts should have no effect on static nodes which are *all* of them unless you are modifying the DT in the kernel.
annie444 has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
annie444 has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
seeeath has joined #asahi-dev
annie444 has quit [Ping timeout: 480 seconds]
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
annie444 has joined #asahi-dev
leitao has joined #asahi-dev
nate8 has joined #asahi-dev
annie444 has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
annie444 has quit []
alyx has joined #asahi-dev
alyx has quit [Remote host closed the connection]
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
leitao has joined #asahi-dev
bisko has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
leitao has joined #asahi-dev
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
seeeath_ has joined #asahi-dev
leitao has joined #asahi-dev
leitao has quit []
seeeath has quit [Ping timeout: 480 seconds]
leitao has joined #asahi-dev
seeeath_ has quit [Read error: Connection reset by peer]
seeeath has joined #asahi-dev
tino has quit [Remote host closed the connection]
eiln has joined #asahi-dev
tino has joined #asahi-dev
tino1 has joined #asahi-dev
tino has quit [Ping timeout: 480 seconds]
annie444 has joined #asahi-dev
eiln has quit [Remote host closed the connection]
zzywysm has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zzywysm has joined #asahi-dev
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
leitao has joined #asahi-dev
Dementor has quit [Ping timeout: 480 seconds]
eiln has joined #asahi-dev
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
leitao has joined #asahi-dev
MajorBiscuit has joined #asahi-dev
Major_Biscuit has quit [Ping timeout: 480 seconds]
seeeath has quit [Max SendQ exceeded]
seeeath has joined #asahi-dev
<jeffmiw>
marcan: it is in my hwmon smc driver, I'm using of_find_node_by_name one time with NULL as from and then with a node. If I do 2 times the one with a node, then on the second insmod it usually get stuck there. Not sure how to deal with the refcount ...
<jeffmiw>
Just doing the call with NULL as from before each call with a node as from make the rmmod/insmod loop work 1K times ... It seems I need to dig further to understand what I'm doing related to this refcoount :)
MajorBiscuit has quit [Ping timeout: 482 seconds]
leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
t has joined #asahi-dev
<t>
@marcan are there any linux driver yaks that only require 1 m1 macbook?
<t>
microphones, hdmi out, webcam?
<t>
usb-a?
<j`ey>
usb-a works, hdmi out is already covered by sven
<j`ey>
not sure about microphones, but webcam has had some work, but still work to do there
<sven>
webcam is a pretty big yak ;)
<j`ey>
microphones, I think there's at least a m1n1 experiment?
<t>
@sven is it something i could work 10-15hrs/week on in 4 months? is there some branch with progress so far
<sven>
I dunno
<sven>
webcam requires quite a bit of reverse engineering I think
<t>
who is kellermanrivero can i ask him some questions
<t>
*them
t has quit [Remote host closed the connection]
<arnd>
lina: my randconfig build setup has a lot of randconfig warnings "drivers/soc/apple/rtkit-crashlog.c:127:6: error: stack frame size (1048) exceeds limit (1024) in 'apple_rtkit_crashlog_dump_regs' [-Werror,-Wframe-larger-than]" from commit 22991d8d5725 ("soc: apple: rtkit: Add register dump decoding to crashlog")
<arnd>
the 1024 byte limit is only on 32-bit architectures, so a 'depends on 64BIT' would avoid that for compile testing, but ideally it should not use that much stack
<arnd>
what is the purpose of the memcpy() to a local structure, can this just access the original data instead?
<ah->
t: he's on here occasionally as millenialhacker
seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
seeeath has joined #asahi-dev
gladiac has joined #asahi-dev
___nick___ has quit []
bluetail has quit [Ping timeout: 480 seconds]
<eiln>
i recall the isp firmware was extremely large
<sven>
luckily so far we almost never had to actually reverse engineer any firmware
seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
seeeath has joined #asahi-dev
chadmed has quit [Remote host closed the connection]
chadmed has joined #asahi-dev
nepeat_ has quit [Ping timeout: 480 seconds]
hightower2 has joined #asahi-dev
zalyx has quit [Quit: later alligator]
zalyx has joined #asahi-dev
compassion has quit [Quit: lounge quit]
<lina>
arnd: I think I did that to avoid alignment issues, but at least on arm64 that shouldn't matter... I can replace it with a pointer if you want