From patchwork Fri Jan 31 13:08:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Ray X-Patchwork-Id: 240517 List-Id: U-Boot discussion From: ian.ray at ge.com (Ian Ray) Date: Fri, 31 Jan 2020 15:08:03 +0200 Subject: [U-Boot, 12/13] board: ge: bx50v3, mx53ppd: fix firstboot detection In-Reply-To: References: Message-ID: <674eaa67c4cf8668c75bede43779f5e749553e98.1580475104.git.ian.ray@ge.com> From: Robert Beckett Use `test' command to test for file existence instead of relying on the old functionality of the `ext2load' command (which now reports an error when attempting to load a zero length file). Signed-off-by: Robert Beckett Signed-off-by: Ian Ray --- include/configs/ge_bx50v3.h | 3 +-- include/configs/mx53ppd.h | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 98ef71d..7a0c63b 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -93,8 +93,7 @@ "if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \ "then setenv quiet; fi\0" \ "hasfirstboot=" \ - "ext2load ${dev} ${devnum}:${partnum} 0x7000A000 " \ - "/boot/bootcause/firstboot\0" \ + "test -e ${dev} ${devnum}:${partnum} /boot/bootcause/firstboot\0" \ "swappartitions=" \ "setexpr partnum 3 - ${partnum}\0" \ "failbootcmd=" \ diff --git a/include/configs/mx53ppd.h b/include/configs/mx53ppd.h index a4452b8..101abc4 100644 --- a/include/configs/mx53ppd.h +++ b/include/configs/mx53ppd.h @@ -72,8 +72,8 @@ "rootwait ${bootargs}\0" \ "doquiet=if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \ "then setenv quiet; fi\0" \ - "hasfirstboot=ext2load ${dev} ${devnum}:${partnum} 0x7000A000 " \ - "/boot/bootcause/firstboot\0" \ + "hasfirstboot=" \ + "test -e ${dev} ${devnum}:${partnum} /boot/bootcause/firstboot\0" \ "swappartitions=setexpr partnum 3 - ${partnum}\0" \ "failbootcmd=" \ "cls; " \