From 8955c6aa5b1ca96ef53bc6fb8b904cd4f6a2d2ca Mon Sep 17 00:00:00 2001 From: Alexandru Avadanii Date: Wed, 26 May 2021 16:21:11 +0200 Subject: linux-intel: Allow BSPs to add patches (w/o AUFS) - allow BSP and scc files included in the BSP to add kernel source patches ("features"), not only kernel configuration fragments; - aufs patches in [1] are not yet rebased on top of [2], so until that happens upstream (aufs has been rebased and reworked on the master branch of yocto-kernel-cache for kernel 5.11) just remove the patches (we can't do that by patching kernel-meta with a patch file, as support is also broken upstream; handle it via a prepend); [1] http://git.yoctoproject.org/cgit.cgi/yocto-kernel-cache/log/\ features/aufs?h=yocto-5.10 [2] https://github.com/intel/linux-intel-lts/commit/26dc6581 Change-Id: I60b03451b3a812e21dd0a2d313e59ba19b249225 Signed-off-by: Alexandru Avadanii --- recipes-kernel/linux/linux-intel.inc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/recipes-kernel/linux/linux-intel.inc b/recipes-kernel/linux/linux-intel.inc index 366d57d..dbc9808 100644 --- a/recipes-kernel/linux/linux-intel.inc +++ b/recipes-kernel/linux/linux-intel.inc @@ -11,6 +11,20 @@ SRCREV_metaenea = "52d45bac8f69340d4677a9271a0f967fc087c44a" KENEABRANCH = "intel-5.10" SRC_URI_append = " git://git@git.enea.com/linux/enea-kernel-cache.git;protocol=ssh;type=kmeta;name=metaenea;branch=${KENEABRANCH};destsuffix=enea-kernel-meta" +# Upstream BSPs include aufs support (by patching the kernel source + enabling it in kernel config). +# However, our current kernel version contains a backported commit that conflicts with aufs patches. +# Until aufs patches are rebased in yocto-kernel-cache, disable aufs kernel source patching, since +# we don't enable it via kernel config anyway. +do_kernel_metadata_prepend() { + ## ENEA_start ## + # kernel-meta patching via patch files added to SRC_URI is currently broken, handle it here + sed -i -E 's/^(include features.aufs.*)$/# \1/g' ${WORKDIR}/kernel-meta/ktypes/standard/standard.scc + ## ENEA_end ## +} + +# Allow BSPs to supply patches without explicitly adding the scc files to SRC_URI/KERNEL_FEATURES +KMETA_EXTERNAL_BSPS = "t" + # KERNEL CONFIG DEFAULT CHECK LEVELS: # 0: no reporting # 1: report options that are specified, but not in the final config -- cgit v1.2.3-54-g00ecf