#
✕ nick:sven
#asahi-dev · 2021-12-14 12:29
svenweird
#asahi-dev · 2021-12-14 12:29
sventhere's also this thing apple calls SMMU (not the ARM one) but that's only for the disp dart and i don't even know if it can create interrupts
#asahi-dev · 2021-12-14 12:28
sveni thought only the USB DARTs shared an interrupt
#asahi-dev · 2021-12-14 12:28
svenhuh
#asahi-dev · 2021-12-14 12:26
svenmarcan: also, reminder about that mailing list :D
#asahi-dev · 2021-12-14 12:26
sven+ alyssa i think
#asahi-dev · 2021-12-14 12:25
svensure. it's almost all the same people anyway
#asahi-dev · 2021-12-14 12:24
svenmarcan: speaking of which, we never merged the dart entry to the general apple soc one, did we?
#asahi-dev · 2021-12-14 11:16
sven:-)
#asahi-dev · 2021-12-14 11:13
svenright. i just happen to have a day job and it's not this.
#asahi-dev · 2021-12-14 11:12
svensure
#asahi-dev · 2021-12-14 11:11
svenwell, the previous nvme driver would kernel panic if you just poked it enough. that's probably not good enough ;)
#asahi-dev · 2021-12-14 11:06
svennvme has just been more fun ;)
#asahi-dev · 2021-12-14 11:05
svenyeah
#asahi-dev · 2021-12-14 10:30
svenhm, i guess macos does the same. still need to verify that though
#asahi-dev · 2021-12-14 10:28
svenit goes from 300 MB/s down to like 1MB/s. and testing the same setup with e.g. fio on macos doesn't do that
#asahi-dev · 2021-12-14 10:25
sveni think that's also what slows it down
#asahi-dev · 2021-12-14 10:24
svenyes
#asahi-dev · 2021-12-14 10:19
svenand regarding nvme... there's still at least one annoying problem. for some reason anything that uses random writes with sync (fsync, sync, etc.) is incredibly slow (<1MB/s). not sure that counts as "works well"
#asahi-dev · 2021-12-14 10:14
svenmarcan: the usb quirk stuff is still pending fwiw (and i need to submit a follow up for the binding), not sure it'll make it to 5.17
#asahi-dev · 2021-12-14 08:48
svenyes. please also include kettenis for at least the device tree bindings
#asahi-dev · 2021-12-13 15:45
svenand here's a simple nvme tracer if anyone wants to play with it https://github.com/AsahiLinux/m1n1/pull/133
#asahi-dev · 2021-12-13 15:42
svennow it also makes sense why that debug command uses SART instead of the NVMMU though. the buffers are written to directly by the ANS firmware
#asahi-dev · 2021-12-13 15:40
svenmacOS tells ANS what time it is and then uses two commands to get the NAND ID and something they seem to call NAND geometry. probably all things we can ignore for linux
#asahi-dev · 2021-12-13 10:09
svenlooks like it's also possibly to enable error injection and do all kinds of fancy (and some scary) things with that one
#asahi-dev · 2021-12-13 10:07
svenapparently macos uses it to uh... send the current time to ANS
#asahi-dev · 2021-12-13 10:07
svenoh fun. 0xd8 is some kind of debug command tunnel because ofc the normal mailbox interface wasn't enough for that
#asahi-dev · 2021-12-13 08:31
svenlol, apple. for some reason they send some undocumented nvme command a few times (0xd8 on the admin queue) when they initialize their controller. except that these commands don't use the NVMMU but SART now
#asahi-dev · 2021-12-12 21:02
svenah yes, so something even more fancy that just memory :D
#asahi-dev · 2021-12-12 21:02
svenit also doesn't really matter to us. it probably even helps since it means that ANS and SEP will be backward-compatible
#asahi-dev · 2021-12-12 21:01
svenand i'm pretty sure they store a anti-replay counter in there
#asahi-dev · 2021-12-12 21:01
svenSEP also has (limited) internal non-volatile memory afaik
#asahi-dev · 2021-12-12 21:00
svensure, just find me a secure boot bypass for that one :P
#asahi-dev · 2021-12-12 20:59
svenSEP is where all their security is, they probably don't want you to ever downgrade that ;)
#asahi-dev · 2021-12-12 20:58
svenno idea about the rest but i'd assume the rest is stored in there as well
#asahi-dev · 2021-12-12 20:57
svenANS is stored on the NOR flash
#asahi-dev · 2021-12-12 20:57
svenexactly
#asahi-dev · 2021-12-12 20:55
sven21:31:37 <sven> but the rest can be downgraded from 1TR
#asahi-dev · 2021-12-12 20:55
svenit's a workaround at best
#asahi-dev · 2021-12-12 20:55
sventhat's hardly a solution
#asahi-dev · 2021-12-12 20:54
svenyeah, just like i said
#asahi-dev · 2021-12-12 20:41
svenwe'll probably have to speak the iBoot DCP protocol in m1n1 to make that work
#asahi-dev · 2021-12-12 20:41
svenno
#asahi-dev · 2021-12-12 20:40
svendo what trick?
#asahi-dev · 2021-12-12 20:32
svenno idea
#asahi-dev · 2021-12-12 20:32
svenyes
#asahi-dev · 2021-12-12 20:31
svenbut the rest can be downgraded from 1TR
#asahi-dev · 2021-12-12 20:31
svenyou can't downgrade SMC, ANS and uhhh.. SEP.
#asahi-dev · 2021-12-12 17:54
svenuh, without ARCH_APPLE many thing won't work
#asahi-dev · 2021-12-12 17:34
svenhttps://github.com/AsahiLinux/linux/blob/fd7c0ced9b5e58028c66dde6cb54fa61a19283b9/drivers/soc/apple/rtkit.c#L579

plus ›