#
#asahi-dev · 2026-01-25 10:57
integralpilotideally we can probably get it working just using mboxes = <&dockchannel 1>; etc. i think
#asahi-dev · 2026-01-25 10:57
integralpilotit probably works that way, i think (i'll have to prototype and see which i'm doing rn)
#asahi-dev · 2026-01-25 10:55
sven*custom
#asahi-dev · 2026-01-25 10:55
svenwe just re-use the original mbox device tree bindings
#asahi-dev · 2026-01-25 10:55
svenour mailbox is in drivers/soc/apple with a customer interface now fwiw
#asahi-dev · 2026-01-25 10:54
integralpilotreading through that email many of the issues marcan brought up probably apply to dockchannel too now that i think of it
#asahi-dev · 2026-01-25 10:51
svenwe might also need more specialized callbacks and then maybe apple,dockchannel = <&dockchannel 0> is better, dunno
#asahi-dev · 2026-01-25 10:50
svenjust have to make sure we don't run into this if we put into the mailbox system <jannau> it wasn't just the atomic context. mailbox was overall a bad fit for asc: https://lore.kernel.org/asahi/20230328-soc-mailbox-v1-0-3953814532fd@marcan.st/
#asahi-dev · 2026-01-25 10:50
integralpiloti've looked into it more (seeing how the mailbox subsystem works because i wasn't sure!) and it seems actually like a better way of handling it and more ergonomic
#asahi-dev · 2026-01-25 10:50
svenit's just that the correct parent/subnode thing and then calling dockchannel_init which requests irqs from the irq controller defined in the same file looks very weird to me
#asahi-dev · 2026-01-25 10:49
svenonly if you think it's reasonable, i'm not really sure about any of this :D
#asahi-dev · 2026-01-25 10:49
integralpilotjust finishing power v4 first
#asahi-dev · 2026-01-25 10:49
integralpilothmm okay, i'll prototype re-writing it that way
#asahi-dev · 2026-01-25 10:49
svenat least right now i think dockchannel should really be a mailbox-like thing, possibly inside the mbox system if it doesn't run into the same problems asc mailboxes did
#asahi-dev · 2026-01-25 10:48
integralpilotthat would probably actually work better
#asahi-dev · 2026-01-25 10:48
integralpilotsven: i guess that could work, but we would need to make sure the callbacks etc. are in a threaded IRQ context
#asahi-dev · 2026-01-25 10:48
svenmaybe i should continue figuring out that debug usb thing so that we can actually test that dockchannel uart
#asahi-dev · 2026-01-25 10:47
svenhttps://github.com/apple-oss-distributions/xnu/blob/d8b80295118ef25ac3a784134bcf95cd8e88109f/pexpert/arm/pe_serial.c#L406
#asahi-dev · 2026-01-25 10:46
svenjannau: oss xnu contains code to drive that dockchannel-uart fwiw
#asahi-dev · 2026-01-25 10:46
sven+use
#asahi-dev · 2026-01-25 10:45
svensure, but the serial driver would just dockchannel_await or whatever
#asahi-dev · 2026-01-25 10:45
integralpilotif you make it not a contorller anymore, you can't give an IRQ number to the serial driver, as the AIC one is for all events
#asahi-dev · 2026-01-25 10:45
jannauit has disjoint regs from dockchannel-mtp and no interrupt or phandle
#asahi-dev · 2026-01-25 10:45
integralpilotwith the system of it acting as its own interrupt controller & abstracting away the multiplexing it's easier to say, oh serial, your IRQ is #3 (or whatever) on the dockchannel
#asahi-dev · 2026-01-25 10:44
integralpilotsven: the way you proposed getting rid of the IRQ stuff would work for HID, but it would probably break serial as i think serial8250 (or similar) expects to be able to bind to an IRQ
#asahi-dev · 2026-01-25 10:44
jannauI don't even understand how dockchannel-uart is supposed from the ADT
#asahi-dev · 2026-01-25 10:42
svenlike for thunderbolt :D
#asahi-dev · 2026-01-25 10:41
jannauit's not handled automatically for multiple domains since the ordering / timing could be device specific
#asahi-dev · 2026-01-25 10:41
noopwafelthanks (both)!
#asahi-dev · 2026-01-25 10:41
svenyou don't want the PD_FLAG_NO_DEV_LINK flag though, i have that there because thunderbolt is special
#asahi-dev · 2026-01-25 10:40
svenhttps://github.com/AsahiLinux/linux/blob/5265e38457df79188be2e13870192a1d488831ac/drivers/thunderbolt/apple.c#L733
#asahi-dev · 2026-01-25 10:40
jannaunoopwafel: devm_pm_domain_attach_list
#asahi-dev · 2026-01-25 10:39
noopwafelintegralpilot: that was what I was hoping but nop :(
#asahi-dev · 2026-01-25 10:38
sventhere's code in nvme that does it, but there's a common helper function now
#asahi-dev · 2026-01-25 10:38
svenlooking for it right now :D
#asahi-dev · 2026-01-25 10:38
noopwafelsven: any pointers to something existing which does the manual work?
#asahi-dev · 2026-01-25 10:38
svenif it has more than a single domain you need to do some manual work
#asahi-dev · 2026-01-25 10:38
integralpilotno, you don't. if you add it to power-domains property on each node it should turn them on as needed
#asahi-dev · 2026-01-25 10:37
svennoopwafel: if your device has a single domain defined in the dts it'll just work
#asahi-dev · 2026-01-25 10:37
noopwafeldo I need to bring up all the pmgr domains before handing over to linux? or am I missing some way to get linux pm to bring up domains during probe? I stared at the docs and the api seems, uh, very suspend-centric
#asahi-dev · 2026-01-25 10:37
svenmight only be a bit strange to have a serial without a reg but oh well
#asahi-dev · 2026-01-25 10:36
svenit is.
#asahi-dev · 2026-01-25 10:36
nickchanit looks compatible to me i think
#asahi-dev · 2026-01-25 10:36
svenit's not unusual that you don't replies for hours at times
#asahi-dev · 2026-01-25 10:36
svenirc is slow
#asahi-dev · 2026-01-25 10:36
svenno worries :)
#asahi-dev · 2026-01-25 10:36
integralpilotoh sorry was AFK!
#asahi-dev · 2026-01-25 10:36
svensure, anything that makes you think what i just made up isn't?
#asahi-dev · 2026-01-25 10:35
nickchanwhatever description is used it must be compatible with a serial driver consumer
#asahi-dev · 2026-01-25 10:34
sven(maybe outside the mbox system if there's a mismatch like for asc)

plus ›