32MiB Plan
Closed this issue · 3 comments
gtxzsxxk commented
32MiB
0x0000_0000: ROM START
0x8000_0000: U-boot, (Kernel Decompress Start)
512KiB U-boot
0x813a_0000: Compressed Kernel at
10MiB
0x81da_0000: Uboot reloc
2MiB
0x81fa_0000: OpenSBI
384KiB
0x81ff_d800: FDT
10KiB
0x8200_0000: RAM end 32MiB
unzip 0x813a0000 0x80000000
setenv bootargs earlycon=sbi console=ttyS0,115200 root=/dev/ram0
bootm 0x80000000 - 0x81ffd800
make ARCH=riscv CROSS_COMPILE=riscv32-buildroot-linux-gnu- -j64 && \
mkimage -A riscv -O linux -T kernel -C none -a 0x80000000 -e 0x80000000 -d arch/riscv/boot/Image uImage && \
gzip -c uImage > uImage.gz
Available memory for kernel: 30.625MiB
--addr=0x81fa0000
--exec=fw_jump.bin
--with=0x80000000#u-boot.bin
--with=0x81ffd800#u-boot.dtb
--with=0x813a0000#uImage.gz
gtxzsxxk commented
[ 0.547875][ T1] printk: legacy console [ttyS0] enabled
[ 0.547875][ T1] printk: legacy console [ttyS0] enabled
[ 0.548139][ T1] printk: legacy bootconsole [sbi0] disabled
[ 0.548139][ T1] printk: legacy bootconsole [sbi0] disabled
[ 0.550688][ T1] uart_add_one_port: 0
[ 0.550824][ T1] serial8250_register_8250_port: 0
[ 0.555397][ T1] brd: module loaded
[ 0.555554][ T1] start plist test
[ 0.641246][ T1] end plist test
[ 0.67] clk: Disabling unused clocks
[ 0.696332][ T1] Freeing unused kernel image (initmem) memory: 3684K
[ 0.696528][ T1] Kernel memory protection not selected by kernel config.
[ 0.696738][ T1] Run /init as init process
[ 0.696881][ T1] with arguments:
[ 0.697005][ T1] /init
[ 0.697122][ T1] with environment:
[ 0.697250][ T1] HOME=/
[ 0.697368][ T1] TERM=linux
[ 0.698951][ T1] resched_offsets_ok(offsets) 1 !irqs_disabled() 0 !is_idle_task(current) 1 !current->non_block_count 1 system_state 3 oops_in_progress 0
[ 0.698951][ T1] jiffies -75000 prev_jiffy 0
[ 0.699411][ T1] BUG: sleeping function called from invalid context at include/linux/sched/mm.h:306
[ 0.699657][ T1] in_atomic(): 0, irqs_disabled(): 1, non_block: 0, pid: 1, name: init
[ 0.699899][ T1] preempt_count: 0, expected: 0
[ 0.700061][ T1] CPU: 0 PID: 1 Comm: init Not tainted 6.8.0-rc4-00003-g5c38432532a3-dirty #89
[ 0.700332][ T1] Call Trace:
[ 0.700456][ T1] [<c0004070>] dump_backtrace+0x2c/0x3c
[ 0.700690][ T1] [<c00040bc>] show_stack+0x3c/0x50
[ 0.700916][ T1] [<c01d61d4>] dump_stack_lvl+0x34/0x50
[ 0.701171][ T1] [<c01d620c>] dump_stack+0x1c/0x2c
[ 0.701418][ T1] [<c0029630>] __might_resched+0x144/0x16c
[ 0.701643][ T1] [<c00296c0>] __might_sleep+0x68/0x80
[ 0.701860][ T1] [<c00ae54c>] might_alloc+0x28/0x3c
[ 0.702102][ T1] [<c00b022c>] kmem_cache_alloc+0x38/0x138
[ 0.702360][ T1] [<c0007340>] vm_area_alloc+0x30/0x80
[ 0.702608][ T1] [<c009e26c>] mmap_region+0x200/0x61c
[ 0.2849] T1] [<c009ea58>] do_mmap+0x3d0/0x418
[ 0.703083][ T1] [<c00868fc>] vm_mmap_pgoff+0x80/0xc8
[ 0.703338][ T1] [<c0086984>] vm_mmap+0x40/0x5c
[ 0.703583][ T1] [<c0103c20>] elf_load+0x94/0x200
[ 0.703812][ T1] [<c01044b0>] load_elf_binary+0x6f8/0xe44
[ 0.704058][ T1] [<c00c0d70>] bprm_execve+0x25c/0x38c
[ 0.704279][ T1] [<c00c1620>] kernel_execve+0x158/0x168
[ 0.704507][ T1] [<c000108c>] run_init_process+0x8c/0xd0
[ 0.704731][ T1] [<c01ef3f8>] kernel_init+0x70/0x134
[ 0.704979][ T1] [<c01f5740>] ret_from_fork+0x14/0x24
[ 0.714977][ T1] init[1]: unhandled signal 11 code 0x2 at 0x955e9974 in libc.so.6[955b7000+139000]
[ 0.715367][ T1] CPU: 0 PID: 1 Comm: init Tainted: G W 6.8.0-rc4-00003-g5c38432532a3-dirty #89
[ 0.715668][ T1] epc : 955e9974 ra : 955d5d24 sp : 9d2c6e70
[ 0.715876][ T1] gp : 6915c800 tp : 957092c0 t0 : 956b9fac
[ 0.71608[ T1] t1 : 6907c0ac t2 : 0000000a s0 : 9d2c6ed4
[ 0.716285][ T1] s1 : 95710d90 a0 : 956f34c8 a1 : 00000000
[ 0.716487][ T1] a2 : 00000000 a3 : 956f2388 a4 : 00000001
[ 0.716682][ T1] a5 : 00000000 a6 : 9d2c6ed0 a7 : 5aff4045
[ 0.716884][ T1] s2 : 00000000 s3 : 00000000 s4 : 956f2388
[ 0.717079][ T1] s5 : 00000000 s6 : 00000000 s7 : 00000000
[ 0.717268][ T1] s8 : 00000000 s9 : 00000000 s10: 00000000
[ 0.717457][ T1] s11: 00000000 t3 : 955d5cd4 t4 : 9570d3f4
[ 0.717659][ T1] t5 : 9d2c69b8 t6 : 70000025
[ 0.717829][ T1] status: 00000022 badaddr: 956f34c8 cause: 00000005
[ 0.718127][ T1] Code: 9517 0010 2503 3745 0713 0010 27af 1005 9663 0007 (26af) 1ce5
[ 0.718419][ T1] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
[ 0.718645][ T1] CPU: 0 PID: 1 Comm: init Tainted: G W 6.8.0-rc4-00003-g5c38432532a3-dirty #8[ 0.718946][ T1] Call Trace:
[ 0.719070][ T1] [<c0004070>] dump_backtrace+0x2c/0x3c
[ 0.719304][ T1] [<c00040bc>] show_stack+0x3c/0x50
[ 0.719530][ T1] [<c01d61d4>] dump_stack_lvl+0x34/0x50
[ 0.9785][ T1] [<c01d620c>] dump_stack+0x1c/0x2c
[ 0.720032][ T1] [<c0009fe0>] panic+0x128/0x2c8
[ 0.720278][ T1] [<c000bedc>] do_exit+0x1e0/0x6cc
[ 0.720487][ T1] [<c000c52c>] do_group_exit+0x38/0xa0
[ 0.720704][ T1] [<c0016058>] get_signal+0x1a0/0x600
[ 0.720962][ T1] [<c0002cb8>] arch_do_signal_or_restart+0x80/0x2c0
[ 0.721218][ T1] [<c01ef0ac>] irqentry_exit_to_user_mode+0x7c/0xa0
[ 0.721491][ T1] [<c01ee8d4>] do_trap_load_fault+0x58/0xa8
[ 0.721747][ T1] [<c01f5680>] ret_from_exception+0x0/0xac
[ 0.721991][ T1] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b ]---
gtxzsxxk commented
[ 0.672097][ T1] VM mapping addr 1762500608 len 950272 prot 5 offset 0 into 1762500608
[ 0.672422][ T1] Loading ELF /init - 4 vaddr 941732 elf_ex->e_type 3
[ 0.672677][ T1] VM mapping addr 1763438592 len 12288 prot 3 offset 933888 into 1763438592
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x61000000
x6: 0x00000056
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x00000049
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0xc081fcc0
PC: 0xc01ee3d0
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x61000000
x6: 0x00000056
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x00000049
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3d4
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x61000000
x6: 0x00000056
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x00000049
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3d8
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x61000000
x6: 0x00000056
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3dc
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c176b
x6: 0x00000056
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3e0
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c176b
x6: 0x691c2000
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3e4
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c1768
x6: 0x691c2000
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3e8
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c1768
x6: 0x691c2000
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3ec
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c1768
x6: 0x691c2000
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01ee3f0
Emulator registers debug print
x0: 0x00000000
x1: 0xc0103d7c
x2: 0xc081fdf0
x3: 0xc06219e8
x4: 0xc0820000
x5: 0x691c1768
x6: 0x691c2000
x7: 0x616d204d
x8: 0xc081fe40
x9: 0x691c1768
x10: 0x691c1768
x11: 0x00000898
x12: 0x00000000
x13: 0x691c2000
x14: 0x000018c4
x15: 0x9d7ff768
x16: 0xc06010f0
x17: 0x00000018
x18: 0x691bf000
x19: 0x691c1d18
x20: 0xc1255c80
x21: 0x00000768
x22: 0x00000003
x23: 0x00001000
x24: 0x00000000
x25: 0x00000000
x26: 0xc05d5000
x27: 0x00000000
x28: 0xc0628973
x29: 0xc0628973
x30: 0xc0628974
x31: 0x00040000
PC: 0xc01f545c
[ 0.673039][ T1] Trying to clear_user: total_size 0 map_addr 1763438592 zero_start 1763448680 eppnt->p_vaddr 941732 eppnt->p_filesz 6340 eppnt->p_memsz 7796 prot 3 padzero 0
[ 0.673459][ T1] Loading ELF /init - 5 vaddr 945900 elf_ex->e_type 3
[ 0.673669][ T1] Loading ELF /init - 6 vaddr 408 elf_ex->e_type 3
[ 0.673873][ T1] Loading ELF /init - 7 vaddr 935764 elf_ex->e_t
[ 0.674083][ T1] Loading ELF /init - 8 vaddr 0 elf_ex->e_type 3
[ 0.674284][ T1] Loading ELF /init - 9 vaddr 941732 elf_ex->e_type 3
[ 0.674544][ T1] VM mapping addr 0 len 135168 prot 5 offset 0 into 2507055104
[ 0.674899][ T1] VM mapping addr 2507182080 len 8192 prot 3 offset 126976 into 2507182080
gtxzsxxk commented
make ARCH=riscv CROSS_COMPILE=riscv32-buildroot-linux-gnu- -j64 && \
mkimage -A riscv -O linux -T kernel -C none -a 0x80000000 -e 0x80000000 -d arch/riscv/boot/Image uImage && \
gzip -c uImage > uImage.gz && riscv32-buildroot-linux-gnu-objdump vmlinux > vmlinux.dump -D -M numeric,no-aliases