Open ZZPHUB opened 1 year ago
same here when trying to compile a kernel module:
make -C /lib/modules/5.15.0-starfive/build M=
pwd
modules make[1]: Entering directory '/usr/src/linux-headers-5.15.0-starfive' scripts/Makefile.build:44: arch/riscv/kernel/vdso/Makefile: No such file or directory make[2]: No rule to make target 'arch/riscv/kernel/vdso/Makefile'. Stop. make[1]: [arch/riscv/Makefile:120: vdso_prepare] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-starfive' make: *** [Makefile:8: all] Error 2
same here when trying to compile a kernel module:
make -C /lib/modules/5.15.0-starfive/build M=
pwd
modules make[1]: Entering directory '/usr/src/linux-headers-5.15.0-starfive' scripts/Makefile.build:44: arch/riscv/kernel/vdso/Makefile: No such file or directory make[2]: No rule to make target 'arch/riscv/kernel/vdso/Makefile'. Stop. make[1]: [arch/riscv/Makefile:120: vdso_prepare] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-starfive' make: *** [Makefile:8: all] Error 2
i use cross compile to solve this problem,and it can work well.but i donnot know how to build in vf2 board.
i use img debian 69 and the toolchain is the gcc that i installed by apt in the 69img
and i git cloned the linux source form here,then i follow this doc to build the img to configure the settings.and i use this way to build,the makefile:
i can get the .ko file but i cannot insmod this file.the message is
when i use the command
dmesg |grep hellodev(the mode name)
,the message is:so,i change the makefile:
but the err message is :