Message ID | 20180302005659.28728-10-andre.przywara@arm.com |
---|---|
State | Superseded |
Delegated to: | Jagannadha Sutradharudu Teki |
Headers | show |
Series | sunxi: sync H3, H5, A64 DTs from mainline Linux | expand |
Hi, On Fri, Mar 02, 2018 at 12:56:48AM +0000, Andre Przywara wrote: > Since the dawn of time for the Allwinner support in mainline U-Boot > we store the environment to the SD card and write directly at > 544KB from the beginning of the device. This leads to problems when > the U-Boot proper image grows beyond 504KB and eventually overlaps. > With one release of having the environment preferably in a FAT > partition, let's now turn off the MMC variant fallback, so we get back > all the space we need to implement features. > In case someone desperately needs to turn direct MMC environment back > on, let's move that to 896KB (128K below 1MB), so that we won't be > easily limited anymore. > > Signed-off-by: Andre Przywara <andre.przywara@arm.com> > --- > env/Kconfig | 5 +++-- > include/configs/sunxi-common.h | 2 +- > 2 files changed, 4 insertions(+), 3 deletions(-) > > diff --git a/env/Kconfig b/env/Kconfig > index a3c6298273..b404855542 100644 > --- a/env/Kconfig > +++ b/env/Kconfig > @@ -152,7 +152,7 @@ config ENV_IS_IN_MMC > bool "Environment in an MMC device" > depends on !CHAIN_OF_TRUST > depends on MMC > - default y if ARCH_SUNXI > + default y if ARCH_SUNXI && !ARM64 I'd go even further and remove it for everyone. > default y if ARCH_EXYNOS4 > default y if MX6SX || MX7D > default y if TEGRA30 || TEGRA124 > @@ -443,7 +443,8 @@ config ENV_OFFSET > hex "Environment Offset" > depends on !ENV_IS_IN_UBI > depends on !ENV_IS_NOWHERE > - default 0x88000 if ARCH_SUNXI > + default 0x88000 if ARCH_SUNXI && !ARM64 > + default 0xe0000 if ARCH_SUNXI && ARM64 However, I'm not sure why that would be needed. I would rather keep the old value to have an easy fallback to the old environment, given that you disable a few things afterwards. Maxime
Hi, On 02/03/18 15:56, Maxime Ripard wrote: > Hi, > > On Fri, Mar 02, 2018 at 12:56:48AM +0000, Andre Przywara wrote: >> Since the dawn of time for the Allwinner support in mainline U-Boot >> we store the environment to the SD card and write directly at >> 544KB from the beginning of the device. This leads to problems when >> the U-Boot proper image grows beyond 504KB and eventually overlaps. >> With one release of having the environment preferably in a FAT >> partition, let's now turn off the MMC variant fallback, so we get back >> all the space we need to implement features. >> In case someone desperately needs to turn direct MMC environment back >> on, let's move that to 896KB (128K below 1MB), so that we won't be >> easily limited anymore. >> >> Signed-off-by: Andre Przywara <andre.przywara@arm.com> >> --- >> env/Kconfig | 5 +++-- >> include/configs/sunxi-common.h | 2 +- >> 2 files changed, 4 insertions(+), 3 deletions(-) >> >> diff --git a/env/Kconfig b/env/Kconfig >> index a3c6298273..b404855542 100644 >> --- a/env/Kconfig >> +++ b/env/Kconfig >> @@ -152,7 +152,7 @@ config ENV_IS_IN_MMC >> bool "Environment in an MMC device" >> depends on !CHAIN_OF_TRUST >> depends on MMC >> - default y if ARCH_SUNXI >> + default y if ARCH_SUNXI && !ARM64 > > I'd go even further and remove it for everyone. Fine, if you say so! > >> default y if ARCH_EXYNOS4 >> default y if MX6SX || MX7D >> default y if TEGRA30 || TEGRA124 >> @@ -443,7 +443,8 @@ config ENV_OFFSET >> hex "Environment Offset" >> depends on !ENV_IS_IN_UBI >> depends on !ENV_IS_NOWHERE >> - default 0x88000 if ARCH_SUNXI >> + default 0x88000 if ARCH_SUNXI && !ARM64 >> + default 0xe0000 if ARCH_SUNXI && ARM64 > > However, I'm not sure why that would be needed. I would rather keep > the old value to have an easy fallback to the old environment, given > that you disable a few things afterwards. Yeah, fair enough. Wasn't so sure about it anyway. Cheers, Andre.
diff --git a/env/Kconfig b/env/Kconfig index a3c6298273..b404855542 100644 --- a/env/Kconfig +++ b/env/Kconfig @@ -152,7 +152,7 @@ config ENV_IS_IN_MMC bool "Environment in an MMC device" depends on !CHAIN_OF_TRUST depends on MMC - default y if ARCH_SUNXI + default y if ARCH_SUNXI && !ARM64 default y if ARCH_EXYNOS4 default y if MX6SX || MX7D default y if TEGRA30 || TEGRA124 @@ -443,7 +443,8 @@ config ENV_OFFSET hex "Environment Offset" depends on !ENV_IS_IN_UBI depends on !ENV_IS_NOWHERE - default 0x88000 if ARCH_SUNXI + default 0x88000 if ARCH_SUNXI && !ARM64 + default 0xe0000 if ARCH_SUNXI && ARM64 help Offset from the start of the device (or partition) diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h index e4e7c22778..1c881286dd 100644 --- a/include/configs/sunxi-common.h +++ b/include/configs/sunxi-common.h @@ -148,7 +148,7 @@ * (CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)), but the value will be used * directly in a makefile, without the preprocessor expansion. */ -#define CONFIG_BOARD_SIZE_LIMIT 0x7e000 +#define CONFIG_BOARD_SIZE_LIMIT 0xd6000 #endif #if CONFIG_MMC_SUNXI_SLOT_EXTRA != -1
Since the dawn of time for the Allwinner support in mainline U-Boot we store the environment to the SD card and write directly at 544KB from the beginning of the device. This leads to problems when the U-Boot proper image grows beyond 504KB and eventually overlaps. With one release of having the environment preferably in a FAT partition, let's now turn off the MMC variant fallback, so we get back all the space we need to implement features. In case someone desperately needs to turn direct MMC environment back on, let's move that to 896KB (128K below 1MB), so that we won't be easily limited anymore. Signed-off-by: Andre Przywara <andre.przywara@arm.com> --- env/Kconfig | 5 +++-- include/configs/sunxi-common.h | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-)