Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Dec 2019 18:00:06 +0000 (UTC)
From:      Emmanuel Vadot <manu@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r355809 - stable/12/usr.bin/dtc
Message-ID:  <201912161800.xBGI06Sn067692@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: manu
Date: Mon Dec 16 18:00:05 2019
New Revision: 355809
URL: https://svnweb.freebsd.org/changeset/base/355809

Log:
  MFC r354115:
  
  dtc: Allow multiple dts-v1 tag
  
  Some dts are including dtsi that also contain a /dts-v1/ tag at the
  top. GNU DTC doesn't seems to have a problem with that so fix our
  dtc to behave the same.
  
  Reviewed by:	kevans

Modified:
  stable/12/usr.bin/dtc/fdt.cc
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/usr.bin/dtc/fdt.cc
==============================================================================
--- stable/12/usr.bin/dtc/fdt.cc	Mon Dec 16 17:59:02 2019	(r355808)
+++ stable/12/usr.bin/dtc/fdt.cc	Mon Dec 16 18:00:05 2019	(r355809)
@@ -1563,11 +1563,11 @@ device_tree::parse_file(text_input_buffer &input,
 {
 	input.next_token();
 	// Read the header
-	if (input.consume("/dts-v1/;"))
+	while (input.consume("/dts-v1/;"))
 	{
 		read_header = true;
+		input.next_token();
 	}
-	input.next_token();
 	if (input.consume("/plugin/;"))
 	{
 		is_plugin = true;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201912161800.xBGI06Sn067692>