Skip to contentSkip to conversation

all external kernel modules fail to compile with with poky and linux 5.10-rc1

DISCUSSION Scott Branden 3 participants 5 messages Nov 12, 2020 – Nov 13, 2020

lore
Share & tools
lore
#1 lore raw
Quoted 5 lines · Scott Branden via lists.openembedded.org

It appears the all external modules fail to compile if you try using the 5.10-rc1 or later kernel due to this commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980

Has anyone tried to compile the latest kernel or has a fix for yocto?

linux-yocto-dev is on v5.10-rc3, and is running without issues. That includes on-target and external module tests passing.

That being said, there may be something different in the kernel recipes, or there's an artifact that we need to get into the kernel staging directory for what you are building.

Is there a reproducer that you can send, so I can test against it ?

Bruce

Quoted 3 lines
Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II
#2 lore raw

Hi Bruce,

Quoted 7 lines · Bruce Ashfield
Quoted 4 lines · Scott Branden via lists.openembedded.org

It appears the all external modules fail to compile if you try using the 5.10-rc1 or later kernel due to this commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980

Has anyone tried to compile the latest kernel or has a fix for yocto?

Quoted 8 lines

linux-yocto-dev is on v5.10-rc3, and is running without issues. That includes on-target and external module tests passing.

That being said, there may be something different in the kernel recipes, or there's an artifact that we need to get into the kernel staging directory for what you are building.

Is there a reproducer that you can send, so I can test against it ?

I'll have to look at linux-yocto-dev first then and see if I can reproduce it there tomorrow.  We don't use linux-yocto.

We have a multiconfig setup and devtool checkout our own linux kernel and set the STAGING_KERNEL_DIR to point to the checked out kernel (why STAGING_KERNEL_DIR needs to be set when we devtool checkout the kernel seems like it should automatically be done by devtool or something....). Next, merge the latest kernel to our tree and try to build: bitbake mc:stingray:cryptodev-module (or any external kernel module) and the compile fails as such:

ERROR: mc:stingray:cryptodev-module-1.11-r0 do_compile: oe_runmake failed
ERROR: mc:stingray:cryptodev-module-1.11-r0 do_compile: Execution of '/mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/temp/run.do_compile.13766' failed with exit code 1:
make -C /mnt/2ndHDD/yocto/nxs/poky/build/workspace/sources/brcm-linux M=/mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git ARCH=arm64 CROSS_COMPILE=aarch64-poky-linux- modules make[1]: Entering directory '/mnt/2ndHDD/yocto/nxs/poky/build/workspace/sources/brcm-linux'
make[2]: Entering directory '/mnt/2ndHDD/yocto/nxs/poky/build/tmp/work-shared/bcm958742k/kernel-build-artifacts'
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/ioctl.o
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/main.o
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/cryptlib.o
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/authenc.o
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/util.o
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/zc.o
  LD [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/cryptodev.o
  MODPOST /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/Module.symvers
make[4]: *** No rule to make target 'scripts/module.lds', needed by '/mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/cryptodev.ko'.  Stop. make[4]: *** Waiting for unfinished jobs....
  CC [M]  /mnt/2ndHDD/yocto/nxs/poky/build/tmp/work/bcm958742k-poky-linux/cryptodev-module/1.11-r0/git/cryptodev.mod.o /mnt/2ndHDD/yocto/nxs/poky/build/workspace/sources/brcm-linux/scripts/Makefile.modpost:117: recipe for target '__modpost' failed
make[3]: *** [__modpost] Error 2
/mnt/2ndHDD/yocto/nxs/poky/build/workspace/sources/brcm-linux/Makefile:1703: recipe for target 'modules' failed
make[2]: *** [modules] Error 2
make[2]: Leaving directory '/mnt/2ndHDD/yocto/nxs/poky/build/tmp/work-shared/bcm958742k/kernel-build-artifacts'
Makefile:185: recipe for target '__sub-make' failed
make[1]: *** [__sub-make] Error 2
make[1]: Leaving directory '/mnt/2ndHDD/yocto/nxs/poky/build/workspace/sources/brcm-linux'
Makefile:27: recipe for target 'build' failed
make: *** [build] Error 2
WARNING: exit code 1 from a shell command.

If I revert the change highlighted in the kernel everything builds:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980

Quoted 8 lines

Bruce

Quoted 2 lines
#3 lore raw
In reply to Scott Branden
Quoted 5 lines · Scott Branden via lists.openembedded.org

It appears the all external modules fail to compile if you try using the 5.10-rc1 or later kernel due to this commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980

Has anyone tried to compile the latest kernel or has a fix for yocto?

Can you check if this resolves the problem:

https://lists.openembedded.org/g/openembedded-core/message/144539

Thanks,

Anuj

#4 lore raw
Quoted 7 lines · Anuj Mittal
Quoted 4 lines · Scott Branden via lists.openembedded.org

It appears the all external modules fail to compile if you try using the 5.10-rc1 or later kernel due to this commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=596b0474d3d9b1242eab713f84d8873f9887d980

Quoted 5 lines
Quoted 1 line

Has anyone tried to compile the latest kernel or has a fix for yocto?

Can you check if this resolves the problem:

https://lists.openembedded.org/g/openembedded-core/message/144539

Yep, that's exactly what you need.

I haven't had my other updates merged yet, so mine is still pending.

Cheers,

Bruce

Quoted 7 lines

Thanks,

Anuj

Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II