[boot] remove no-data option as it will soon break
The fvm.sparse.blk will soon contain fvm.data.blk, as such, this option will
cease to work. There is no replacement - users are to migrate to using `fx
ota` as a workflow that preserves the data partition.
Bug: BLD-272 #comment
Change-Id: I3db22a25fcfabd21b72a1233093b226e2fa1e300
diff --git a/devshell/boot b/devshell/boot
index 87fe246..9b8e19b 100755
--- a/devshell/boot
+++ b/devshell/boot
@@ -5,7 +5,7 @@
### run bootserver in zedboot disk paver mode
-## usage: fx boot [--netboot] [--no-data] [--force-pave]
+## usage: fx boot [--netboot] [--force-pave]
## [--artifacts <dir>]
## [--sign-tool <path_to_sign_tool>]
## [--bootloader <path_to_prebuilt_bootloader>]
@@ -13,8 +13,6 @@
## <type> see "--help" for list (default: x64 for x64 / arm64 for arm64)
## --netboot Boot from ramdisk containing FVM
## --force-pave Force the target device to pave to persistent storage
-## --no-data Use FVM images without a /data partition (preserve existing
-## data)
## --artifacts a directory to load files to send to the target where the
## root of the directory base zircon.bin and its bootdata file
## and an images sub-directory has all the images to pave
@@ -45,7 +43,6 @@
}
netboot=false
-add_data=true
ip_targ=()
bootserver_extra=()
sign_tool=""
@@ -66,14 +63,6 @@
--force-pave)
force_pave=true
;;
- --no-data)
- echo >&2 "##"
- echo >&2 "## Note: if the target has no pre-existing data partition, then"
- echo >&2 "## none will be created. The resultant system will behave in a"
- echo >&2 "## kind of 'incognito' fashion, as /data will be backed by ram."
- echo >&2 "##"
- add_data=false
- ;;
--sign-tool)
shift
sign_tool="$1"
@@ -215,7 +204,7 @@
if $add_fvm; then
disks=("${disks[@]}" --fvm "${fuchsia_dir}/${IMAGE_FVM_SPARSE}")
- if $add_data; then
+ if [[ -s "${fuchsia_dir}/${IMAGE_DATA_FVM_RAW}" ]]; then
disks=("${disks[@]}" --fvm "${fuchsia_dir}/${IMAGE_DATA_FVM_RAW}")
fi
fi