From: sbabic at denx.de Date: Mon, 10 Jun 2019 09:40:55 +0000 (UTC) Subject: [U-Boot] [PATCH] ARM: imx6logic: Stop overwriting fdt_file if In-Reply-To: <20190313154922.11994-1-aford173@gmail.com> Message-ID: <20190610094151.37BACC21FB1@lists.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de > The board file uses the processor type to determine what dtb file > is set. Unfortunately, if the user wants to manually set this, > it get gets overwritten upon boot. This patch adds a check to > see if the value is already set and only changes it if the value > is empty. > Signed-off-by: Adam Ford > diff --git a/board/logicpd/imx6/imx6logic.c b/board/logicpd/imx6/imx6logic.c > index b17a3b1d39..53e609e15c 100644 > --- a/board/logicpd/imx6/imx6logic.c > +++ b/board/logicpd/imx6/imx6logic.c > @@ -152,7 +152,8 @@ int board_late_init(void) > > if (is_mx6dq()) { > env_set("board_rev", "MX6DQ"); > - env_set("fdt_file", "imx6q-logicpd.dtb"); > + if (!env_get("fdt_file")) > + env_set("fdt_file", "imx6q-logicpd.dtb"); > } > > return 0; Applied to u-boot-imx, master, thanks ! Best regards, Stefano Babic -- ===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================