<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/meta/classes/kernel-devicetree.bbclass, branch 4.1_M2</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=4.1_M2</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=4.1_M2'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2021-12-22T23:11:45+00:00</updated>
<entry>
<title>classes/kernel*: add variables to allow changing artifact extension</title>
<updated>2021-12-22T23:11:45+00:00</updated>
<author>
<name>Paul Eggleton</name>
<email>paul.eggleton@microsoft.com</email>
</author>
<published>2021-12-20T21:58:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=65e8df66d9579b609791deb74d8e1b9ec17c1115'/>
<id>urn:sha1:65e8df66d9579b609791deb74d8e1b9ec17c1115</id>
<content type='text'>
Allow .bin suffix to be removed (or changed) in the various artifact
filenames. Removing this extension is useful when trying to remove
symlinks and present only unversioned image files (especially for the
FIT image).

(From OE-Core rev: cbecc3cf06eb7359fedf3c6af281cc72178cad18)

Signed-off-by: Paul Eggleton &lt;paul.eggleton@microsoft.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>classes/kernel*: allow disabling symlink creation</title>
<updated>2021-12-22T23:11:45+00:00</updated>
<author>
<name>Paul Eggleton</name>
<email>paul.eggleton@microsoft.com</email>
</author>
<published>2021-12-20T21:58:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=a2eb528b63b0c53daab31308a6afdcb605ac5f40'/>
<id>urn:sha1:a2eb528b63b0c53daab31308a6afdcb605ac5f40</id>
<content type='text'>
Allow setting any of the *_LINK_NAME variables to empty string in order
to disable creating symlinks for kernel artifacts, as you can already
for filesystem images with IMAGE_LINK_NAME. Additionally, for the image
type named symlinks, add a KERNEL_IMAGETYPE_SYMLINK boolean variable
which you can set to 0 to disable those symlinks as well.

(From OE-Core rev: d7341f1f22c32ff6cc95d7127f26f87d7fc9c6bd)

Signed-off-by: Paul Eggleton &lt;paul.eggleton@microsoft.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>Convert to new override syntax</title>
<updated>2021-08-02T14:44:10+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-07-28T22:28:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=bb6ddc3691ab04162ec5fd69a2d5e7876713fd15'/>
<id>urn:sha1:bb6ddc3691ab04162ec5fd69a2d5e7876713fd15</id>
<content type='text'>
This is the result of automated script conversion:

scripts/contrib/convert-overrides.py &lt;oe-core directory&gt;

converting the metadata to use ":" as the override character instead of "_".

(From OE-Core rev: 42344347be29f0997cc2f7636d9603b1fe1875ae)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree: Fix interaction when packaging disabled</title>
<updated>2021-06-27T21:51:05+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-06-26T19:22:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=1d1afe6a2ba96b4a4b6322f45957debf0b0bb074'/>
<id>urn:sha1:1d1afe6a2ba96b4a4b6322f45957debf0b0bb074</id>
<content type='text'>
When packaging is disabled using the nopackages class, ensure we don't
add to PACKAGES. This fixes builds where we have an unpackaged kernel
alongside a packaged kernel.

(From OE-Core rev: d6b114cf5a9b22688c0b59a3afc46a07450d87b5)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree: Introduce KERNEL_DTC_FLAGS to pass dtc flags</title>
<updated>2021-01-12T17:44:17+00:00</updated>
<author>
<name>Ovidiu Panait</name>
<email>ovidiu.panait@windriver.com</email>
</author>
<published>2020-12-23T13:08:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=ff036cbb77124867a6c6f97ca206b4fd3ee00c70'/>
<id>urn:sha1:ff036cbb77124867a6c6f97ca206b4fd3ee00c70</id>
<content type='text'>
Currently DTC_FLAGS kernel makefile parameter can be specified directly on the
command line by adding it to KERNEL_EXTRA_ARGS. However, this prevents
scripts/Makefile.lib logic from appending flags that silence dtc warnings (all
assignments done from within a makefile, to a variable specified on the command
line, are ignored).

Because of this, the do_compile log is cluttered with dtc warnings that should
only be printed when compiling with W="123":
...
/soc: node has a reg or ranges property, but no unit name
/soc/gpu: missing or empty reg/ranges property
/soc/firmware/gpio: missing or empty reg/ranges property
...

To fix this, introduce the dedicated KERNEL_DTC_FLAGS variable to hold
dtc flags and export DTC_FLAGS in the environment before generating the dtbs
(make allows "+=" operations on variables that come from the environment, so
the warnings are silenced properly).

(From OE-Core rev: 063b5de86624a42b0aa784db6dddc7552a6dee7f)

Signed-off-by: Ovidiu Panait &lt;ovidiu.panait@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree: Fix intermittent build failures caused by DTB builds</title>
<updated>2020-08-06T14:12:39+00:00</updated>
<author>
<name>Tyler Hicks</name>
<email>tyhicks@linux.microsoft.com</email>
</author>
<published>2020-08-05T16:56:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b148043e0e2b10fc300c806b596d70397071b286'/>
<id>urn:sha1:b148043e0e2b10fc300c806b596d70397071b286</id>
<content type='text'>
Fix a build-time race condition that resulted in intermittent build
failures in the do_assemble_fitimage task. The race condition involved
the do_assemble_fitimage task reading the vmlinux file while the
do_compile_kernelmodules task was re-writing the vmlinux file.

This can be seen with an aarch64 image build that uses a 5.4 based
kernel and sets KERNEL_DEVICETREE. The problem is that the do_compile
snippet that the kernel-devicetree class appends did not specify the
full kernel build environment when building the DTB(s) from the kernel
tree. This resulted in CONFIG_CC_CAN_LINK=y being removed from the
kernel config file just before the do_compile task completed. The
CONFIG_CC_CAN_LINK=y line was then re-inserted into the kernel config
file as part of the do_compile_kernelmodules task.

In some cases, this resulted in the do_compile_kernelmodules task to
re-link vmlinux which sometimes occured at the same time that the
do_assemble_fitimage task was attempting to use vmlinux. The
do_assemble_fitimage task would fail with the following error message:

 aarch64-poky-linux-objcopy:vmlinux: file format not recognized

We can use the pine-a64-lts machine, from the meta-pine64 layer, to show
that the kernel config file was changed between do_compile and
do_compile_kernelmodules:

 $ C=tmp/work/pine_a64_lts-poky-linux/linux-pine64/5.7+gitAUTOINC+ae03bade3b-r0/linux-pine_a64_lts-standard-build/.config
 $ bitbake -c do_kernel_configcheck virtual/kernel
 ...
 $ md5sum $C; grep CC_CAN_LINK $C
 32b133cf8a749a91f698a7ca8616c84f  ...
 CONFIG_CC_CAN_LINK=y

 $ bitbake -c do_compile virtual/kernel
 ...
 $ md5sum $C; grep CC_CAN_LINK $C
 2fd2ec2a66eecc329dcb5afaf005eada  ...

 $ bitbake -c do_compile_kernelmodules virtual/kernel
 ...
 $ md5sum $C; grep CC_CAN_LINK $C
 32b133cf8a749a91f698a7ca8616c84f  ...
 CONFIG_CC_CAN_LINK=y

With this change, the do_compile snippet appended by the
kernel-devicetree class does not modify the kernel config. The kernel
config is unchanged across the do_compile and do_compile_kernelmodules
tasks and do_compile_kernelmodules will not attempt to re-link vmlinux.

(From OE-Core rev: 74619de0277471f446bf7a719f4c445359c823f6)

Signed-off-by: Tyler Hicks &lt;tyhicks@linux.microsoft.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree: Cope with non-standard kernel deploy subdirectory</title>
<updated>2019-10-23T15:30:36+00:00</updated>
<author>
<name>Mike Crowe</name>
<email>mac@mcrowe.com</email>
</author>
<published>2019-10-21T14:38:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=dcf52753abcf494f70323140a5d276228e260c91'/>
<id>urn:sha1:dcf52753abcf494f70323140a5d276228e260c91</id>
<content type='text'>
kernel.bbclass installs non-standard kernels (where
KERNEL_PACKAGE_NAME is not "kernel") in a subdirectory of ${DEPLOYDIR}.
To achieve this kernel_do_deploy sets the deployDir shell variable to
${DEPLOYDIR} for the standard kernel or
${DEPLOYDIR}/${KERNEL_DEPLOYSUBDIR} for non-standard kernels.

kernel-devicetree.bbclass's do_deploy_append ought to do the same
and can do so by using the same shell variable.

(From OE-Core rev: db5752911fe085337b9d3d4af85f89a0c664388e)

Signed-off-by: Mike Crowe &lt;mac@mcrowe.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree.bbclass: add missing backslash</title>
<updated>2019-10-08T10:22:24+00:00</updated>
<author>
<name>Martin Jansa</name>
<email>martin.jansa@gmail.com</email>
</author>
<published>2019-09-11T15:18:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=ec6c982949958ee9e461fcd2db9f09c36e68dd5f'/>
<id>urn:sha1:ec6c982949958ee9e461fcd2db9f09c36e68dd5f</id>
<content type='text'>
* in oe-core commit 1860d9d3c62e2e94cd68a809385873ffd8270b6d I've accidentally
  removed the backshash here

Reported-By: "Hilsdorf, Jan (LAWO)" &lt;Jan.Hilsdorf@lawo.com&gt;
(From OE-Core rev: 44f0047c0268f3e9f9fdf78f93bdad9bfe491174)

Signed-off-by: Martin Jansa &lt;Martin.Jansa@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel*.bbclass: rename *_SYMLINK_NAME variables to *_LINK_NAME and *_BASE_NAME to *_NAME</title>
<updated>2018-08-21T13:49:42+00:00</updated>
<author>
<name>Martin Jansa</name>
<email>martin.jansa@gmail.com</email>
</author>
<published>2018-08-19T22:16:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=f09947586c5c2c05368651838fea970808ab161d'/>
<id>urn:sha1:f09947586c5c2c05368651838fea970808ab161d</id>
<content type='text'>
* for consistency with IMAGE_NAME and IMAGE_LINK_NAME
  and to avoid confusion with IMAGE_BASENAME (which is the
  actual name of the artifact, e.g. PN while KERNEL_IMAGE_BASE_NAME
  was only the version suffix)

(From OE-Core rev: f952c8e08b4798aa0f8bf764cfd70bda0eae9b8b)

Signed-off-by: Martin Jansa &lt;Martin.Jansa@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>kernel-devicetree.bbclass: Fix and simplify instalation of DTB files</title>
<updated>2018-07-10T16:32:59+00:00</updated>
<author>
<name>Martin Jansa</name>
<email>martin.jansa@gmail.com</email>
</author>
<published>2018-07-09T15:04:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=c5b70d7155a76b727400db225c446d1b2f7072a6'/>
<id>urn:sha1:c5b70d7155a76b727400db225c446d1b2f7072a6</id>
<content type='text'>
* add 2 new variables:
  KERNEL_DTB_BASE_NAME
  KERNEL_DTB_SYMLINK_NAME
  instead of reusing KERNEL_IMAGE_SYMLINK_NAME and than expecting that
  default value ${MACHINE} was being used in e.g.:
  DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`

* install normal DTB files only once even if there is multiple entries
  in KERNEL_IMAGETYPE_FOR_MAKE and don't prefix them with the type of
  the kernel image, use the KERNEL_IMAGETYPE_FOR_MAKE as a prefix only
  when installing them bundled with kernel or initramfs image.

* deploy the files from ${D}/${KERNEL_IMAGEDEST}/ instead of kernel
  build directory, so that we don't need to call
  DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"`
  again in do_deploy

* create all links in do_deploy task, because default KERNEL_DTB_BASE_NAME
  like KERNEL_IMAGE_BASE_NAME contains PKGR and PKGR is different in
  do_install and do_deploy, because kernel.bbclass calls
  meta/classes/kernel.bbclass:do_install[prefuncs] += "package_get_auto_pr"
  meta/classes/kernel.bbclass:do_deploy[prefuncs] += "package_get_auto_pr"

* the filenames are a bit different, but with separate variable it
  should be easier for other bbclasses which use these DTB files to
  find them correctly, just use either the cannonical name
  $dtb_base_name.$dtb_ext or $dtb_base_name-${KERNEL_DTB_SYMLINK_NAME}.$dtb_ext
  because PKGR (and other PKG* variables) might be different in your
  task and kernel.do_deploy task.

* fix DTB files being deployed with incorrect filenames when
  KERNEL_IMAGE_SYMLINK_NAME isn't set to ${MACHINE}, e.g. instead of
  the default:
-rw-r--r-- 2 bitbake bitbake 1.4K Nov 20 07:41 deploy/images/raspberrypi3-64/Image-1-4.9.59+git0+e7976b2aff-r0.2-lirc-rpi-20171120043031.dtbo
lrwxrwxrwx 2 bitbake bitbake   64 Nov 20 07:41 deploy/images/raspberrypi3-64/Image-lirc-rpi.dtbo -&gt; Image-1-4.9.59+git0+e7976b2aff-r0.2-lirc-rpi-20171120043031.dtbo
lrwxrwxrwx 2 bitbake bitbake   64 Nov 20 07:41 deploy/images/raspberrypi3-64/lirc-rpi.dtbo -&gt; Image-1-4.9.59+git0+e7976b2aff-r0.2-lirc-rpi-20171120043031.dtbo
  I was getting:
-rw-r--r-- 2 bitbake bitbake 1348 Nov 20 10:28 deploy/images/raspberrypi3-64/Image-linux-raspberrypi-lirc-rpi.dtbo
lrwxrwxrwx 2 bitbake bitbake   37 Nov 20 10:28 deploy/images/raspberrypi3-64/Image-linux-raspberrypi-lirc-rpi-master-20171120102653.dtbo -&gt; Image-linux-raspberrypi-lirc-rpi.dtbo
lrwxrwxrwx 2 bitbake bitbake   37 Nov 20 10:28 deploy/images/raspberrypi3-64/lirc-rpi.dtbo -&gt; Image-linux-raspberrypi-lirc-rpi.dtbo
  and e.g. sdcard_image-rpi.bbclass from meta-raspberrypi:
  https://github.com/agherzan/meta-raspberrypi/blob/37e4e18f4a745ce8dc11f7e40a29da0859ff13c6/classes/sdcard_image-rpi.bbclass
  was failing in:
  mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${DTB_BASE_NAME}.dtb ::${DTB_BASE_NAME}.dtb
  because ${KERNEL_IMAGETYPE}-${DTB_BASE_NAME}.dtb doesn't exist in my
  build, due to
  DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
  not replacing whole "${KERNEL_IMAGE_SYMLINK_NAME}" (read ${MACHINE})
  with just ${DTB_BASE_NAME}

* with this change applied the deploy dir looks like this:
-rw-r--r-- 2 bitbake bitbake 1.4K Nov 20 15:49 deploy/images/raspberrypi3-64/lirc-rpi-1-4.9.59+git0+e7976b2aff-r0.8-raspberrypi3-64-20171120154716.dtbo
lrwxrwxrwx 2 bitbake bitbake   74 Nov 20 15:49 deploy/images/raspberrypi3-64/lirc-rpi.dtbo -&gt; lirc-rpi-1-4.9.59+git0+e7976b2aff-r0.8-raspberrypi3-64-20171120154716.dtbo
lrwxrwxrwx 2 bitbake bitbake   74 Nov 20 15:49 deploy/images/raspberrypi3-64/lirc-rpi-raspberrypi3-64.dtbo -&gt; lirc-rpi-1-4.9.59+git0+e7976b2aff-r0.8-raspberrypi3-64-20171120154716.dtbo
  and works correctly even with DISTRO using different naming scheme

* the sdcard_image-rpi.bbclass still needs to be modified, I've provided
  updated version here:
  https://github.com/agherzan/meta-raspberrypi/pull/159
* mpc8315e-rdb.conf MACHINE in meta-yocto-bsp also needs small fix:
  https://lists.yoctoproject.org/pipermail/poky/2018-July/011436.html

(From OE-Core rev: 1860d9d3c62e2e94cd68a809385873ffd8270b6d)

Signed-off-by: Martin Jansa &lt;Martin.Jansa@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
