FPU disabled on VCU-118

Greetings. I have been trying to synthesize NOEL-V in the Xilinx VCU-118. I have reached a functional implementation, with GRMON successfully reporting the system information.

Unfortunately, I have not been able to get Linux to boot. In some attempts at debugging, I found it might be cause of the FPU being missing. This agrees with GRMON’s “float” command reporting “FPU is disabled!” and “reg” reporting the same.

I have seen that nanofpunv should be instantiated, so I don’t understand why this might be a problem.
One last resort would be trying to synthesize GRFPU instead.

I would appreciate any suggestions.
Daniel.

You can use GRMON command ‘info sys’ to print a detailed report, check if D & F extension is supported by hardware.

  dm0        Frontgrade Gaisler  RISC-V Debug Module
             AHB Master 9
             AHB: f6000000 - f7000000
             hart0: DXLEN 64, MXLEN 64, SXLEN 64, UXLEN 64
                    ISA A C D F H I M X,  Modes M S U
                    Stack pointer 0xbffffff0
                    icache 4 * 4 kB, 32 B/line, dir
                    dcache 4 * 4 kB, 32 B/line, dir
                    5 triggers,
                    itrace 64 lines

The ‘float’ and ‘reg’ command can not show the FPU registers, maybe this is a GRMON bug, I will feedback this issue in another post.

But it doesn’t affect Linux boot.

Thank you for your reply. In fact, this seems to be the case, as info sys does adequately report that the target supports floating point extensions:

dm0        Frontgrade Gaisler  RISC-V Debug Module
             AHB: fe000000 - ff000000
             hart0: DXLEN 64, MXLEN 64, SXLEN 64, UXLEN 64
                    ISA A C D F H I M P,  Modes M S U
                    Stack pointer 0x7ffffff0
                    icache 4 * 4 kB, 32 B/line, dir
                    dcache 4 * 4 kB, 32 B/line, dir
                    3 triggers,
                    itrace 64 lines

Unfortunately, then it seems that other problem is causing Linux not to boot, as I am receiving a signal 4 (SIGILL), which I thought was caused by this.
Do you have any pointer to where I should be looking? Maybe I got the device tree wrong? How can I debug further?
Thank you again for your response.

Kernel panic log:

[   24.722096] debug_vm_pgtable: [debug_vm_pgtable         ]: Validating architecture
[   24.880624] Freeing unused kernel image (initmem) memory: 9584K
[   24.917968] Run /init as init process
[   24.959391] init[1]: unhandled signal 4 code 0x1 at 0x0000003f99feece0 in ld-linux-
[   25.028080] CPU: 0 PID: 1 Comm: init Not tainted 6.3.0 #2
[   25.064813] Hardware name: noel-min64-sc (DT)
[   25.092591] epc : 0000003f99feece0 ra : 0000003f99fe88e8 sp : 0000003ffeced2e0
[   25.138698]  gp : ffffffff81b00400 tp : 0000000000000000 t0 : 0000000000000018
[   25.183207]  t1 : 0000003f99fd7dac t2 : 0000000000000008 s0 : 0000003f99ff9208
[   25.228968]  s1 : 0000003f99ff92b0 a0 : 0000003ffeced318 a1 : 0000000000000000
[   25.274545]  a2 : 0000003ffeced518 a3 : 2424242424242424 a4 : 0000000000000024
[   25.321273]  a5 : 0000003ffeced308 a6 : 870303010103030f a7 : 24160a4b570a5248
[   25.367980]  s2 : 0000003f99ff92b0 s3 : 0000003ffeced480 s4 : 0000000000000000
[   25.412377]  s5 : 0000000000000000 s6 : 0000000000000001 s7 : 0000002ae16ebe49
[   25.458122]  s8 : 0000003ffeced480 s9 : 0000002ae17d7de0 s10: 0000003ffeced480
[   25.504187]  s11: 0000003ffeced480 t3 : 0000003f99fe8870 t4 : 00000000ffffffff
[   25.548393]  t5 : 0000003ffeced818 t6 : 0000003ffeced814
[   25.581627] status: 0000000200000020 badaddr: 0000000006853827 cause: 0000000000000002
[   25.634056] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000004
[   25.681189] CPU: 0 PID: 1 Comm: init Not tainted 6.3.0 #2
[   25.715322] Hardware name: noel-min64-sc (DT)
[   25.742104] Call Trace:
[   25.757154] [<ffffffff800053be>] dump_backtrace+0x1c/0x24
[   25.791105] [<ffffffff8086b450>] show_stack+0x2c/0x38
[   25.822299] [<ffffffff808766ca>] dump_stack_lvl+0x3c/0x54
[   25.855395] [<ffffffff808766f6>] dump_stack+0x14/0x1c
[   25.886001] [<ffffffff8086b7ea>] panic+0x106/0x29e
[   25.915481] [<ffffffff800133f0>] do_exit+0x73c/0x742
[   25.945857] [<ffffffff8001356a>] do_group_exit+0x24/0x70
[   25.978072] [<ffffffff8001df9c>] get_signal+0x694/0x6e6
[   26.009607] [<ffffffff800046ba>] do_work_pending+0xfc/0x3e2
[   26.058108] [<ffffffff8000378a>] resume_userspace_slow+0x8/0xa
[   26.096256] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000004 ]---

I guess it’s a configuration mismatch between Buildroot and Linux.

Buildroot: Target options > Target Architecture Variant > [*] General purpose (G)
Buildroot: Target options > Target ABI   > [*] lp64d

Linux: General setup > Platform type > -*- Emit compressed instructions when building Linux
Linux: General setup > Platform type > [*] FPU support

Hello. Those options are already present in the buildroot configuration. In fact, even the prebuilt noel64 images panic with the same exact error. I am unsure what could be causing this panic, as it does not seem to depend on the buildroot/linux kernel configuration.

How did your DTS describe it.

riscv,isa = "rv64imafdc";

Hello, it describes it as “g”, general purpose, although I have also tried using your extensions with the same (un)success.