Wind River Support Network


LIN6-8778 : implicit declaration of function 'kzalloc' Breaks Kernel Build with defconfig

Created: Nov 19, 2014    Updated: Dec 3, 2018
Resolved Date: Nov 27, 2014
Found In Version:
Fix Version:
Severity: Standard
Applicable for: Wind River Linux 6
Component/s: Build & Config


Customer created linux-windriver_3.10.bbappend in the custom layer to pull in default kernel config for their project:
FILESEXTRAPATHS_prepend := "${THISDIR}/files:${THISDIR}/${PN}-${PV}:"
SRC_URI += "file://defconfig"

This worked in WRL6.0.0.2, but now this started causing compilation errors in WRL6.0.0.13 ( + fix for bug LIN6-8628 applied), like the compilation error:

| /linux/wrlinux/bitbake_build/tmp/work/intel_x86_64-wrs-linux/linux-windriver/3.10-r0/linux/arch/x86/platform/intel-atom/platform_camera.c: In function 'camera_sensor_csi':
| /linux/wrlinux/bitbake_build/tmp/work/intel_x86_64-wrs-linux/linux-windriver/3.10-r0/linux/arch/x86/platform/intel-atom/platform_camera.c:172:3: error: implicit declaration of function 'kzalloc' [-Werror=implicit-function-declaration]
| csi = kzalloc(sizeof(*csi), GFP_KERNEL);
| ^


Customer was able to work around this issue by patching platform_camera.c to include <linux/slab.h>

Steps to Reproduce

1. configure --enable-reconfig --enable-board=intel-x86-64 --enable-kernel=standard --enable-rootfs=glibc_small --enable-bootimage=cpio.gz --with-layer=../custom_layer --with-rcpl-version=0013
2. make -C build linux-windriver

Other Downloads

Live chat