[OE-core] [meta-oe][PATCH] kernel-devicetree: Corrected normalize_dtb

Martin Jansa martin.jansa at gmail.com
Wed Jul 4 16:13:19 UTC 2018


Confirmed.

I was seeing the same today when testing my rebased changes for
kernel*bbclasses.

On Wed, Jul 4, 2018 at 6:09 PM Khem Raj <raj.khem at gmail.com> wrote:

>
>
> On 7/2/18 8:03 AM, Paulo Neves wrote:
> > The normalize_dtb function was buggy because
> > it only converted from .dts suffix to .dtb
> > suffix if the user passed a full source path to
> > KERNEL_DEVICETREE containing the /dts/ path.
> > The problem is that if the user did that there
> > would be a warning.
> >
> > On the othet hand if user just set the variable
> > KERNEL_DEVICETREE="file.dts" the bbclass translation
> > to the respective .dtb target did not occur and
> > make would fail saying it has no rule to make target
> > file.dts
> >
> > This patch decouples the logic of having /dts/ in the
> > path from the target translation.
> >
>
> This breaks a case where relative paths are used e.g. for rpi
> kernel we use DTB=overlay/xxx.dtbo and DTB=xxx.dtb and so on
> with this change its going to strip leading directory name and
> break that assumption.
>
> See
>
> http://git.yoctoproject.org/cgit/cgit.cgi/meta-raspberrypi/tree/conf/machine/include/rpi-base.inc#n17
>
> > Signed-off-by: Paulo Neves <ptsneves at gmail.com>
> > ---
> >   meta/classes/kernel-devicetree.bbclass | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/meta/classes/kernel-devicetree.bbclass
> b/meta/classes/kernel-devicetree.bbclass
> > index 4f80cc62eb..9866d844ab 100644
> > --- a/meta/classes/kernel-devicetree.bbclass
> > +++ b/meta/classes/kernel-devicetree.bbclass
> > @@ -13,8 +13,8 @@ normalize_dtb () {
> >       DTB="$1"
> >       if echo ${DTB} | grep -q '/dts/'; then
> >               bbwarn "${DTB} contains the full path to the the dts file,
> but only the dtb name should be used."
> > -             DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'`
> >       fi
> > +     DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'`
> >       echo "${DTB}"
> >   }
> >
> >
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20180704/4216615d/attachment-0002.html>


More information about the Openembedded-core mailing list