Hello, I think I have made some progress.
The kernel seems alive:
qemu-system-aarch64 -machine virt -cpu cortex-a53 -m 1G -nographic
-kernel ./gnumach -append "gnumach -H" -device
guest-loader,addr=0x42000000,kernel=./aarch64/example.elf,bootargs='example
--host-priv-port=${host-port} --device-master-port=${device-port}
$(task-create) $(task-resume)' -s -S
aarch64-linux-gnu-gdb gnumach.elf
Python Exception <class 'ImportError'>: cannot import name
'INTENSITY_BOLD' from '_gdb' (unknown location)
aarch64-linux-gnu-gdb: ⚠️ warning:
Could not load the Python gdb module from `/usr/share/gdb/python'.
Limited Python support is available from the _gdb module.
Suggest passing --data-directory=/path/to/gdb/data-directory.
GNU gdb (GDB) 17.2
Copyright (C) 2025 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "--host=x86_64-pc-linux-gnu
--target=aarch64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from gnumach.elf...
(gdb) target remote :1234
❌️ could not connect: Connessione scaduta.
(gdb) set architecture aarch64
The target architecture is set to "aarch64".
(gdb) target remote :1234
Remote debugging using :1234
Python Exception <class 'NameError'>: Installation error:
gdb._execute_unwinders function is missing
0x0000000040000000 in ?? ()
(gdb) add-symbol-file gnumach.elf 0xffff000040200000
add symbol table from file "gnumach.elf" at
.text_addr = 0xffff000040200000
(y or n) y
Reading symbols from gnumach.elf...
(gdb) hbreak Panic
Hardware assisted breakpoint 1 at 0x3bb0: Panic. (2 locations)
(gdb) hbreak halt_all_cpus
Hardware assisted breakpoint 2 at 0x844: halt_all_cpus. (2 locations)
(gdb) hbreak psci_system_reset
Hardware assisted breakpoint 3 at 0x23cc: psci_system_reset. (2 locations)
(gdb) continue
Continuing.
^C
Program received signal SIGINT, Interrupt.
Python Exception <class 'NameError'>: Installation error:
gdb._execute_unwinders function is missing
machine_idle (Python Exception <class 'NameError'>: Installation
error: gdb._execute_unwinders function is missing
mycpu=0) at aarch64/aarch64/model_dep.c:72
⚠️ warning: Source file is more recent than executable.
72 }
(gdb) printf "%s\n" (char *)consbuf
❌️ Invalid argument syntax
(gdb) printf "%s\n", (char *)consbuf
❌️ Cannot access memory at address 0xb4bc0
(gdb) printf "%s\n", (char *)kmsg_buffer
❌️ Cannot access memory at address 0xbad28
(gdb) printf "%s\n", (char *)0xffff0000402b4bc0
GNU Mach 1.8
Kernel command line: gnumach -H
Booting in EL1
vm_page: page table size: 262144 entries (24576k)
vm_page: DMA: pages: 262144 (1024M), free: 220847 (862M)
vm_page: DMA: min:13107 low:15728 high:26214
Model name: linux dummy-virt
module 0: example --host-priv-port=${host-port}
--device-master-port=${device-port} $(task-create) $(task-resume)
1 bootstrap modules
task loaded: example --host-priv-port=1 --device-master-port=2
start example:
(gdb) printf "%s\n", (char *)0xffff0000402bad28
GNU Mach 1.8
Kernel command line: gnumach -H
Booting in EL1
vm_page: page table size: 262144 entries (24576k)
vm_page: DMA: pages: 262144 (1024M), free: 220847 (862M)
vm_page: DMA: min:13107 low:15728 high:26214
Model name: linux dummy-virt
module 0: example --host-priv-port=${host-port}
--device-master-port=${device-port} $(task-create) $(task-resume)
1 bootstrap modules
task loaded: example --host-priv-port=1 --device-master-port=2
start example:
Gianluca