configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as metadata_csum and dir_index because there is incompatibility with these options.
--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)
configs/stm32mp157c_dk2_defconfig +1 -0
@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index" # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
Signature · 1 line
2.23.0
PATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
Since we know the proper solution, remove that faulty patch.
--- ...-fix-checking-the-presence-of-an-env.patch | 37 ------------------- configs/stm32mp157c_dk2_defconfig | 1 - 2 files changed, 38 deletions(-) delete mode 100644 board/stmicroelectronics/stm32mp157c-dk2/patches/uboot/0001-stm32mp1-configs-fix-checking-the-presence-of-an-env.patch
board/stmicroelectronics/stm32mp157c-dk2/patches/uboot/0001-stm32mp1-configs-fix-checking-the-presence-of-an-env.patch deleted +0 -37
@@ -1,37 +0,0 @@ -From a7204e5ae1e5f87ad449c7425cf7614205e60734 Mon Sep 17 00:00:00 2001 -From: Bartosz Bilas <[email protected]> -Date: Sun, 27 Oct 2019 09:01:12 +0100 -Subject: [PATCH] stm32mp1: configs: fix checking the presence of an - environment - -Execute env check command within extra env settings section instead of -bootcmd whereby we are able to mount rootfs partition from sd card properly. - -Signed-off-by: Bartosz Bilas <[email protected]> ---- - include/configs/stm32mp1.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/include/configs/stm32mp1.h b/include/configs/stm32mp1.h -index 988992b336..cadc0358fd 100644 ---- a/include/configs/stm32mp1.h -+++ b/include/configs/stm32mp1.h -@@ -115,7 +115,6 @@ - "if test ${boot_device} = serial || test ${boot_device} = usb;" \ - "then stm32prog ${boot_device} ${boot_instance}; " \ - "else " \ -- "run env_check;" \ - "if test ${boot_device} = mmc;" \ - "then env set boot_targets \"mmc${boot_instance}\"; fi;" \ - "if test ${boot_device} = nand;" \ -@@ -160,6 +159,7 @@ - "initrd_high=0xffffffff\0" \ - "altbootcmd=run bootcmd\0" \ - "env_default=1\0" \ -+ "run env_check;" \ - "env_check=if test $env_default -eq 1;"\ - " then env set env_default 0;env save;fi\0" \ - STM32MP_BOOTCMD \ --- -2.23.0 -
configs/stm32mp157c_dk2_defconfig +0 -1
@@ -1,7 +1,6 @@ BR2_arm=y BR2_cortex_a7=y BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_5_3=y -BR2_GLOBAL_PATCH_DIR="board/stmicroelectronics/stm32mp157c-dk2/patches" BR2_ROOTFS_OVERLAY="board/stmicroelectronics/stm32mp157c-dk2/overlay/" BR2_ROOTFS_POST_IMAGE_SCRIPT="support/scripts/genimage.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/stmicroelectronics/stm32mp157c-dk2/genimage.cfg"
Signature · 1 line
2.23.0
PATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
Quoted 3 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Bartosz" == Bartosz Bilas <[email protected]> writes:
Since we know the proper solution, remove that faulty patch.
Ehh, can you be a bit more specific? Do you mean that the change of ext4fs parameters fix the issue that this is trying to work around?
Signature · 1 line
Bye, Peter Korsgaard
PATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
Hello Peter,
Quoted 5 lines · Peter Korsgaard
Quoted 2 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Bartosz" == Bartosz Bilas <[email protected]> writes:
Since we know the proper solution, remove that faulty patch.
Ehh, can you be a bit more specific? Do you mean that the change of ext4fs parameters fix the issue that this is trying to work around?
I'm sorry for that - it was so obvious for me during patches generation. Yes, I do - disabling new features that are enabled by default in new mkfs version fix the issue with mounting rootfs partition.
Best
Bartek
Thomas Petazzoni
AppliedPATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
In reply to Bartosz BilasQuoted 8 lines · On Sun, 3 Nov 2019 12:50:17 +0100 Bartosz Bilas <[email protected]>…
Since we know the proper solution, remove that faulty patch.
Signed-off-by Bartosz Bilas <[email protected]>--- ...-fix-checking-the-presence-of-an-env.patch | 37 ------------------- configs/stm32mp157c_dk2_defconfig | 1 - 2 files changed, 38 deletions(-) delete mode 100644 board/stmicroelectronics/stm32mp157c-dk2/patches/uboot/0001-stm32mp1-configs-fix-checking-the-presence-of-an-env.patch
Applied to master after improving the commit log. Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
Hi Bartosz,
Is possible to bump linux kernel to version 5.4.7? The 5.3.x series has been EOL, the "longterm maintenance" series will be acceptable.
Thanks.
Quoted 15 lines · On Thu, Jan 2, 2020, 00:21 Thomas Petazzoni <[email protected]>…
Quoted 8 lines · On Sun, 3 Nov 2019 12:50:17 +0100 Bartosz Bilas <[email protected]>…
Since we know the proper solution, remove that faulty patch.
Signed-off-by Bartosz Bilas <[email protected]>--- ...-fix-checking-the-presence-of-an-env.patch | 37 ------------------- configs/stm32mp157c_dk2_defconfig | 1 - 2 files changed, 38 deletions(-) delete mode 100644
board/stmicroelectronics/stm32mp157c-dk2/patches/uboot/0001-stm32mp1-configs-fix-checking-the-presence-of-an-env.patchApplied to master after improving the commit log. Thanks!
Quoted 10 lines
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20200103/a2e2ff23/attachment.html>
PATCH 2/2 board/stm32mp157c-dk2: remove unnecessary workaround
Hello Scott,
sure. I'll check if the board boots with the newer kernel and if so I'll send a patch at the weekend.
Best
Bartek
Quoted 39 lines · Scott Fan
Hi Bartosz,
Is possible to bump linux kernel to version 5.4.7? The 5.3.x series has been EOL, ?the "longterm maintenance" series will be acceptable.
Thanks.
On Thu, Jan 2, 2020, 00:21 Thomas Petazzoni <thomas.petazzoni at bootlin.com <mailto:[email protected]>> wrote:
On Sun,? 3 Nov 2019 12:50:17 +0100 Bartosz Bilas <[email protected] <mailto:[email protected]>> wrote: > Since we know the proper solution, remove that faulty patch. > > Signed-off-by: Bartosz Bilas <[email protected] <mailto:[email protected]>> > --- >? ...-fix-checking-the-presence-of-an-env.patch | 37 ------------------- >? configs/stm32mp157c_dk2_defconfig? ? ? ? ? ? ?|? 1 - >? 2 files changed, 38 deletions(-) >? delete mode 100644 board/stmicroelectronics/stm32mp157c-dk2/patches/uboot/0001-stm32mp1-configs-fix-checking-the-presence-of-an-env.patch Applied to master after improving the commit log. Thanks! Thomas -- Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ buildroot mailing list buildroot at busybox.net <mailto:[email protected]> http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 18 lines
*BARTOSZ BI?AS* Embedded Software Developer GRINN skype: TEL.+48 71 716 40 99 WEB. grinn-global.com Grinn sp. z o.o. Strzegomska 140a 54-429 Wroc?aw KRS:0000230049 NIP:8992730302 REGON:020047322 S?d Rejonowy we Wroc?awiu VI Wydzia? Gospodarczy Kapita? zak?adowy: 125.000,00 z? -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20200103/07578b28/attachment.html>
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
In reply to Bartosz BilasQuoted 16 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Bartosz" == Bartosz Bilas <[email protected]> writes:
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)configs/stm32mp157c_dk2_defconfig +0
-0
configs/stm32mp157c_dk2_defconfig BR2_LINUX_KERNEL_INSTALL_TARGET=y · line 19
Quoted 4 lines
configs/stm32mp157c_dk2_defconfig +1
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"
Is this a general issue with the ext4 support in u-boot? Should we do this generally by default, similar to how we do it for 64bit?
Signature · 1 line
Bye, Peter Korsgaard
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
Hello Peter,
Quoted 10 lines · Peter Korsgaard
Quoted 9 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Bartosz" == Bartosz Bilas <[email protected]> writes:
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)
Quoted 13 lines
configs/stm32mp157c_dk2_defconfig BR2_LINUX_KERNEL_INSTALL_TARGET=y · line 19
Quoted 9 lines
configs/stm32mp157c_dk2_defconfig +1
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"Is this a general issue with the ext4 support in u-boot? Should we do this generally by default, similar to how we do it for 64bit?
probably in case when device saves env in file on ext4 it is, but it should be checked on the other boards in order to inquiry if I'm right. As I know the requests done by U-Boot are acceptable if the ext4 file system is generated with only the features supported by U-Boot. Unfortunately I don't have any board except that which allows me to do so.
Best
Bartek
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
In reply to Bartosz BilasHello Bartosz,
Quoted 14 lines · On Sun, 3 Nov 2019 12:50:16 +0100 Bartosz Bilas <[email protected]>…
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)configs/stm32mp157c_dk2_defconfig +0
-0
configs/stm32mp157c_dk2_defconfig BR2_LINUX_KERNEL_INSTALL_TARGET=y · line 19
Quoted 4 lines
configs/stm32mp157c_dk2_defconfig +1
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"
Are you sure it is necessary to disable those three options?
Indeed, U-Boot ext4 write support clearly excludes filesystems that have the metadata_csum option enabled:
https://gitlab.denx.de/u-boot/u-boot/blob/master/fs/ext4/ext4_write.c#L880
However, there's nothing about the 64bit and dir_index options. How did you conclude that they were causing problems? Did you try with just -O ^metadata_csum ?
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
Hello Thomas,
Quoted 25 lines · Thomas Petazzoni
Hello Bartosz,
Quoted 14 lines · On Sun, 3 Nov 2019 12:50:16 +0100 Bartosz Bilas <[email protected]>…
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)configs/stm32mp157c_dk2_defconfig +0
-0configs/stm32mp157c_dk2_defconfig BR2_LINUX_KERNEL_INSTALL_TARGET=y · line 19
Quoted 4 lines
configs/stm32mp157c_dk2_defconfig +1
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"Are you sure it is necessary to disable those three options?
Quoted 7 lines
Indeed, U-Boot ext4 write support clearly excludes filesystems that have the
metadata_csumoption enabled:https://gitlab.denx.de/u-boot/u-boot/blob/master/fs/ext4/ext4_write.c#L880However, there's nothing about the 64bit and
dir_indexoptions. How did you conclude that they were causing problems? Did you try with just -O ^metadata_csum ?
I was talking with the maintainer of that board on U-Boot mailing list
[1] and he said that I should disable those 2 options (dir_index and metada_csum) to have U-Boot working properly. I'm not sure about 64bit because I saw that was set by default in buildroot. I didn't check that with metadata_csum option only but I'll do that and let you know if it works.
[1] https://lists.denx.de/pipermail/u-boot/2019-October/388618.html
Best
Bartek
Quoted 4 lines
Thanks,
Thomas
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
Quoted 37 lines · Bartosz Bilas
Hello Thomas,
Quoted 26 lines · Thomas Petazzoni
Hello Bartosz,
Quoted 15 lines · On Sun,? 3 Nov 2019 12:50:16 +0100 Bartosz Bilas <[email protected]>…
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>---
? configs/stm32mp157c_dk2_defconfig | 1 +
? 1 file changed, 1 insertion(+)configs/stm32mp157c_dk2_defconfig +0
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=yQuoted 4 lines
? BR2_TARGET_ROOTFS_EXT2=y
? BR2_TARGET_ROOTFS_EXT2_4=y
? BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"Are you sure it is necessary to disable those three options?
Quoted 7 lines
Indeed, U-Boot ext4 write support clearly excludes filesystems that have the
metadata_csumoption enabled:?? https://gitlab.denx.de/u-boot/u-boot/blob/master/fs/ext4/ext4_write.c#L880
However, there's nothing about the 64bit anddir_indexoptions. How did you conclude that they were causing problems? Did you try with just -O ^metadata_csum ?
Quoted 5 lines
I was talking with the maintainer of that board on U-Boot mailing list [1] and he said that I should disable those 2 options (
dir_indexandmetada_csum) to have U-Boot working properly. I'm not sure about 64bit because I saw that was set by default in buildroot. I didn't check that withmetadata_csumoption only but I'll do that and let you know if it works.
As explained in the help text of the option:
The default is "-O ^64bit", i.e. disable 64-bit filesystem support. This default value has been chosen because U-Boot versions before 2017.02 don't support this filesystem
option: using it may make the filesystem unreadable by U-Boot.
Since this defconfig uses a more recent U-Boot, it's not necessary.
That said, if those two options should be disabled for U-Boot to work, it's
probably a good idea to add them to the defaults (i.e. all three options, like you put in the defconfig here).
Regards,
Arnout
Regards,
Arnout
PATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
Hello guys,
Quoted 51 lines · Arnout Vandecappelle
Quoted 36 lines · Bartosz Bilas
Hello Thomas,
Quoted 26 lines · Thomas Petazzoni
Hello Bartosz,
Quoted 15 lines · On Sun,? 3 Nov 2019 12:50:16 +0100 Bartosz Bilas <[email protected]>…
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- ? configs/stm32mp157c_dk2_defconfig | 1 +? 1 file changed, 1 insertion(+)
configs/stm32mp157c_dk2_defconfig +0
-0configs/stm32mp157c_dk2_defconfig BR2_LINUX_KERNEL_INSTALL_TARGET=y · line 19
Quoted 4 lines
configs/stm32mp157c_dk2_defconfig +1
-0@@ -16,6 +16,7 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y ? BR2_TARGET_ROOTFS_EXT2=y ? BR2_TARGET_ROOTFS_EXT2_4=y ? BR2_TARGET_ROOTFS_EXT2_SIZE="120M" +BR2_TARGET_ROOTFS_EXT2_MKFS_OPTIONS="-O ^64bit,^metadata_csum,^dir_index"Are you sure it is necessary to disable those three options?
Quoted 7 lines
Indeed, U-Boot ext4 write support clearly excludes filesystems that have the
metadata_csumoption enabled:?? https://gitlab.denx.de/u-boot/u-boot/blob/master/fs/ext4/ext4_write.c#L880
However, there's nothing about the 64bit anddir_indexoptions. How did you conclude that they were causing problems? Did you try with just -O ^metadata_csum ?Quoted 5 lines
I was talking with the maintainer of that board on U-Boot mailing list [1] and he said that I should disable those 2 options (
dir_indexandmetada_csum) to have U-Boot working properly. I'm not sure about 64bit because I saw that was set by default in buildroot. I didn't check that withmetadata_csumoption only but I'll do that and let you know if it works.As explained in the help text of the option:
The default is "-O ^64bit", i.e. disable 64-bit filesystem support. This default value has been chosen because U-Boot versions before 2017.02 don't support this filesystem
option: using it may make the filesystem unreadable by U-Boot.
Quoted 5 lines
Since this defconfig uses a more recent U-Boot, it's not necessary.
That said, if those two options should be disabled for U-Boot to work, it's
probably a good idea to add them to the defaults (i.e. all three options, like you put in the defconfig here).
I've checked if it worked with disabled metadata_csum option only and it turns out that Thomas is right. Kernel is able to mount rootfs partition properly even if I do any environment operation in U-Boot. So it means that the default 64bit option is not necessary as well.
Quoted 8 lines
Regards,
ArnoutRegards,
Arnout
Best
Bartek
Thomas Petazzoni
AppliedPATCH 1/2 configs/stm32mp157c_dk2: disable mkfs metadata_csum and dir_index options
In reply to Bartosz BilasQuoted 8 lines · On Sun, 3 Nov 2019 12:50:16 +0100 Bartosz Bilas <[email protected]>…
To solve issue with non-possibilities to mount rootfs partition we should disable a new mkfs features such as
metadata_csumanddir_indexbecause there is incompatibility with these options.Signed-off-by Bartosz Bilas <[email protected]>--- configs/stm32mp157c_dk2_defconfig | 1 + 1 file changed, 1 insertion(+)
Applied to master after changing the patch to only disable the metadata_csum option, as we discussed in the thread following this patch.
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com