cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
hu_kang
Adventurer
Adventurer
1,151 Views
Registered: ‎10-28-2018

petalinux2019.1: Kernel configuration is invalid

Hi,

I'm running petalinux and building a kernel-module for linux

The first build is ok, but after a minor modification( add one empty row in the c file),

petalinux-build reports error:

ERROR: dla-1.0-r0 do_compile: oe_runmake failed 
ERROR: dla-1.0-r0 do_compile: Function failed: do_compile (log file is located at /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/temp/log.do_compile.1162)
ERROR: Logfile of failure stored in: /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/temp/log.do_compile.1162
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 12 KERNEL_src=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source KERNEL_PATH=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1
.4/build/tmp/work-shared/plnx-zynqmp/kernel-source KERNEL_VERSION=4.19.0-xilinx-v2019.1 CC=aarch64-xilinx-linux-gcc   -fuse-ld=bfd -fdebug-prefix-map=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/wor
k/plnx_zynqmp-xilinx-linux/dla/1.0-r0=/usr/src/debug/dla/1.0-r0 -fdebug-prefix-map=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/recipe-sysroot= -fdebug-prefi
x-map=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/recipe-sysroot-native=  -fdebug-prefix-map=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2
019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source=/usr/src/kernel LD=aarch64-xilinx-linux-ld.bfd   AR=aarch64-xilinx-linux-ar  O=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/p
lnx-zynqmp/kernel-build-artifacts KBUILD_EXTRA_SYMBOLS=
| make -C /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source M=/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-
xilinx-linux/dla/1.0-r0
| make[1]: Entering directory '/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source'
| make[2]: Entering directory '/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-build-artifacts'
|  
|   ERROR: Kernel configuration is invalid.
|          include/generated/autoconf.h or include/config/auto.conf are missing.
|          Run 'make oldconfig && make prepare' on kernel src to fix it.
|  
| make[2]: *** [/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source/Makefile:643: include/config/auto.conf] Error 1
| make[2]: Leaving directory '/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-build-artifacts'
| make[1]: *** [Makefile:146: sub-make] Error 2
| make[1]: Leaving directory '/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work-shared/plnx-zynqmp/kernel-source'
| make: *** [Makefile:6: all] Error 2
| ERROR: oe_runmake failed
| WARNING: /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/temp/run.do_compile.1162:1 exit 1 from 'exit 1'
| ERROR: Function failed: do_compile (log file is located at /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/build/tmp/work/plnx_zynqmp-xilinx-linux/dla/1.0-r0/temp/log.do_compile.1162)
ERROR: Task (/home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/project-spec/meta-user/recipes-modules/dla/dla.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 8221 tasks of which 8220 didn't need to be rerun and 1 failed.

Summary: 1 task failed:
 /home/hukang/data/Downloads/AI_SDK/SD_image/xilinx-ultra96v2-v2019.1-dpu1.4/project-spec/meta-user/recipes-modules/dla/dla.bb:do_compile
Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
ERROR: Failed to build project

How to resolve this?

If I'm to run 

make oldconfig && make prepare

How can it be done since everything is using petalinux commands?

ps.

remove the module and re-create one still gives the same error

Regards,
Kang
0 Kudos
Reply
1 Reply
shabbirk
Moderator
Moderator
1,126 Views
Registered: ‎12-04-2016

Hi @hu_kang 

I hope you are making this additional modification in the module file resides in recipe-modules of petalinux

Can you try cleaning the project and rebuild using: petalinux-build -x mrproper, petalinux-build

0 Kudos
Reply