mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-08-01 21:23:51 -09:00
fs/ext2: remove ext2 revision 0 support
Revision 0 is very old and misses a number of features. From man mkfs.ext2: Set the file system revision for the new file system. Note that 1.2 kernels only support revision 0 file systems. The default is to create revision 1 file systems. We are unlikely to have a lot of Linux 1.2.x users, so drop support for it. As revision 1 is the default, drop the -E revision argument to mkfs.ext2 for simplicity. Signed-off-by: Peter Korsgaard <peter@korsgaard.com> Signed-off-by: Julien Olivain <ju.o@free.fr>
This commit is contained in:
committed by
Julien Olivain
parent
a92b74c20c
commit
ba38576aa6
@@ -146,6 +146,13 @@ endif
|
|||||||
|
|
||||||
comment "Legacy options removed in 2025.02"
|
comment "Legacy options removed in 2025.02"
|
||||||
|
|
||||||
|
config BR2_TARGET_ROOTFS_EXT2_2r0
|
||||||
|
bool "ext2 rev0 support been removed"
|
||||||
|
select BR2_LEGACY
|
||||||
|
help
|
||||||
|
Support for ext2 revision 0 format has been removed and
|
||||||
|
revision 1 is now unconditionally used.
|
||||||
|
|
||||||
config BR2_GDB_VERSION_13
|
config BR2_GDB_VERSION_13
|
||||||
bool "gdb 13.x has been removed"
|
bool "gdb 13.x has been removed"
|
||||||
select BR2_LEGACY
|
select BR2_LEGACY
|
||||||
|
|||||||
@@ -13,10 +13,6 @@ choice
|
|||||||
bool "ext2/3/4 variant"
|
bool "ext2/3/4 variant"
|
||||||
default BR2_TARGET_ROOTFS_EXT2_2r1
|
default BR2_TARGET_ROOTFS_EXT2_2r1
|
||||||
|
|
||||||
config BR2_TARGET_ROOTFS_EXT2_2r0
|
|
||||||
bool "ext2 (rev0)"
|
|
||||||
select BR2_TARGET_ROOTFS_EXT2_2
|
|
||||||
|
|
||||||
config BR2_TARGET_ROOTFS_EXT2_2r1
|
config BR2_TARGET_ROOTFS_EXT2_2r1
|
||||||
bool "ext2 (rev1)"
|
bool "ext2 (rev1)"
|
||||||
select BR2_TARGET_ROOTFS_EXT2_2
|
select BR2_TARGET_ROOTFS_EXT2_2
|
||||||
@@ -35,12 +31,6 @@ config BR2_TARGET_ROOTFS_EXT2_GEN
|
|||||||
default 3 if BR2_TARGET_ROOTFS_EXT2_3
|
default 3 if BR2_TARGET_ROOTFS_EXT2_3
|
||||||
default 4 if BR2_TARGET_ROOTFS_EXT2_4
|
default 4 if BR2_TARGET_ROOTFS_EXT2_4
|
||||||
|
|
||||||
# All ext generations are revision 1, except ext2r0, which is revision 0
|
|
||||||
config BR2_TARGET_ROOTFS_EXT2_REV
|
|
||||||
int
|
|
||||||
default 0 if BR2_TARGET_ROOTFS_EXT2_2r0
|
|
||||||
default 1 if !BR2_TARGET_ROOTFS_EXT2_2r0
|
|
||||||
|
|
||||||
config BR2_TARGET_ROOTFS_EXT2_LABEL
|
config BR2_TARGET_ROOTFS_EXT2_LABEL
|
||||||
string "filesystem label"
|
string "filesystem label"
|
||||||
default "rootfs"
|
default "rootfs"
|
||||||
@@ -85,8 +75,7 @@ config BR2_TARGET_ROOTFS_EXT2_RESBLKS
|
|||||||
|
|
||||||
config BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS
|
config BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS
|
||||||
string "additional mke2fs options"
|
string "additional mke2fs options"
|
||||||
# Note: ext2 rev0 does not support filesystem options.
|
default "-O ^64bit"
|
||||||
default "-O ^64bit" if !BR2_TARGET_ROOTFS_EXT2_2r0
|
|
||||||
help
|
help
|
||||||
Specify a space-separated list of mke2fs options, including
|
Specify a space-separated list of mke2fs options, including
|
||||||
any ext2/3/4 filesystem features.
|
any ext2/3/4 filesystem features.
|
||||||
@@ -101,8 +90,7 @@ config BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS
|
|||||||
support. This default value has been chosen because U-Boot
|
support. This default value has been chosen because U-Boot
|
||||||
versions before 2017.02 don't support this filesystem
|
versions before 2017.02 don't support this filesystem
|
||||||
option: using it may make the filesystem unreadable by
|
option: using it may make the filesystem unreadable by
|
||||||
U-Boot. Note: this default does not apply to the old ext2
|
U-Boot.
|
||||||
(rev0) which does not support filesystem options.
|
|
||||||
|
|
||||||
choice
|
choice
|
||||||
prompt "Compression method"
|
prompt "Compression method"
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ ROOTFS_EXT2_LABEL = $(subst ",,$(BR2_TARGET_ROOTFS_EXT2_LABEL))
|
|||||||
|
|
||||||
ROOTFS_EXT2_OPTS = \
|
ROOTFS_EXT2_OPTS = \
|
||||||
-d $(TARGET_DIR) \
|
-d $(TARGET_DIR) \
|
||||||
-E revision=$(BR2_TARGET_ROOTFS_EXT2_REV) \
|
|
||||||
-N $(BR2_TARGET_ROOTFS_EXT2_INODES) \
|
-N $(BR2_TARGET_ROOTFS_EXT2_INODES) \
|
||||||
-m $(BR2_TARGET_ROOTFS_EXT2_RESBLKS) \
|
-m $(BR2_TARGET_ROOTFS_EXT2_RESBLKS) \
|
||||||
-L "$(ROOTFS_EXT2_LABEL)" \
|
-L "$(ROOTFS_EXT2_LABEL)" \
|
||||||
|
|||||||
@@ -38,26 +38,6 @@ def boot_img_and_check_fs_type(emulator, builddir, fs_type):
|
|||||||
|
|
||||||
|
|
||||||
class TestExt2(infra.basetest.BRTest):
|
class TestExt2(infra.basetest.BRTest):
|
||||||
config = infra.basetest.BASIC_TOOLCHAIN_CONFIG + \
|
|
||||||
"""
|
|
||||||
BR2_TARGET_ROOTFS_EXT2=y
|
|
||||||
BR2_TARGET_ROOTFS_EXT2_2r0=y
|
|
||||||
BR2_TARGET_ROOTFS_EXT2_LABEL="foobaz"
|
|
||||||
BR2_TARGET_ROOTFS_EXT2_SIZE="16384"
|
|
||||||
# BR2_TARGET_ROOTFS_TAR is not set
|
|
||||||
"""
|
|
||||||
|
|
||||||
def test_run(self):
|
|
||||||
out = dumpe2fs_run(self.builddir, "rootfs.ext2")
|
|
||||||
self.assertEqual(dumpe2fs_getprop(out, VOLNAME_PROP), "foobaz")
|
|
||||||
self.assertEqual(dumpe2fs_getprop(out, REVISION_PROP), "0 (original)")
|
|
||||||
|
|
||||||
exit_code = boot_img_and_check_fs_type(self.emulator,
|
|
||||||
self.builddir, "ext2")
|
|
||||||
self.assertEqual(exit_code, 0)
|
|
||||||
|
|
||||||
|
|
||||||
class TestExt2r1(infra.basetest.BRTest):
|
|
||||||
config = infra.basetest.BASIC_TOOLCHAIN_CONFIG + \
|
config = infra.basetest.BASIC_TOOLCHAIN_CONFIG + \
|
||||||
"""
|
"""
|
||||||
BR2_TARGET_ROOTFS_EXT2=y
|
BR2_TARGET_ROOTFS_EXT2=y
|
||||||
|
|||||||
Reference in New Issue
Block a user