#
✕ nick:sven
#asahi · 2021-09-02 17:50
sventhere's also a clock-frequencies and clock-frequencies-regs property in PMGR iirc, but running grep on XNU and all kernel extensions doesn't find _any_ reference to the regs one
#asahi · 2021-09-02 17:44
svenso it's all hardware magic (or coprocessors) doing the power stuff?
#asahi · 2021-09-02 17:44
svenhuh
#asahi · 2021-09-02 17:42
sven*reserved
#asahi · 2021-09-02 17:42
svenj_ey: the iommu core understands a few different types of reserve regions fwiw, see https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/include/linux/iommu.h#n100
#asahi · 2021-09-02 17:40
svenlooks good to me
#asahi · 2021-09-02 08:32
sventhe smmu driver uses that to reserve MSI_IOVA_BASE, https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/iommu/arm/arm-smmu/arm-smmu.c#n1553
#asahi · 2021-09-02 08:32
sventhere's a get_resv_regions that the iommu driver can implement
#asahi · 2021-09-02 08:29
svenunless the iommu framework can figure out the msi doorbell somehow, but i don't think so
#asahi · 2021-09-02 08:28
svenunless you setup dma-ranges to excluse the msi page in the pcie node only luck
#asahi · 2021-09-02 08:24
svenyeah
#asahi · 2021-08-31 14:38
sventhere's also always this usb phy driver for usb 3 and thunderbolt that i've been avoiding successfully so far if you get really bored, https://github.com/corellium/linux-m1/blob/master/drivers/phy/apple/phy-apple-atc-m1.c
#asahi · 2021-08-31 14:34
svenhttps://github.com/corellium/linux-m1/blob/master/drivers/cpufreq/apple-m1-cpufreq.c
#asahi · 2021-08-31 14:33
sveniirc it's some magic pokes to magic registers
#asahi · 2021-08-30 08:20
svenhm, no idea then. those were the only two issues i had
#asahi · 2021-08-30 08:18
svenwhat kind of cable do you use? iirc i had a cable where rebooting worked but the serial console didn't because it hadn't connected those lines
#asahi · 2021-08-30 08:17
svendo you use /dev/cu.debug-console as the tty dev? i think there's another one that won't work
#asahi · 2021-08-30 06:04
svendidn't someone mention that the thunderbolt pcie controller has issues with unaligned reads/writes or something which makes egpu support tricky? (possibly corellium). i guess we'll see once thunderbolt comes up
#asahi · 2021-08-29 13:29
sven9 women can't make a baby in a single month
#asahi · 2021-08-28 21:54
sveni think that branch doesn't have marcan's clock driver yet
#asahi · 2021-08-28 21:54
sveni don't think that's enough. you literally need to enable the ANS clock (or all clocks) from mini
#asahi · 2021-08-28 21:52
svenmake sure you don't overwrite macos or the recovery partitions by accident
#asahi · 2021-08-28 21:52
svenand you have to be a little bit careful when creating the filesystems
#asahi · 2021-08-28 21:49
sventhat branch still needs the "enable all clocks hack" fwiw
#asahi · 2021-08-25 05:38
svenoh, interesting. i always assume TrustZone only referred to the EL3 and secure/non-secure world stuff
#asahi · 2021-08-24 18:06
sventhat's what apple seems to call trustzone
#asahi · 2021-08-24 18:06
sven(and on top of that it has transparent memory encryption and an integrity tree with the root hash stored outside of RAM)
#asahi · 2021-08-24 18:06
svenin the bootrom their security coprocessors gets to "steal" some RAM and lock it down so that the main processor can't access it anymore
#asahi · 2021-08-24 18:05
svenwhat apples calls trustzone is (as far i know and don't quote me on this) their memory lockdown feature
#asahi · 2021-08-24 18:05
svenit has a mailbox interface, and it also has something apple calls trustzone but it's unrelated to ARM's TrustZone
#asahi · 2021-08-24 18:04
svenugh. nope.
#asahi · 2021-08-24 16:24
svenj_ey: robin just wanted all the cookies for himself instead of letting individual drivers handle them :P
#asahi · 2021-08-24 16:24
svenj_ey: :D
#asahi · 2021-08-24 16:19
svenespecially the shared memory vs. sart vs. just iommu part
#asahi · 2021-08-24 16:18
sveni'm quite happy with rtkit library idea. not totally happy with the implementation yet
#asahi · 2021-08-24 16:18
svenbut that ASC there needs to disappear anyway because next to ASC there's also this M3 thing
#asahi · 2021-08-24 16:17
svenand then RTBuddy or something which handles the rtkit part
#asahi · 2021-08-24 16:17
sventhere's some ASCWrap or so entry that handles the mailbox
#asahi · 2021-08-24 16:17
sventake a look at ioreg from macOS
#asahi · 2021-08-24 16:16
sveni don't think so
#asahi · 2021-08-24 16:16
sventhat ASC needs to disappear
#asahi · 2021-08-24 16:16
svenohhhh.
#asahi · 2021-08-24 16:16
sveni'm probably gonna miss these comments in irc fwiw. can you try to write them on github maybe? (does github support commenting on commits that are not PRs?)
#asahi · 2021-08-24 16:15
sven:>
#asahi · 2021-08-24 16:15
svensee "WIP". i didn't proof read or ran any kind of spell check on it :)
#asahi · 2021-08-24 16:14
svener.. is that the rtkit commit?
#asahi · 2021-08-24 16:12
svenyes. because i wanted to give marcan's rtkit library idea a try
#asahi · 2021-08-24 16:12
svenall it does is send/recv 64+32bit messages
#asahi · 2021-08-24 16:11
sventhe non-compat mailbox doesn't do any rtkit stuff
#asahi · 2021-08-24 16:11
svenno

plus ›