Malta Target Kernel panic in qemu

I'm attempting to run the Malta LE target in Qemu, but am getting a kernel panic on startup.

This is happening on the current snapshot, but have also tried 24.10.0-rc4 and get the same issue.

Qemu version:

"C:\Program Files\qemu\qemu-system-mipsel.exe" --version
QEMU emulator version 9.2.0 (v9.2.0-12071-g3dd0aeb44b)
Copyright (c) 2003-2024 Fabrice Bellard and the QEMU Project developers

Output:

>"C:\Program Files\qemu\qemu-system-mipsel.exe" -M malta -hda openwrt-malta-le-rootfs-ext4.img -kernel openwrt-malta-le-vmlinux.elf -nographic -m 512 -append "root=/dev/sda console=ttyS0 rootfstype=ext4 init=/bin/sh"
WARNING: Image format was not specified for 'openwrt-malta-le-rootfs-ext4.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
[    0.000000] Linux version 6.6.67 (builder@buildhost) (mipsel-openwrt-linux-musl-gcc (OpenWrt GCC 13.3.0 r28410-a85059438f) 13.3.0, GNU ld (GNU Binutils) 2.42) #0 SMP Thu Dec 26 17:18:06 2024
[    0.000000] earlycon: uart8250 at I/O port 0x3f8 (options '38400n8')
[    0.000000] printk: bootconsole [uart8250] enabled
[    0.000000] CPU0 revision is: 00019300 (MIPS 24Kc)
[    0.000000] MIPS: machine is mti,malta
[    0.000000] Software DMA cache coherency enabled
[    0.000000] Primary instruction cache 2kB, VIPT, 2-way, linesize 16 bytes.
[    0.000000] Primary data cache 2kB, 2-way, VIPT, no aliases, linesize 16 bytes
[    0.000000] Zone ranges:
[    0.000000]   DMA      [mem 0x0000000000000000-0x0000000000ffffff]
[    0.000000]   Normal   [mem 0x0000000001000000-0x000000001fffffff]
[    0.000000]   HighMem  [mem 0x0000000020000000-0x000000009fffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000]   node   0: [mem 0x0000000090000000-0x000000009fffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x000000009fffffff]
[    0.000000] On node 0, zone HighMem: 524288 pages in unavailable ranges
[    0.000000] random: crng init done
[    0.000000] percpu: Embedded 13 pages/cpu s20896 r8192 d24160 u53248
[    0.000000] Kernel command line: root=/dev/sda console=ttyS0 rootfstype=ext4 init=/bin/sh
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes, linear)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes, linear)
[    0.000000] Writing ErrCtl register=00000000
[    0.000000] Readback ErrCtl register=00000000
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 129920
[    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[    0.000000] Memory: 488752K/524288K available (8298K kernel code, 668K rwdata, 1724K rodata, 244K init, 257K bss, 35536K reserved, 0K cma-reserved, 262144K highmem)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] rcu: Hierarchical RCU implementation.
[    0.000000] rcu:     RCU restricting CPUs from NR_CPUS=2 to nr_cpu_ids=1.
[    0.000000]  Tracing variant of Tasks RCU enabled.
[    0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000] rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[    0.000000] NR_IRQS: 256
[    0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[    0.000000] CPU frequency 320.00 MHz
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 11945341957 ns
[    0.000249] sched_clock: 32 bits at 160MHz, resolution 6ns, wraps every 13421732860ns
[    0.006279] Console: colour dummy device 80x25
[    0.011881] Calibrating delay loop... 835.58 BogoMIPS (lpj=4177920)
[    0.094153] pid_max: default: 32768 minimum: 301
[    0.098190] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.099892] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.135120] RCU Tasks Trace: Setting shift to 0 and lim to 1 rcu_task_cb_adjust=1 rcu_task_cpu_ids=1.
[    0.138747] rcu: Hierarchical SRCU implementation.
[    0.139837] rcu:     Max phase no-delay instances is 1000.
[    0.145104] smp: Bringing up secondary CPUs ...
[    0.146522] smp: Brought up 1 node, 1 CPU
[    0.159233] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.161462] futex hash table entries: 256 (order: 2, 16384 bytes, linear)
[    0.173005] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[    0.179913] thermal_sys: Registered thermal governor 'step_wise'
[    0.199961] SCSI subsystem initialized
[    0.214720] PCI host bridge to bus 0000:00
[    0.216087] pci_bus 0000:00: root bus resource [mem 0x10000000-0x17ffffff]
[    0.218392] pci_bus 0000:00: root bus resource [io  0x1000-0x1fffff]
[    0.219789] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[    0.223114] pci 0000:00:00.0: [11ab:4620] type 00 class 0x060000
[    0.225326] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x00000fff pref]
[    0.226831] pci 0000:00:00.0: reg 0x14: [mem 0x01000000-0x01000fff pref]
[    0.228324] pci 0000:00:00.0: reg 0x18: [mem 0x1c000000-0x1c000fff]
[    0.229607] pci 0000:00:00.0: reg 0x1c: [mem 0x1f000000-0x1f000fff]
[    0.230985] pci 0000:00:00.0: reg 0x20: [mem 0x1be00000-0x1be00fff]
[    0.232366] pci 0000:00:00.0: reg 0x24: [io  0x14000000-0x14000fff]
[    0.235913] pci 0000:00:0a.0: [8086:7110] type 00 class 0x060100
[    0.237914] pci 0000:00:0a.1: [8086:7111] type 00 class 0x010180
[    0.239271] pci 0000:00:0a.1: reg 0x20: [io  0x0000-0x000f]
[    0.240432] pci 0000:00:0a.1: legacy IDE quirk: reg 0x10: [io  0x01f0-0x01f7]
[    0.241920] pci 0000:00:0a.1: legacy IDE quirk: reg 0x14: [io  0x03f6]
[    0.243602] pci 0000:00:0a.1: legacy IDE quirk: reg 0x18: [io  0x0170-0x0177]
[    0.245439] pci 0000:00:0a.1: legacy IDE quirk: reg 0x1c: [io  0x0376]
[    0.247423] pci 0000:00:0a.2: [8086:7112] type 00 class 0x0c0300
[    0.248900] pci 0000:00:0a.2: reg 0x20: [io  0x0000-0x001f]
[    0.250968] pci 0000:00:0a.3: [8086:7113] type 00 class 0x068000
[    0.252665] pci 0000:00:0a.3: quirk: [io  0x1000-0x103f] claimed by PIIX4 ACPI
[    0.254402] pci 0000:00:0a.3: quirk: [io  0x1100-0x110f] claimed by PIIX4 SMB
[    0.256616] pci 0000:00:0b.0: [1022:2000] type 00 class 0x020000
[    0.257932] pci 0000:00:0b.0: reg 0x10: [io  0x0000-0x001f]
[    0.259111] pci 0000:00:0b.0: reg 0x14: [mem 0x00000000-0x0000001f]
[    0.260465] pci 0000:00:0b.0: reg 0x30: [mem 0x00000000-0x0003ffff pref]
[    0.262246] pci 0000:00:12.0: [1013:00b8] type 00 class 0x030000
[    0.263586] pci 0000:00:12.0: reg 0x10: [mem 0x00000000-0x01ffffff pref]
[    0.264943] pci 0000:00:12.0: reg 0x14: [mem 0x00000000-0x00000fff]
[    0.266239] pci 0000:00:12.0: reg 0x30: [mem 0x00000000-0x0000ffff pref]
[    0.268305] pci_bus 0000:00: busn_res: [bus 00-ff] end is updated to 00
[    0.271325] pci 0000:00:12.0: BAR 0: assigned [mem 0x10000000-0x11ffffff pref]
[    0.273182] pci 0000:00:0b.0: BAR 6: assigned [mem 0x12000000-0x1203ffff pref]
[    0.274855] pci 0000:00:12.0: BAR 6: assigned [mem 0x12040000-0x1204ffff pref]
[    0.276416] pci 0000:00:12.0: BAR 1: assigned [mem 0x12050000-0x12050fff]
[    0.277882] pci 0000:00:0a.2: BAR 4: assigned [io  0x1040-0x105f]
[    0.279107] pci 0000:00:0b.0: BAR 0: assigned [io  0x1060-0x107f]
[    0.280315] pci 0000:00:0b.0: BAR 1: assigned [mem 0x12051000-0x1205101f]
[    0.281762] pci 0000:00:0a.1: BAR 4: assigned [io  0x1080-0x108f]
[    0.288212] clocksource: Switched to clocksource MIPS
[    0.290758] VFS: Disk quotas dquot_6.6.0
[    0.291930] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    0.302518] NET: Registered PF_INET protocol family
[    0.305485] IP idents hash table entries: 4096 (order: 3, 32768 bytes, linear)
[    0.314601] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes, linear)
[    0.317099] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
[    0.318901] TCP established hash table entries: 2048 (order: 1, 8192 bytes, linear)
[    0.320795] TCP bind hash table entries: 2048 (order: 3, 32768 bytes, linear)
[    0.322808] TCP: Hash tables configured (established 2048 bind 2048)
[    0.326306] MPTCP token hash table entries: 256 (order: 0, 4096 bytes, linear)
[    0.328726] UDP hash table entries: 256 (order: 1, 8192 bytes, linear)
[    0.330336] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes, linear)
[    0.333493] NET: Registered PF_UNIX/PF_LOCAL protocol family
[    0.336176] pci 0000:00:0a.2: enabling device (0000 -> 0001)
[    0.338242] PCI: CLS 0 bytes, default 16
[    0.360977] workingset: timestamp_bits=14 max_order=17 bucket_order=3
[    0.364759] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.366232] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    0.373627] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
[    0.381165] Serial: 8250/16550 driver, 16 ports, IRQ sharing enabled
[    0.389804] printk: console [ttyS0] disabled
[    0.405526] serial8250.0: ttyS0 at I/O 0x3f8 (irq = 4, base_baud = 115200) is a 16550A
[    0.408181] serial8250.0: ttyS0 extra baud rates supported: 230400, 460800
[    0.408181] serial8250.0: ttyS0 extra baud rates supported: 230400, 460800
[    0.409953] printk: console [ttyS0] enabled
[    0.409953] printk: console [ttyS0] enabled
[    0.414940] printk: bootconsole [uart8250] disabled
[    0.414940] printk: bootconsole [uart8250] disabled
[    0.447344] serial8250.0: ttyS1 at I/O 0x2f8 (irq = 3, base_baud = 115200) is a 16550A
[    0.449519] serial8250.0: ttyS1 extra baud rates supported: 230400, 460800
[    0.461441] serial8250.0: ttyS2 at MMIO 0x1f000900 (irq = 20, base_baud = 230400) is a 16550A
[    0.504307] brd: module loaded
[    0.518832] loop: module loaded
[    0.521101] ata_piix 0000:00:0a.1: enabling device (0000 -> 0001)
[    0.532150] scsi host0: ata_piix
[    0.535240] scsi host1: ata_piix
[    0.536654] ata1: PATA max UDMA/33 cmd 0x1f0 ctl 0x3f6 bmdma 0x1080 irq 14
[    0.538328] ata2: PATA max UDMA/33 cmd 0x170 ctl 0x376 bmdma 0x1088 irq 15
[    0.543581] mousedev: PS/2 mouse device common for all mice
[    0.548582] rtc_cmos 70.rtc: registered as rtc0
[    0.550822] rtc_cmos 70.rtc: setting system clock to 2024-12-28T07:09:28 UTC (1735369768)
[    0.553081] rtc_cmos 70.rtc: alarms up to one day, 242 bytes nvram
[    0.558494] NET: Registered PF_INET6 protocol family
[    0.574863] Segment Routing with IPv6
[    0.576127] In-situ OAM (IOAM) with IPv6
[    0.577820] NET: Registered PF_PACKET protocol family
[    0.579535] bridge: filtering via arp/ip/ip6tables is no longer available by default. Update your scripts to load br_netfilter if you need this.
[    0.582908] 8021q: 802.1Q VLAN Support v1.8
[    0.639197] clk: Disabling unused clocks
[    0.728143] ata1: found unknown device (class 0)
[    0.734609] ata2: found unknown device (class 0)
[    0.738127] ata2.00: ATAPI: QEMU DVD-ROM, 2.5+, max UDMA/100
[    0.741521] ata1.00: ATA-7: QEMU HARDDISK, 2.5+, max UDMA/100
[    0.743022] ata1.00: 212992 sectors, multi 16: LBA48
[    0.755182] scsi 0:0:0:0: Direct-Access     ATA      QEMU HARDDISK    2.5+ PQ: 0 ANSI: 5
[    0.762720] sd 0:0:0:0: [sda] 212992 512-byte logical blocks: (109 MB/104 MiB)
[    0.765191] sd 0:0:0:0: [sda] Write Protect is off
[    0.767035] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[    0.769556] sd 0:0:0:0: [sda] Preferred minimum I/O size 512 bytes
[    0.775719] scsi 1:0:0:0: CD-ROM            QEMU     QEMU DVD-ROM     2.5+ PQ: 0 ANSI: 5
[    0.783773] sd 0:0:0:0: [sda] Attached SCSI disk
[    0.840308] EXT4-fs (sda): mounted filesystem ff313567-e9f1-5a5d-9895-3ba130b4a864 ro with ordered data mode. Quota mode: none.
[    0.844880] VFS: Mounted root (ext4 filesystem) readonly on device 8:0.
[    0.886225] Freeing unused kernel image (initmem) memory: 244K
[    0.887895] This architecture does not have kernel memory protection.
[    0.889482] Run /bin/sh as init process
[    0.947444] do_page_fault(): sending SIGSEGV to sh for invalid write access to 00000000
[    0.949153] epc = 77e091b4 in libc.so[77dd7000+b2000]
[    0.951083] ra  = 77e09710 in libc.so[77dd7000+b2000]
[    0.954361] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
[    0.956743] Rebooting in 1 seconds..

Any ideas?

Arghh it looks like a qemu bug. Dropping back to 9.1.0 worked.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.