summaryrefslogtreecommitdiff
path: root/util-linux/mkfs_ext2_test.sh
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2009-10-20 17:47:23 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2009-10-20 17:47:23 +0200
commitc708a6d000fb26d17773dfdf0bee96d433f18b08 (patch)
treeb08a3e247ee905736c5aaaec66c54c0a70699083 /util-linux/mkfs_ext2_test.sh
parent82d6433abe251d8d7a43417af392b638f868afe5 (diff)
downloadbusybox-w32-c708a6d000fb26d17773dfdf0bee96d433f18b08.tar.gz
busybox-w32-c708a6d000fb26d17773dfdf0bee96d433f18b08.tar.bz2
busybox-w32-c708a6d000fb26d17773dfdf0bee96d433f18b08.zip
mkfs_ext2: further work on small images
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux/mkfs_ext2_test.sh')
-rwxr-xr-xutil-linux/mkfs_ext2_test.sh41
1 files changed, 20 insertions, 21 deletions
diff --git a/util-linux/mkfs_ext2_test.sh b/util-linux/mkfs_ext2_test.sh
index 4bc5f1ea9..a636de561 100755
--- a/util-linux/mkfs_ext2_test.sh
+++ b/util-linux/mkfs_ext2_test.sh
@@ -45,31 +45,30 @@ test_mke2fs() {
45 45
46# -:bbox +:standard 46# -:bbox +:standard
47 47
48# kilobytes=60 is the minimal allowed size. 48# kilobytes=60 is the minimal allowed size
49#
50# kilobytes=8378 is the first value where we differ from std:
51# +warning: 185 blocks unused
52# Filesystem label=
53# OS type: Linux
54# Block size=1024 (log=0)
55# Fragment size=1024 (log=0)
56# -2096 inodes, 8378 blocks
57# +2096 inodes, 8193 blocks
58# 418 blocks reserved for the super user
59# First data block=1
60# -2 block groups
61# +1 block groups
62# 8192 blocks per group, 8192 fragments per group
63# -1048 inodes per group
64# -Superblock backups stored on blocks:
65# -8193
66# +2096 inodes per group
67#
68kilobytes=60 49kilobytes=60
69while true; do 50while true; do
70 test_mke2fs || exit 1 51 test_mke2fs || exit 1
71 : $((kilobytes++)) 52 : $((kilobytes++))
72 test $kilobytes = 300000 && break 53 test $kilobytes = 200 && break
54done
55
56# Transition from one block group to two
57# fails in [8378..8410] range
58kilobytes=$((8*1024 - 20))
59while true; do
60 test_mke2fs #|| exit 1
61 : $((kilobytes++))
62 test $kilobytes = $((8*1024 + 300)) && break
63done
64
65# Transition from two block groups to three
66# works
67kilobytes=$((16*1024 - 40))
68while true; do
69 test_mke2fs || exit 1
70 : $((kilobytes++))
71 test $kilobytes = $((16*1024 + 500)) && break
73done 72done
74exit 73exit
75 74