Clean up init_wrapper script 71/256671/4
authorHyotaek Shim <hyotaek.shim@samsung.com>
Fri, 9 Apr 2021 04:14:46 +0000 (13:14 +0900)
committerHyotaek Shim <hyotaek.shim@samsung.com>
Mon, 19 Apr 2021 12:28:47 +0000 (21:28 +0900)
Change-Id: I760a01622d5432f0bc7622fed4d35dded75f165e
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
scripts/init.wrapper

index cfdcd74724348bdfec194ee7f5c647dcf36ebb08..691cae952acb7479ade31a207a9639e44a1c89eb 100644 (file)
@@ -1,7 +1,6 @@
 #!/bin/sh
 PATH=/bin:/usr/bin:/sbin:/usr/sbin
 SYSTEM_MNT=/opt
-SYS_BLK_DIR=/sys/class/block
 MODULES_MNT=/usr/lib/modules
 
 mkdir -p /dev /sys /proc
@@ -51,8 +50,8 @@ if [ x$MODULES = "x" ]
 then
     echo "Warning : There is no modules partition."
 else
-    /sbin/resize2fs -f $MODULES
     /sbin/fsck -y $MODULES
+    /sbin/resize2fs -f $MODULES
     /bin/mount $MODULES $MODULES_MNT
 fi
 
@@ -61,7 +60,6 @@ then
     echo "Warning : There is no system-data partition."
 else
     /usr/bin/mount | grep "$DATAFS " > /dev/null
-
     if [ $? = "0" ]
     then
         /usr/bin/umount -l "$DATAFS"