[OE-core] Race condition when building external kernel modules

Anders Darander anders at chargestorm.se
Fri Sep 5 06:17:38 UTC 2014


Hi,

* Denys Dmytriyenko <denis at denix.org> [140905 01:09]:
> This report is exactly from 3 years ago. Has this ever been resolved or looked 
> at? We have started seeing this a lot lately in our own distro based on Daisy 
> with 3.14 kernel when building with 12-24 threads. But it might not be release 
> specific or even OE specifig...

Yes, our usecase was solved by by commit 8681b82e8b466929205edde7ba479f3ac1a6143e,
"module.bbclass: add lock to prevent error bulding ext modules". That
seems to still be in modules.bbclass, thus the do_make_scripts task
ought to be protected.

> All the same symptoms as below - external modules break when building/using 
> scripts from the kernel tree ran by do_make_scripts function. Usually the 
> failure is due to a race in or around fixdep: error opening depfile, but 
> sometimes it's in scripts/dtc or scripts/mod when it can't move a temp file 
> from a build. Looks like kernel creates .tmp_<name>.o files for use with ksyms 
> utils as well as .<name>.o.d files for fixdep and those are usually the files 
> that are not available at the right moment due to some race...

Do you get the issue also when building just one external module? I'd
guess not...

Can you verify that it's in the do_make_scripts function the breakage
occurs, or is it in the do_compile step?

Cheers,
Anders

-- 
Anders Darander
ChargeStorm AB		Tel: +46 702 44 84 36
Drottninggatan 20	Email: anders at chargestorm.se
602 24 Norrköping	Web: www.chargestorm.se



More information about the Openembedded-core mailing list