Hi, On Fri, Dec 20, 2024 at 05:22:50PM -0500, Bruce Ashfield wrote: > On Fri, Dec 20, 2024 at 8:31 AM Mikko Rapeli via lists.yoctoproject.org > <mikko.rapeli=linaro....@lists.yoctoproject.org> wrote: > > > Hi, > > > > On Fri, Dec 20, 2024 at 05:22:21AM -0800, Anton Antonov via > > lists.yoctoproject.org wrote: > > > On Fri, Dec 20, 2024 at 04:06 AM, Mikko Rapeli wrote: > > > > > > > > > > > I don't think this feature should be genericarm64 specific. I think it > > > > should be defined similar to x86 one: > > > > > > https://git.yoctoproject.org/yocto-kernel-cache/tree/features/intel-persistent-memory/intel-x86-64-pmem.cfg > > > > > > > > > > > > and added to genericarm64 machine (and any other arm64 machine when > > > > required) via MACHINE_FEATURES in the machine definition: > > > > > > https://github.com/yoctoproject/poky/blob/master/meta-yocto-bsp/conf/machine/genericarm64.conf#L11 > > > > Ok, sounds sensible. > > > > Can someone help me how to apply changes to kernel-meta git tree via > > > > patches in SRC_URI? > > > > This way I can test the real thing and enable this via > > MACHINE_FEATURES. > > > > > > AFAIR, when I tested my changes in yocto-kernel-cache I used the > > following approach: > > > 1. The local yocto-kernel-cache repo with my changes in "arm" branch in > > /path/to/yocto-kernel-cache > > > 2. In my local.conf I had: > > > > > > SRC_URI:pn-linux-yocto = " git:// > > git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH};protocol=https > > <http://git.yoctoproject.org/linux-yocto.git;name=machine;branch=$%7BKBRANCH%7D;protocol=https> > > ( git:// > > git.yoctoproject.org/linux-yocto.git;name=machine;branch=$%7BKBRANCH%7D;protocol=https > > ) \ > > git:///path/to/yocto-kernel-cache;type=kmeta;name=meta;branch=arm;destsuffix=${KMETA};protocol=file" > > SRCREV_meta:pn-linux-yocto = "${AUTOREV}" > > > > > > You can also create a inux-yocto_%.bbappend file in meta-yocto-bsp with > > the definitions above instead of using local.conf > > > > Yes this is the alternative. I was hoping to avoid this for testing > > simple patches. I will come back to this next year due to holidays. > > > > I have this in the kernel-yocto bbclass: > > » # was anyone trying to patch the kernel meta data ?, we > need to do > > > » » # this here, since the scc commands migrate the .cfg > fragments to the > > > » » # kernel source tree, where they'll be used later. > > > > » » check_git_config > > > > » » patches="${@" ".join(find_patches(d,'kernel-meta'))}" > > > > » > > So anything on the src_uri with a subdir of kernel-meta should be picked up > and detected as a patch to the meta-data. > > This is VERY lightly used, I'm not 100% sure that there aren't bugs lurking. > > Alternatively, I suggest just adding a kernel-meta directory into your layer > and adding it to the SRC_URI, see the patch from today tweaking > it to allow simpler processing of it. With a directory like that you can > extend/clobber most fragments from the core kernel-cache repository.
I figured out that both "subdir" and "patchdir" flags in SRC_URI patches are needed to apply a patch to kernel-meta. Without these the patch file is silently ignored. It is quite hard to debug this in the do_patch task implementation. Not many useful traces in logs etc. So this works: --- a/meta/recipes-kernel/linux/linux-yocto_6.12.bb +++ b/meta/recipes-kernel/linux/linux-yocto_6.12.bb @@ -43,6 +43,15 @@ KBRANCH:class-devupstream = "v6.12/base" SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH};protocol=https \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-6.12;destsuffix=${KMETA};protocol=https" +SRC_URI += "\ + file://changes_to_test.patch;subdir=kernel-meta;patchdir=kernel-meta \ +" + LIC_FILES_CHKSUM = "file://COPYING;md5=6bc538ed5bd9a7fc9398086aedcd7e46" LINUX_VERSION ?= "6.12.13" Cheers, -Mikko
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#14789): https://lists.yoctoproject.org/g/linux-yocto/message/14789 Mute This Topic: https://lists.yoctoproject.org/mt/111250321/21656 Group Owner: linux-yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-