From 81aa56955a3d0b656bf1da27499cbbefb1ee4d59 Mon Sep 17 00:00:00 2001 From: longpanda Date: Sun, 20 Jun 2021 21:44:37 +0800 Subject: [PATCH] optimization for boot openwrt --- IMG/cpio/ventoy/loop/openwrt/ventoy-disk.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/IMG/cpio/ventoy/loop/openwrt/ventoy-disk.sh b/IMG/cpio/ventoy/loop/openwrt/ventoy-disk.sh index e1ef7e6e..0345da61 100644 --- a/IMG/cpio/ventoy/loop/openwrt/ventoy-disk.sh +++ b/IMG/cpio/ventoy/loop/openwrt/ventoy-disk.sh @@ -27,9 +27,9 @@ vtlog "####### $0 $* ########" VTPATH_OLD=$PATH; PATH=$BUSYBOX_PATH:$VTOY_PATH/tool:$PATH -for i in $(ls /sys/block/); do +for i in $(ls /sys/class/block/); do if ! [ -e /dev/$i ]; then - blkdev_num=$(sed 's/:/ /g' /sys/block/$i/dev) + blkdev_num=$(sed 's/:/ /g' /sys/class/block/$i/dev) vtlog "mknod -m 0666 /dev/$i b $blkdev_num" mknod -m 0666 /dev/$i b $blkdev_num fi