From dac5caa67c2f5bb9c2f1bb46104e3f8afc940873 Mon Sep 17 00:00:00 2001 From: Chris Novakovic Date: Tue, 11 Jul 2017 00:00:51 +0100 Subject: [PATCH] initramfs: write /dev/.flash_netboot if /flash is a remote filesystem The init script currently touches a file at /dev/.storage_netboot if /storage is a remote filesystem, so that scripts that run after the root filesystem has been switched can behave differently depending on whether /storage is mounted locally or remotely. Add similar functionality for /flash by touching /dev/.flash_netboot if it is a remote filesystem. --- packages/sysutils/busybox/scripts/init | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/sysutils/busybox/scripts/init b/packages/sysutils/busybox/scripts/init index 435b726b17..c8568cfa12 100755 --- a/packages/sysutils/busybox/scripts/init +++ b/packages/sysutils/busybox/scripts/init @@ -1095,6 +1095,11 @@ if [ "$UPDATE_DISABLED" = "yes" ] ; then echo "" > /sysroot/dev/.update_disabled fi + + if [ "$FLASH_NETBOOT" = "yes" ] ; then + echo "" > /sysroot/dev/.flash_netboot + fi + # swap can not be used over nfs.(see scripts/mount-swap) if [ "$STORAGE_NETBOOT" = "yes" ] ; then echo "" > /sysroot/dev/.storage_netboot