2023-04-04
00:13ahdeb[m] has joined #asahi-dev
00:39raveling has quit [Ping timeout: 480 seconds]
00:44seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
00:48baahemian has quit [Quit: baahemian]
01:02raveling has joined #asahi-dev
01:10raveling has quit [Ping timeout: 480 seconds]
01:21raveling has joined #asahi-dev
01:26baahemian has joined #asahi-dev
01:27skipwich_ has quit []
01:29raveling has quit [Ping timeout: 480 seconds]
01:31baahemian has quit [Quit: baahemian]
01:32baahemian has joined #asahi-dev
01:36i509vcb has joined #asahi-dev
01:37Urriellu has quit [Ping timeout: 480 seconds]
01:42skipwich has joined #asahi-dev
01:49alyssa has joined #asahi-dev
01:49alyssaorowith2os: marcan: jannau: if we're building Asahi-only Mesa, you can drop the LLVM dep (build option -Dllvm=disabled)
01:51baahemian has quit [Ping timeout: 480 seconds]
01:53seeeath has joined #asahi-dev
01:53seeeath has quit []
01:55alyssa has quit [Quit: leaving]
02:09seeeath has joined #asahi-dev
02:14znih has joined #asahi-dev
02:18znih has quit []
02:46Mary6 has quit []
02:52Mary6 has joined #asahi-dev
02:57ntal has joined #asahi-dev
03:00skipwich has quit [Quit: DISCONNECT]
03:01skipwich has joined #asahi-dev
03:06seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
03:09ntal has quit [Remote host closed the connection]
03:16tobhe_ has joined #asahi-dev
03:20pbsds has quit [Quit: The Lounge - https://thelounge.chat]
03:20tobhe has quit [Ping timeout: 480 seconds]
03:22pbsds has joined #asahi-dev
03:23seeeath has joined #asahi-dev
03:28hightower3 has joined #asahi-dev
03:34hightower2 has quit [Ping timeout: 480 seconds]
03:43seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
03:45drubrkletern has quit [Remote host closed the connection]
03:45user982492 has joined #asahi-dev
03:50seeeath has joined #asahi-dev
03:58seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
04:00seeeath has joined #asahi-dev
04:11seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
04:24seeeath has joined #asahi-dev
04:24seeeath has quit []
04:28seeeath has joined #asahi-dev
04:40user982492 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
04:43derzahl has quit [Remote host closed the connection]
04:48seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
05:29crabbedhaloablut has quit [Ping timeout: 480 seconds]
05:31Urriellu has joined #asahi-dev
05:35raveling has joined #asahi-dev
05:53mixi has joined #asahi-dev
06:01bisko has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
06:39probie_ has joined #asahi-dev
06:40probie has quit [Read error: Connection reset by peer]
06:41probie_ is now known as probie
07:20crabbedhaloablut has joined #asahi-dev
07:22nicolas17 has quit [Ping timeout: 480 seconds]
07:37bisko has joined #asahi-dev
07:37hightower3 has quit [Remote host closed the connection]
07:46leitao has joined #asahi-dev
07:59Urriellu has quit [Ping timeout: 480 seconds]
08:01rpirea has joined #asahi-dev
08:13bisko has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
08:18leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
08:24loki_val has joined #asahi-dev
08:25cylm has joined #asahi-dev
08:28crabbedhaloablut has quit [Ping timeout: 480 seconds]
08:31loki_val has quit []
08:33crabbedhaloablut has joined #asahi-dev
08:35crabbedhaloablut has quit []
08:37crabbedhaloablut has joined #asahi-dev
09:08leitao has joined #asahi-dev
09:09nyilas has joined #asahi-dev
09:18bisko has joined #asahi-dev
09:29nsklaus has joined #asahi-dev
09:34leitao has quit [Ping timeout: 480 seconds]
09:43i509vcb has quit [Quit: Connection closed for inactivity]
10:05leitao has joined #asahi-dev
10:08leitao has quit []
10:10leitao has joined #asahi-dev
10:15rpirea_ has joined #asahi-dev
10:18rpirea has quit [Ping timeout: 480 seconds]
10:26rpirea has joined #asahi-dev
10:30rpirea_ has quit [Ping timeout: 480 seconds]
10:38leitao has quit [Ping timeout: 480 seconds]
11:19gordonfreeman has joined #asahi-dev
11:23gordonfreemanhello, I'm running macos under m1n1 for kernel debugging. How can I locate physical address of an EL0 virtual address?
11:24gordonfreemanthere are `at` instructions in hv_translate function but they require SPSR.M value to be EL0. However in m1n1 shell we are not EL0. Set it to EL0 forcefully then called hv_translate but didn't work
11:27gordonfreemanAlso tried to run `at s1e0r`at EL1 for EL0 VA--->PA conversion but what I get in the PAR_EL1 is "Translation fault, level 2" error code.
11:34leitao has joined #asahi-dev
11:38MajorBiscuit has joined #asahi-dev
11:43gordonfreemanInteresting fact is `at s1e0r` has only 1 reference in XNU src, in `mmu_uvtop` ("MMU user virtual to physical address translation"). But this mmu_uvtop is meant to be used only in KDP.
11:44gordonfreemanso seemingly xnu doesn't do EL0 VA-PA conversion as well... but then what manages this mapping?
11:45marcangordonfreeman: using the live SPSR_EL2 is probably wrong, it should use the saved SPSR from the HV context so it can survive exceptions at EL2. but at that point `el` might as well be an argument.
11:46marcanof course it will only work if EL0 is actually mapped, which might only be the case when actually executing kernel code. and then you'll have to look up how PAN interacts with that.
11:48marcanOSes don't usually need to do VA to PA conversion via hardware, they have higher-level page management structures.
11:49gordonfreeman> *executing user code
11:50gordonfreemanany idea how can I drop to m1n1 shell while executing user code? What I currently do is to trigger kernel to make a hvc call to stop the execution. But obviously we switch to kernel context while doing this
11:53gordonfreemanoh so EL0 brk's are also handled in m1n1? I thought only EL1 ones... will try this out
11:58rpirea has quit []
11:59rpirea has joined #asahi-dev
12:24seeeath has joined #asahi-dev
12:26raveling has quit [Ping timeout: 480 seconds]
12:29leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
12:35leitao has joined #asahi-dev
12:35bisko has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
12:36gordonfreemanOkay, right after mmap'ing and memset'ting a fixed address from EL0, I trigger a brk. In brk handler I run hv_translate but 0x0 is returned. checked out SPSR and it's M=SPSR_M.EL0t, which is what we want.
12:37gordonfreemanWhat's wrong?
12:42mazgordonfreeman: do you have HCR_EL2.TGE=0 at the point where you translate? How about any of the E0PD bits set in TCR_EL1?
12:46amarioguy has joined #asahi-dev
12:48raveling has joined #asahi-dev
12:52gordonfreemanHCR_EL2.TGE is 0. E0PD0 and E0PD1 are zero.
12:58bisko has joined #asahi-dev
12:59raveling has quit [Ping timeout: 480 seconds]
13:21raveling has joined #asahi-dev
13:29raveling has quit [Ping timeout: 480 seconds]
13:40amarioguy has quit [Ping timeout: 480 seconds]
13:55seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
13:55seeeath has joined #asahi-dev
14:09rpirea has quit [Ping timeout: 480 seconds]
14:10raveling has joined #asahi-dev
14:16rpirea has joined #asahi-dev
14:31raveling has quit [Ping timeout: 480 seconds]
14:39raveling has joined #asahi-dev
14:46leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
14:59bisko has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
15:05bps has quit [Ping timeout: 480 seconds]
15:09c10l has quit [Quit: Bye o/]
15:16c10l has joined #asahi-dev
15:27nyilas has quit [Remote host closed the connection]
15:31raveling has quit [Ping timeout: 480 seconds]
15:38leitao has joined #asahi-dev
15:42c10l has quit [Quit: Bye o/]
15:43c10l has joined #asahi-dev
15:47raveling has joined #asahi-dev
16:06leitao has quit [Ping timeout: 480 seconds]
16:08amarioguy has joined #asahi-dev
16:21i509vcb has joined #asahi-dev
16:23amarioguy has quit [Ping timeout: 480 seconds]
16:32raveling has quit [Ping timeout: 480 seconds]
17:00leitao has joined #asahi-dev
17:02Urriellu has joined #asahi-dev
17:08thasti has quit [Remote host closed the connection]
17:12thasti has joined #asahi-dev
17:21raveling has joined #asahi-dev
17:33cylm has quit [Ping timeout: 480 seconds]
17:36raveling has quit [Ping timeout: 480 seconds]
17:41leitao has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
17:51nyilas has joined #asahi-dev
17:58seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
17:58seeeath has joined #asahi-dev
18:34timokrgr has joined #asahi-dev
18:48erik has joined #asahi-dev
18:49erik is now known as Erkovich_
18:50Erkovich_ has quit []
18:50erik has joined #asahi-dev
18:50erik has quit [Remote host closed the connection]
18:50Cromulent has joined #asahi-dev
18:58nicolas17 has joined #asahi-dev
19:29WindowPa- has joined #asahi-dev
19:34WindowPain has quit [Ping timeout: 480 seconds]
19:55seeeath has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
19:57seeeath has joined #asahi-dev
20:02zalyx0 has quit [Read error: Connection reset by peer]
20:04seeeath has quit [Quit: Textual IRC Client: www.textualapp.com]
20:05zalyx0 has joined #asahi-dev
20:05nyilas has quit [Remote host closed the connection]
20:35Urriellu has quit [Ping timeout: 480 seconds]
21:01MajorBiscuit has quit [Quit: WeeChat 3.6]
21:56Urriellu has joined #asahi-dev
22:20Cromulent has quit [Quit: Connection closed for inactivity]
22:20YungRaj has joined #asahi-dev
22:23YungRaj has quit []
22:51Droop has quit [Read error: Connection reset by peer]
22:51Droop has joined #asahi-dev
23:13lewurm`` has quit [Ping timeout: 480 seconds]
23:13seb91nihel has joined #asahi-dev
23:13null has quit [Quit: oh no.]
23:13null has joined #asahi-dev
23:14seb4nihel has quit [Quit: ZNC 1.8.2 - https://znc.in]
23:58nsklaus has quit [Quit: ZZZzzz…]