rpi: tizen-boot: check whether there is an init file in sbin directory
authorJaehoon Chung <jh80.chung@samsung.com>
Thu, 6 Jul 2017 02:13:20 +0000 (11:13 +0900)
committerJaehoon Chung <jh80.chung@samsung.com>
Tue, 17 Oct 2023 04:19:17 +0000 (13:19 +0900)
Check the "init" file in sbin directory.
If there is the "init" file, it should be ramdisk image.

Change-Id: Ic827f42c783668832f7d9201132fee0185d953c5
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
board/raspberrypi/rpi/tizen-boot.scr

index 5b7453e..daa0a44 100644 (file)
@@ -27,7 +27,7 @@ bootmode=ramdisk
 fi
 
 # boot from ram0 if there is sbin
-if test -e $bootdev $mmcrootdev:$ramdiskpart sbin; then;
+if test -e $bootdev $mmcrootdev:$ramdiskpart sbin/init; then;
 rootdev=ram0
 else
 rootdev=mmcblk${mmcrootdev}p${mmcrootpart}
@@ -51,7 +51,7 @@ if load $bootdev $mmcbootdev:$mmcbootpart $kernel_addr_r $kernel; then;
        echo ${bootmode} "boot";
        load $bootdev $mmcbootdev:$mmcbootpart $fdt_addr_r $fdtfile;
        load $bootdev $mmcbootdev:$mmcbootpart $kernel_addr_r $prefix$kernel;
-       if test -e mmc $mmcrootdev:$ramdiskpart sbin; then;
+       if test -e mmc $mmcrootdev:$ramdiskpart sbin/init; then;
                echo "Loading Ramdisk from partition"${ramdiskpart};
                mmc read $ramdisk_addr_r $ramdisk_start $ramdisk_size;
        fi