Wind River Support Network

HomeDefectsLIN1022-1273
Fixed

LIN1022-1273 : aptiv: boot caught kmemleak at of_platform_device_create_pdata+0xc8/0x100

Created: Aug 9, 2022    Updated: Sep 6, 2022
Resolved Date: Sep 6, 2022
Found In Version: 10.22.33.1
Severity: Standard
Applicable for: Wind River Linux LTS 22
Component/s: Kernel

Description

root@aptivcvcsousa:~# uname -a
caLinux aptivcvcsousa 5.15.58-rt48-yocto-preempt-rt #1 SMP PREEMPT_RT Mon Aug 1 16:37:30 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
troot@aptivcvcsousa:~# cat /proc/version
cLinux version 5.15.58-rt48-yocto-preempt-rt (oe-user@oe-host) (aarch64-wrs-linux-gcc (GCC) 11.3.0, GNU ld (GNU Binutils) 2.38.20220623) #1 SMP PREEMPT_RT Mon Aug 1 16:37:30 UTC 2022
root@aptivcvcsousa:~# cat /proc/cmdline
cconsole=ttyLF0,115200n8 earlycon nohz=off coherent_pool=64M rw root=/dev/nfs nfsroot=128.224.165.20:/export/pxeboot/vlm-boards/29266/rootfs,nolock,v3,tcp ip=128.224.165.112:128.224.165.20:128.224.165.1:255.255.255.0::eth0:off
aroot@aptivcvcsousa:~# cat /etc/os-release
/opID=wrlinux
NAME="Wind River Linux Base"
VERSION="10.22.17.1"
VERSION_ID=10.22.17.1
PRETTY_NAME="Wind River Linux Base 22.17 Update 1"
troot@aptivcvcsousa:~# /opt/wr-test/main_test.py -k aarch64_exploring_test: -q
... ...

root@aptivcvcsousa:/opt/wr-test/testcases/bts/aarch64_exploring_test# cat /sys/kernel/debug/kmemleak |grep -E -B10 -A50 'kmemleak_alloc|kmem_cache_alloc' ||return 0
<ffffffc009541a98>] driver_init+0x3c/0x54
[<ffffffc009501840>] kernel_init_freeable+0xf8/0x130
[<ffffffc008fe5d04>] kernel_init+0x30/0x13c
[<ffffffc0080176a0>] ret_from_fork+0x10/0x20
unreferenced object 0xffffff880274d200 (size 128):
comm "swapper/0", pid 1, jiffies 4294893077 (age 573.956s)
hex dump (first 32 bytes):
f8 68 7c 7f 88 ff ff ff 20 69 7c 7f 88 ff ff ff .h (..... i|.....
20 69 7c 7f 88 ff ff ff e0 de 7f 7f 88 ff ff ff i|.............
backtrace:
[<ffffffc0082f181c>) kmem_cache_alloc_trace+0x198/0x27c
[<ffffffc008a11f44>] fwnode_link_add+0x94/0x114
[<ffffffc008cf4190>] of_fwnode_add_links+0x1f0/0x220
[<ffffffc008a0e9a4>] fw_devlink_parse_fwtree+0x44/0x90
[<ffffffc008a0e9cc>] fw_devlink_parse_fwtree+0x6c/0x90
[<ffffffc008a0e9cc>] fw_devlink_parse_fwtree+0x6c/0x90
[<ffffffc008a12b4c>] device_add+0x528/0x6ec
[<ffffffc008cf1dc0>] of_device_add+0x60/0x70
[<ffffffc008cf2748>] of_platform_device_create_pdata+0xc8/0x100
[<ffffffc008cf293c>] of_platform_bus_create+0x18c/0x230
[<ffffffc008cf2b3c>] of_platform_populate+0x5c/0xe0
[<ffffffc009550a10>] of_platform_default_populate_init+0xb4/0xd4
[<ffffffc00801588c>] do_one_initcall+0x9c/0x4b0
[<ffffffc009501690>] do_initcalls+0x104/0x144
[<ffffffc009501848>] kernel_init_freeable+0x100/0x130
[<ffffffc008fe5d04>] kernel_init+0x30/0x13c
h4.

Steps to Reproduce

/lpg-build/cdc/fast_prod/WRL10_22/WRL10_22_GIT/wrlinux-10/setup.sh --machines aptiv_cvc_sousa --templates feature/docker feature/kernel-hardening --distro wrlinux --dl-layers --accept-eula=yes
source environment-setup-x86_64-wrlinuxsdk-linux
source oe-init-build-env build
echo 'PREFERRED_PROVIDER_virtual/kernel = "linux-yocto-rt"' >> conf/local.conf
bitbake-layers add-layer /lpg-build/cdc/WASSP_LINUX_1022/testcases/wrlinux/wr-testing/bts-dev
echo 'require templates/feature/bts/template.conf' >> conf/local.conf
bitbake wrlinux-image-std
Live chat
Online