[OE-core] [PATCH 1/7] linux-dtb.inc: fix detection of ending '.dts'

Stefan Christ s.christ at phytec.de
Mon Oct 19 09:03:01 UTC 2015


Hi,

On Mon, Oct 19, 2015 at 10:27:52AM +0200, Nicolas Dechesne wrote:
> On Mon, Oct 19, 2015 at 10:15 AM, Stefan Christ <s.christ at phytec.de> wrote:
> >
> > Device tree files ending with ".dts" are not recognized correctly
> > because of unnecessary front slashes.
> >
> > Signed-off-by: Stefan Christ <s.christ at phytec.de>
> > ---
> >  meta/recipes-kernel/linux/linux-dtb.inc | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/meta/recipes-kernel/linux/linux-dtb.inc b/meta/recipes-kernel/linux/linux-dtb.inc
> > index ee3a5e1..db2afb8 100644
> > --- a/meta/recipes-kernel/linux/linux-dtb.inc
> > +++ b/meta/recipes-kernel/linux/linux-dtb.inc
> > @@ -8,7 +8,7 @@ python __anonymous () {
> >  do_compile_append() {
> >         if test -n "${KERNEL_DEVICETREE}"; then
> >                 for DTB in ${KERNEL_DEVICETREE}; do
> > -                       if echo ${DTB} | grep -q '/dts/'; then
> > +                       if echo ${DTB} | grep -q 'dts'; then
> 
> 
> 
> My understanding is that the '/dts/' was here to catch 'boot/dts/' in
> order to detect the absolute path name, not the trailing '.dts'. In
> which case this patch might not be appropriate.

Hmm, the meaning of the code seems to be non obvious. I just looked at sed
replacement and concluded that it's about the file name ending.

Using the full path to the dtb file is not supported by the code anyway, e.g.

   DTB_PATH="${B}/arch/${ARCH}/boot/dts/${DTB}"

would be wrong.

So the correct solution would check both cases

   - full path or only filename and
   - ending is dts or dtb

Correct?

Mit freundlichen Grüßen / Kind regards,
	Stefan Christ




More information about the Openembedded-core mailing list