aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJose Luis Duran <jlduran@FreeBSD.org>2026-05-27 00:23:05 +0000
committerJose Luis Duran <jlduran@FreeBSD.org>2026-05-27 00:23:05 +0000
commitca2d4026c3f2bb8eeab888cf50f2c2e3914ab3e5 (patch)
tree44159ae128b6c896e54ce239348fe95f12a33b57
parent87150a2ed140d5a3c1272ce9cfe815f19282840b (diff)
nanobsd: Fix code image size formatting
mkimg(8) parses sizes using expand_number(3). It is an error to use "b" as a suffix. This is the result of a confusion with makefs(8), which uses NetBSD's strsuftoll(3). Reviewed by: imp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D57224
-rw-r--r--tools/tools/nanobsd/legacy.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/tools/nanobsd/legacy.sh b/tools/tools/nanobsd/legacy.sh
index 52d60b4fda8c..ed4bd493c8d7 100644
--- a/tools/tools/nanobsd/legacy.sh
+++ b/tools/tools/nanobsd/legacy.sh
@@ -326,7 +326,7 @@ _create_diskimage() {
altroot="-p freebsd:=${NANO_OBJ}/_.altroot.image:+$(( NANO_SECTS * 512 ))"
rm -f "${NANO_OBJ}/_.altroot.part"
else
- altroot="-p freebsd::${CODE_SIZE}b:+$(( NANO_SECTS * 512 ))"
+ altroot="-p freebsd::$(( CODE_SIZE * 512 )):+$(( NANO_SECTS * 512 ))"
fi
else
altroot="-p-"