u-boot/arch/arm
Patrick Delaunay 54be09cd8f arm: caches: manage phys_addr_t overflow in mmu_set_region_dcache_behaviour
Solved the overflow on phys_addr_t type for start + size in
mmu_set_region_dcache_behaviour() function.

This overflow is avoided by dividing start and end by 2 before addition,
and we only expecting that start and size are even.

This patch doesn't change the current function behavior if the
parameters (start or size) are not aligned on MMU_SECTION_SIZE.

For example, this overflow occurs on ARM32 with:
start = 0xC0000000 and size = 0x40000000
then start + size = 0x100000000 and end = 0x0.

For information the function behavior change with risk of regression,
if we just shift start and size before the addition.
Example with 2MB section size:
  MMU_SECTION_SIZE 0x200000 and MMU_SECTION_SHIFT = 21
  with start = 0x1000000, size = 0x1000000,
  - with the proposed patch, start = 0 and end = 0x1 as previously
  - with the more simple patch:
    end = (start >> MMU_SECTION_SHIFT) + (size >> MMU_SECTION_SHIFT)
    the value of end change:
    start >> 21 = 0, size >> 21 = 0 and end = 0x0 !!!

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2020-05-01 11:34:01 -04:00
..
cpu driver: net: fm: add DM ETH support 2020-04-29 11:10:54 +05:30
dts Xilinx changes for v2020.07-rc2 2020-04-30 11:34:01 -04:00
include arm: caches: add DCACHE_DEFAULT_OPTION 2020-05-01 11:34:01 -04:00
lib arm: caches: manage phys_addr_t overflow in mmu_set_region_dcache_behaviour 2020-05-01 11:34:01 -04:00
mach-aspeed dm: core: Require users of devres to include the header 2020-02-05 19:33:46 -07:00
mach-at91 common: Move hang() to the same header as panic() 2020-01-24 23:06:49 +05:30
mach-bcm283x rpi4: Update memory map to accommodate scb devices 2020-01-29 18:30:33 +01:00
mach-bcmstb
mach-cortina board: presidio-asic: Add basic G3 engr. development board support 2020-02-07 16:16:01 -05:00
mach-davinci mach-davinci: Hard-code the default SPL_LDSCRIPT path 2020-03-16 18:54:18 -04:00
mach-exynos arm: exynos: Read default MMC device from XOM[7:5] pins 2020-01-28 09:54:05 +09:00
mach-highbank
mach-imx spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-integrator
mach-k3 spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-keystone common: Move hang() to the same header as panic() 2020-01-24 23:06:49 +05:30
mach-kirkwood common: Move reset_cpu() to the CPU header 2020-01-24 23:06:49 +05:30
mach-mediatek arm: mediatek: remove unused binman config 2020-03-10 17:08:13 -04:00
mach-meson arm: meson-gx: add board_usb_init()/cleanup() for USB gadget 2020-04-20 14:19:10 +02:00
mach-mvebu arm: mvebu: correct SPL boot configs for SPI/MMC 2020-04-22 14:28:15 +02:00
mach-omap2 spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-orion5x edminiv2: Move CONFIG_SPL_LDSCRIPT to defconfig 2020-03-16 18:54:18 -04:00
mach-owl arm: add support Actions Semi S700 2020-04-24 16:40:09 -04:00
mach-qemu qemu: don't allow to select 32- and 64-bit 2020-04-24 10:51:32 -04:00
mach-rmobile common: Move some cache and MMU functions out of common.h 2019-12-02 18:23:55 -05:00
mach-rockchip spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-s5pc1xx common: Move some cache and MMU functions out of common.h 2019-12-02 18:23:55 -05:00
mach-snapdragon mach-snapdragon: Fix overwriting last digit of serial number 2020-04-03 11:47:47 -04:00
mach-socfpga arm: socfpga: stratix10: Fix incorrect CLKMGR_S10_PERPLL_BYPASS offset 2020-04-27 09:14:52 +02:00
mach-sti
mach-stm32 mach-stm32: Fix MPU region size dedicated to SDRAM for STM32F4 2019-06-28 09:45:27 +02:00
mach-stm32mp spl: mmc: Rename spl_boot_partition() to spl_mmc_boot_partition() 2020-04-22 20:41:57 +08:00
mach-sunxi sunxi: SPL SPI: Add SPI boot support for the Allwinner H6 SoC 2020-03-18 18:12:04 +05:30
mach-tegra ARM: tegra: Add NVIDIA Jetson Nano Developer Kit support 2020-04-02 14:30:02 -07:00
mach-u8500 board: Add new Samsung "stemmy" board based on ST-Ericsson U8500 2020-01-22 17:47:57 -05:00
mach-uniphier spl: mmc: Rename spl_boot_mode() to spl_mmc_boot_mode() 2020-04-22 20:41:57 +08:00
mach-versal arm: asm/cache.c: Introduce arm_reserve_mmu 2020-04-24 15:17:14 -04:00
mach-versatile
mach-zynq ARM: zynq: Do not print message about boot device 2020-04-06 12:52:45 +02:00
mach-zynqmp arm: asm/cache.c: Introduce arm_reserve_mmu 2020-04-24 15:17:14 -04:00
mach-zynqmp-r5 common: Move reset_cpu() to the CPU header 2020-01-24 23:06:49 +05:30
thumb1/include/asm/proc-armv
config.mk
Kconfig configs: migrate CONFIG_SYS_ARM_CACHE_* in Kconfig 2020-05-01 11:34:01 -04:00
Kconfig.debug
Makefile arm: Add support for ST-Ericsson U8500 SoC 2020-01-22 17:47:57 -05:00