[PATCH] scmi: correctly configure MMU for SCMI buffer

2021-03-16 Thread Patrick Delaunay
Align the MMU area for SCMI shared buffer on section size; use the ALIGN macro in mmu_set_region_dcache_behaviour call. Since commit d877f8fd0f09 ("arm: provide a function for boards init code to modify MMU virtual-physical map") the parameter of mmu_set_region_dcache_behaviour need to be MMU_SECT

Re: [PATCH u-boot] regmap: fix a serious pointer casting bug

2021-03-16 Thread Bin Meng
Hi Simon, On Tue, Mar 16, 2021 at 2:10 PM Simon Glass wrote: > > Hello Marek, > > On 03.03.21 14:15, Marek Behún wrote: > > There is a serious bug in regmap_read() and regmap_write() functions > > where an uint pointer is cast to (void *) which is then cast to (u8 *), > > (u16 *), (u32 *) or (u64

Re: [PATCH] doc: icicle: Fix incorrect board name in HSS docs

2021-03-16 Thread Heinrich Schuchardt
On 11.03.21 02:48, Sean Anderson wrote: > The HSS source uses an "mpfs" prefix with the icicle board name. Change our > documentation to match. > > Signed-off-by: Sean Anderson > --- > > doc/board/microchip/mpfs_icicle.rst | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --g

Re: [PATCH u-boot v2.1 38/38] ARM: enable LTO for some boards

2021-03-16 Thread Marek Behun
On Mon, 15 Mar 2021 21:12:32 -0400 Tom Rini wrote: > On Mon, Mar 15, 2021 at 10:42:31AM +0100, Marek Behun wrote: > > On Fri, 12 Mar 2021 15:47:12 -0500 > > Tom Rini wrote: > > > > > On Fri, Mar 12, 2021 at 06:36:05PM +0100, Marek Behun wrote: > > > > On Fri, 12 Mar 2021 18:19:08 +0100 > >

RE: [PATCH] arm: socfpga: smc: Remove unused SMC function ID

2021-03-16 Thread Tan, Ley Foon
> -Original Message- > From: Lim, Elly Siew Chin > Sent: Friday, March 12, 2021 5:51 PM > To: u-boot@lists.denx.de > Cc: Marek Vasut ; Tan, Ley Foon > ; See, Chin Liang ; > Simon Goldschmidt ; Chee, Tien Fong > ; Westergreen, Dalon > ; Simon Glass ; Gan, > Yau Wai ; Lim, Elly Siew Chin

Re: [PATCH] pci: layerscape: Change to allocate zeroed memery for struct ls_pcie

2021-03-16 Thread Vladimir Oltean
On Thu, Mar 11, 2021 at 03:30:51PM +0800, Zhiqiang Hou wrote: > From: Hou Zhiqiang > > As on some incipient Layerscape platforms (LS1043A series) there isn't > separate PF control register block, these registers reside in the LUT > register block, so when the driver detected there isn't 'ctrl', i

Pull request for efi-2021-04-rc5

2021-03-16 Thread Heinrich Schuchardt
Dear Tom, The following changes since commit 4103e13534141c31e4e9bf40848ab3a61dabce81: Prepare v2021.04-rc4 (2021-03-15 12:06:41 -0400) are available in the Git repository at: https://source.denx.de/u-boot/custodians/u-boot-efi.git tags/efi-2021-04-rc5 for you to fetch changes up to 75d48d

Re: [PATCH 6/7] board: sifive: add HiFive Unmatched board support

2021-03-16 Thread Green Wan
On Thu, Mar 11, 2021 at 10:21 PM Bin Meng wrote: > On Thu, Mar 11, 2021 at 9:50 PM Green Wan wrote: > > > > Add dts, defconfig and board support for HiFive Unmatched. > > > > Signed-off-by: Green Wan > > --- > > arch/riscv/dts/fu740-hifive-unmatched-a00-ddr.dtsi | 1489 > >

[PATCH u-boot v3 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Marek Behún
There is a serious bug in regmap_read() and regmap_write() functions where an uint pointer is cast to (void *) which is then cast to (u8 *), (u16 *), (u32 *) or (u64 *), depending on register width of the map. For example given a regmap with 16-bit register width the code int val = 0x12340

[PATCH u-boot v3 00/39] U-Boot LTO (Sandbox + Some ARM boards)

2021-03-16 Thread Marek Behún
Hello, this is version 3 of patches adding support for LTO to U-Boot. This series was tested by Github/Azure CI at https://github.com/u-boot/u-boot/pull/57 Code reduction is on average 4.23% for u-boot.bin and 13.58% for u-boot-spl.bin. Changes sinve v2: - now linking with --build-id=none in

[PATCH u-boot v3 03/39] checkpatch: require quotes around section name in the __section() macro

2021-03-16 Thread Marek Behún
This is how Linux does this now, see Linux commit 339f29d91acf. Signed-off-by: Marek Behún --- scripts/checkpatch.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 755f4802a4..fd1e9c4d24 100755 --- a/scripts/checkpatch.pl +

[PATCH u-boot v3 06/39] linker_lists: prepare macros to avoid code repetition

2021-03-16 Thread Marek Behún
Prepare private macros expanding to linker list entry symbol name and declaration to avoid nasty code repetition in the next patch. We also avoid some code repetition in current code with these macros. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- include/linker_lists.h | 46 +++

[PATCH u-boot v3 05/39] compiler.h: align the __ADDRESSABLE macro with Linux' version

2021-03-16 Thread Marek Behún
Use UNIQUE_ID in the __ADDRESSABLE macro. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- include/linux/compiler.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/compiler.h b/include/linux/compiler.h index 82a8a4ede9..98dd3fc4cc 100644 --- a/include/linux

[PATCH u-boot v3 02/39] api: fix a potential serious bug caused by undef CONFIG_SYS_64BIT_LBA

2021-03-16 Thread Marek Behún
The api_public.h header file undefined macro CONFIG_SYS_64BIT_LBA. But api/api_storage.c includes this header before including part.h, causing the type of lbaint_t and subsequently the type signature of blk_dread() and blk_dwrite() functions to change from the rest of U-Boot (if CONFIG_SYS_64BIT_L

[PATCH u-boot v3 07/39] test/py: improve regular expression for ut subtest symbol matcher

2021-03-16 Thread Marek Behún
Improve the regular expression that matches unittest symbols in u-boot.sym. Currently we do not enforce no prefix in symbol string, but with the soon to come change in linker lists declaring lists and entries with the __ADDRESSABLE macro (because of LTO), the symbol file will contain for every sym

[PATCH u-boot v3 04/39] treewide: Convert macro and uses of __section(foo) to __section("foo")

2021-03-16 Thread Marek Behún
This commit does the same thing as Linux commit 33def8498fdd. Use a more generic form for __section that requires quotes to avoid complications with clang and gcc differences. Remove the quote operator # from compiler_attributes.h __section macro. Convert all unquoted __section(foo) uses to quot

[PATCH u-boot v3 09/39] string: make memcpy(), memset(), memcmp() and memmove() visible for LTO

2021-03-16 Thread Marek Behún
It seems that sometimes (happening on ARM64, for example with turris_mox_defconfig) GCC, when linking with LTO, changes the symbol names of some functions, for example lib/string.c's memcpy() function to memcpy.isra.0. This is a problem however when GCC for a code such as this: struct some

[PATCH u-boot v3 08/39] linker_lists: declare lists and entries as __ADDRESSABLE for LTO

2021-03-16 Thread Marek Behún
Use the __ADDRESSABLE() macro to make entries and lists declared by ll_entry_declare() and ll_entry_declare_list() addressable so that when building with LTO the compiler does not optimize this data away. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- include/linker_lists.h | 8 ++--

[PATCH u-boot v3 10/39] efi_loader: fix warning when linking with LTO

2021-03-16 Thread Marek Behún
When linking with LTO, the compiler complains about type mismatch of variables `__efi_runtime_start`, `__efi_runtime_stop`, `__efi_runtime_rel_start` and `__efi_runtime_rel_stop`: include/efi_loader.h:218:21: warning: type of ‘__efi_runtime_start’ does not m

[PATCH u-boot v3 11/39] efi_loader: add Sphinx doc for __efi_runtime and __efi_runtime_data

2021-03-16 Thread Marek Behún
Document the macros __efi_runtime and __efi_runtime_data in Sphinx style. Signed-off-by: Marek Behún Reviewed-by: Heinrich Schuchardt --- include/efi_loader.h | 29 ++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/include/efi_loader.h b/include/efi_lo

[PATCH u-boot v3 15/39] Makefile, Makefile.spl: cosmetic change

2021-03-16 Thread Marek Behún
Indent the linking commands so that they look cosmetically better. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- Makefile | 12 +++- scripts/Makefile.spl | 17 +++-- 2 files changed, 18 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index

[PATCH u-boot v3 14/39] lib: crc32: put the crc_table variable into efi_runtime_rodata section

2021-03-16 Thread Marek Behún
When compiling with LTO, the compiler fails with an error saying that `crc_table` causes a section type conflict with `efi_var_buf`. This is because both are declared to be in the same section (via macro `__efi_runtime_data`), but one is const while the other is not. Put this variable into the se

[PATCH u-boot v3 12/39] efi_loader: add macro for const EFI runtime data

2021-03-16 Thread Marek Behún
Add macro __efi_runtime_rodata, for const variables with similar purpose as those using __efi_runtime_data. Signed-off-by: Marek Behún Reviewed-by: Heinrich Schuchardt --- include/efi_loader.h | 17 + 1 file changed, 17 insertions(+) diff --git a/include/efi_loader.h b/include/

[PATCH u-boot v3 13/39] efi_selftest: compiler flags for efi_selftest_miniapp_exception.o

2021-03-16 Thread Marek Behún
Add $(CFLAGS_EFI) and remove $(CFLAGS_NON_EFI) for efi_selftest_miniapp_exception.o. The removal is needed when compiling with LTO - this object file needs to be compiled without -flto. The adding is for consistency with other miniapps. Signed-off-by: Marek Behún Reviewed-by: Heinrich Schuchard

[PATCH u-boot v3 19/39] sandbox: errno: avoid conflict with libc's errno

2021-03-16 Thread Marek Behún
When building with LTO, the system libc's `errno` variable used in arch/sandbox/cpu/os.c conflicts with U-Boot's `errno` (defined in lib/errno.c) with the following error: .../ld: errno@@GLIBC_PRIVATE: TLS definition in /lib64/libc.so.6 section .tbss mismatches non-TLS reference in

[PATCH u-boot v3 18/39] build: link with --build-id=none

2021-03-16 Thread Marek Behún
Some toolchains are compiled so that they pass a --build-id=something parameter to the linker implicitly. This causes U-Boot LTO linking to fail with something like: ld: section .note.gnu.build-id LMA ... overlaps section .text LMA ... because U-Boot's link scripts do not currently handle .note.

[PATCH u-boot v3 16/39] build: use thin archives instead of incremental linking

2021-03-16 Thread Marek Behún
Currently we use incremental linking (ld -r) to link several object files from one directory into one built-in.o object file containing the linked code from that directory (and its subdirectories). Linux has, some time ago, moved to thin archives instead. Thin archives are archives (.a) that do n

[PATCH u-boot v3 21/39] sandbox: make LTO available

2021-03-16 Thread Marek Behún
Make LTO available for sandbox architecture. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- arch/Kconfig | 1 + arch/sandbox/config.mk | 2 ++ 2 files changed, 3 insertions(+) diff --git a/arch/Kconfig b/arch/Kconfig index 27843cd79c..a6dab3e56d 100644 --- a/arch/Kconfig +++ b/

[PATCH u-boot v3 20/39] sandbox: use sections instead of symbols for getopt array boundaries

2021-03-16 Thread Marek Behún
In style of linked lists, instead of declaring symbols for boundaries of getopt options array in the linker script, declare corresponding sections and retrieve the boundaries via static inline functions. Without this clang's LTO produces binary without any getopt options, because for some reason i

[PATCH u-boot v3 17/39] build: support building with Link Time Optimizations

2021-03-16 Thread Marek Behún
Add plumbing for building U-Boot with Link Time Optimizations. When building with LTO, $(PLATFORM_LIBS) has to be in --whole-archive / --no-whole-archive group, otherwise some functions declared in assembly may not be resolved and linking may fail. Signed-off-by: Marek Behún --- Kbuild

[PATCH u-boot v3 22/39] sandbox: enable LTO by default

2021-03-16 Thread Marek Behún
Build sandbox targets with LTO by default. Signed-off-by: Marek Behún Reviewed-by: Bin Meng --- arch/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/Kconfig b/arch/Kconfig index a6dab3e56d..b884b7b248 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -123,6 +123,7 @@ config SANDB

[PATCH u-boot v3 23/39] ARM: global_data: make set_gd() work for armv5 and armv6

2021-03-16 Thread Marek Behún
The Thumb instruction `ldr` is able to move high registers only from armv7. For armv5 and armv6 we have to use `mov`. Signed-off-by: Marek Behún --- arch/arm/include/asm/global_data.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/arm/include/asm/global_data.h b/arc

[PATCH u-boot v3 25/39] ARM: fix LTO build for some thumb-interwork cases

2021-03-16 Thread Marek Behún
Fix LTO build for some thumb-interwork usecases (such as for da850evm_defconfig), where inline assmebly such as mrc p15,0,r2,c1,c0,0 causes the compiler to fail during LTO linking with Error: selected processor does not support `mrc p15,0,r2,c1,c0,0' in Thumb mode Signed-off-by: Marek

[PATCH u-boot v3 24/39] ARM: make gd a function call for LTO and set via set_gd()

2021-03-16 Thread Marek Behún
On ARM, the gd pointer is stored in registers r9 / x18. For this the -ffixed-r9 / -ffixed-x18 flag is used when compiling, but using global register variables causes errors when building with LTO, and these errors are very difficult to overcome. Richard Biener says [1]: Note that global register

[PATCH u-boot v3 26/39] ARM: fix LTO for imx28_xea

2021-03-16 Thread Marek Behún
When imx28_xea_defconfig is built with LTO, the compiler complains about the two different declarations of _start: include/asm-generic/sections.has extern void _start(void); arch/arm/cpu/arm926ejs/mxs/mxs.c as extern uint32_t _start; Fix this. Signed-off-by: Marek Behún Reviewed-by:

[PATCH u-boot v3 27/39] ARM: fix LTO for apf27

2021-03-16 Thread Marek Behún
When apf27_defconfig is built with LTO, linking complains about undefined reference to `nand_boot`. This is because it is referenced from inline assembly. Make it visible. Signed-off-by: Marek Behún --- drivers/mtd/nand/raw/mxc_nand_spl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

[PATCH u-boot v3 28/39] ARM: fix LTO for keystone

2021-03-16 Thread Marek Behún
When building keystone with LTO the compiler complains: Error: selected processor does not support `smc #0' in Thumb mode Fix this by removing -flto for the file implementing these SMC calls. Signed-off-by: Marek Behún --- arch/arm/mach-keystone/Makefile | 1 + 1 file changed, 1 insertion(+)

[PATCH u-boot v3 32/39] ARM: fix LTO for rockchip and samsung

2021-03-16 Thread Marek Behún
When building with LTO, the compiler complains about type mismatch of function usb_gadget_handle_interrupts(). This function is defined without parameters in files arch/arm/mach-rockchip/board.c board/samsung/common/exynos5-dt.c but it should have one parameter, int index. Fix this. Signed-of

[PATCH u-boot v3 29/39] ARM: kona: fix clk_bsc_enable() type mismatch for LTO

2021-03-16 Thread Marek Behún
When building with LTO, the compiler complains about type mismatch of function clk_bsc_enable() in file: arch/arm/cpu/armv7/kona-common/clk-stubs.c vs other files that define or use this function: warning: type of ‘clk_bsc_enable’ does not match original declaration. Change the type of this fu

[PATCH u-boot v3 30/39] ARM: imx8m: fix imx_eqos_txclk_set_rate() type mismatch for LTO

2021-03-16 Thread Marek Behún
When building imx8mp_evk_defconfig with LTO, the compiler complains about type mismatch of function imx_eqos_txclk_set_rate() in file drivers/net/dwc_eth_qos.c:845:12 which contains a weak definition of this function, vs file arch/arm/mach-imx/imx8m/clock_imx8mm.c which contains an implementati

[PATCH u-boot v3 34/39] armv8: SPL: discard relocation information

2021-03-16 Thread Marek Behún
For some reason when building SPL for ARMv8 with LTO, the relocation information is not discarded. Discard it explicitly in the linker script. This fixes LTO build for imx8mm_venice_defconfig. Signed-off-by: Marek Behún --- arch/arm/cpu/armv8/u-boot-spl.lds | 1 + 1 file changed, 1 insertion(+

[PATCH u-boot v3 31/39] ARM: fix LTO for seaboard

2021-03-16 Thread Marek Behún
When seaboard_defconfig is compiled with LTO, the compiler complains about some instructions not being supported in ARM mode. This is caused by arch/arm/mach-tegra/tegra20/warmboot_avp.c having different CFLAGS declared in Makefile. This file needs to be compiled without LTO. Fix this by removing

[PATCH u-boot v3 35/39] ata: ahci: fix ahci_link_up() type mismatch for LTO

2021-03-16 Thread Marek Behún
When building highbank_defconfig with LTO, the compiler complains about type mismatch of function ahci_link_up(). The third parameter of this function is of type u8 in drivers/ata/ahci.c, but of type int in board/highbank/ahci.c. There is no reason in using u8, and the code using this function ac

[PATCH u-boot v3 33/39] ARM: omap3: fix LTO for DM3730 (and possibly other omap3 boards)

2021-03-16 Thread Marek Behún
Adam Ford says that DM3730 needs board.c compiled without LTO flags. Signed-off-by: Marek Behún Tested-by: Adam Ford --- arch/arm/mach-omap2/omap3/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/mach-omap2/omap3/Makefile b/arch/arm/mach-omap2/omap3/Makefile index 91ed8ebc

[PATCH u-boot v3 37/39] ARM: don't use -ffunction-sections/-fdata-sections with LTO build

2021-03-16 Thread Marek Behún
When building with LTO, using -ffunction-sections/-fdata-sections is not useful anymore. Signed-off-by: Marek Behún --- arch/arm/config.mk | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/arch/arm/config.mk b/arch/arm/config.mk index 4153f7e371..2b2c6ad2e5 100644 --- a

[PATCH u-boot v3 36/39] ARM: make LTO available

2021-03-16 Thread Marek Behún
Make LTO available for ARM architecture. Signed-off-by: Marek Behún --- arch/Kconfig | 1 + arch/arm/lib/Makefile | 2 ++ 2 files changed, 3 insertions(+) diff --git a/arch/Kconfig b/arch/Kconfig index b884b7b248..bf4b8afcb4 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -33,6 +33,7 @

[PATCH u-boot v3 38/39] ARM: don't use --gc-sections with LTO when using private libgcc

2021-03-16 Thread Marek Behún
When using LTO, we can throw away the --gc-sections flag, but only if using private libgcc. When using system's libgcc, --gc-sections is still needed, otherwise linking will fail due to undefined references to libc's symbols. Signed-off-by: Marek Behún --- arch/arm/config.mk | 2 ++ 1 file chan

[PATCH u-boot v3 39/39] ARM: enable LTO for some boards

2021-03-16 Thread Marek Behún
Enable LTO for some boards that were tested by people on U-Boot Mailing List. Signed-off-by: Marek Behún Tested-by: Adam Ford Tested-by: Pali Rohár Tested-by: Tim Harvey --- configs/am3517_evm_defconfig | 1 + configs/da850evm_defconfig| 1 + configs/da850evm_direct_nor_d

[PATCH] dm: spi: Prevent setting a speed of 0 Hz in spi_post_probe

2021-03-16 Thread Michal Simek
The commit 12bfb2e05fc2 ("dm: spi: prevent setting a speed of 0 Hz") changes default value from 0 to SPI_DEFAULT_SPEED_HZ but spi_post_probe() hasn't been updated in the same way. It should be also update to be aligned with previous patch. Fixes: 12bfb2e05fc2 ("dm: spi: prevent setting a speed of

Ficus EE not working / supported ?

2021-03-16 Thread Ezequiel Garcia
Hi Mani, Kever, I tried to bringup (again) my Ficus board, but I've been unable to boot a kernel. Seems my old u-boot branch doesn't want to boot, and the only U-Boot I managed to boot is some recent one (which I guess is better than having an ancient one). Now, doc/board/rockchip/rockchip.rst m

Re: [PATCH] doc: icicle: Fix incorrect board name in HSS docs

2021-03-16 Thread Sean Anderson
On 3/16/21 4:51 AM, Heinrich Schuchardt wrote: On 11.03.21 02:48, Sean Anderson wrote: The HSS source uses an "mpfs" prefix with the icicle board name. Change our documentation to match. Signed-off-by: Sean Anderson --- doc/board/microchip/mpfs_icicle.rst | 6 +++--- 1 file changed, 3 inse

Re: [PATCH v2 1/9] ARM: dts: stm32: Add Engicam i.Core STM32MP1 SoM

2021-03-16 Thread Patrick DELAUNAY
Hi Jagan On 3/15/21 6:32 PM, Jagan Teki wrote: i.Core STM32MP1 is an EDIMM SoM based on STM32MP157A from Engicam. General features: - STM32MP157A - Up to 1GB DDR3L - 4GB eMMC - 10/100 Ethernet - USB 2.0 Host/OTG - I2S - MIPI DSI to LVDS - rest of STM32MP157A features i.Core STM32MP1 needs to m

Re: [PATCH v2 2/9] ARM: dts: stm32: Add Engicam i.Core STM32MP1 1X4Gb DDR3

2021-03-16 Thread Patrick DELAUNAY
Hi Jagan On 3/15/21 6:32 PM, Jagan Teki wrote: Engicam i.Core STM32MP1 SODIMM SoM has mounted 1x4Gb DDR3 which has 32bits width 528000Khz frequency. Add DDR configuration via dtsi. Reviewed-by: Patrice Chotard Signed-off-by: Jagan Teki --- Changes for v2: - collect Patrice r-b .../stm32mp

Re: [PATCH] dm: spi: Prevent setting a speed of 0 Hz in spi_post_probe

2021-03-16 Thread Pratyush Yadav
On 16/03/21 01:33PM, Michal Simek wrote: > The commit 12bfb2e05fc2 ("dm: spi: prevent setting a speed of 0 Hz") > changes default value from 0 to SPI_DEFAULT_SPEED_HZ but spi_post_probe() > hasn't been updated in the same way. It should be also update to be aligned > with previous patch. > > Fixes

Re: [PATCH v2 3/9] ARM: stm32: Imply SPL_SPI_LOAD

2021-03-16 Thread Patrick DELAUNAY
On 3/15/21 6:32 PM, Jagan Teki wrote: SPI Load isn't mandatory for STM32 builds. Let's imply instead of select it to get rid of build issues for non-SPI defconfigs. Reviewed-by: Patrice Chotard Signed-off-by: Jagan Teki --- Changes for v2: - collect Patrice r-b arch/arm/mach-stm32mp/Kcon

Re: [PATCH v2 4/9] board: stm32: Add Engicam i.Core STM32MP1 EDIMM2.2 Starter Kit

2021-03-16 Thread Patrick DELAUNAY
On 3/15/21 6:32 PM, Jagan Teki wrote: Engicam EDIMM2.2 Starter Kit is an EDIMM 2.2 Form Factor Capacitive Evaluation Board. Genaral features: - LCD 7" C.Touch - microSD slot - Ethernet 1Gb - Wifi/BT - 2x LVDS Full HD interfaces - 3x USB 2.0 - 1x USB 3.0 - HDMI Out - Mini PCIe - MIPI CSI - 2x C

Re: [PATCH v2 5/9] board: stm32: Add Engicam i.Core STM32MP1 C.TOUCH 2.0

2021-03-16 Thread Patrick DELAUNAY
Hi Jagan, On 3/15/21 6:32 PM, Jagan Teki wrote: Engicam C.TOUCH 2.0 is an EDIMM compliant general purpose Carrier board. Genaral features: - Ethernet 10/100 - Wifi/BT - USB Type A/OTG - Audio Out - CAN - LVDS panel connector i.Core STM32MP1 is an EDIMM SoM based on STM32MP157A from Engicam. i

Re: [PATCH v2 6/9] ARM: dts: stm32: Add Engicam MicroGEA STM32MP1 Micro SoM

2021-03-16 Thread Patrick DELAUNAY
Hi Jagan, On 3/15/21 6:32 PM, Jagan Teki wrote: MicroGEA STM32MP1 is a STM32MP157A based Micro SoM. General features: - STM32MP157AAC - Up to 1GB DDR3L-800 - 512MB Nand flash - I2S MicroGEA STM32MP1 needs to mount on top of Engicam MicroDev carrier boards for creating complete platform solutio

Re: [PATCH v2 7/9] ARM: dts: stm32: Add Engicam MicroGEA STM32MP1 1X4Gb DDR3

2021-03-16 Thread Patrick DELAUNAY
Hi Jagan, On 3/15/21 6:32 PM, Jagan Teki wrote: Engicam MicroGEA STM32MP1 Micro SOM has mounted 1x4Gb DDR3 which has 16bits width 533Mhz frequency. Add DDR configurations via dtsi. Reviewed-by: Patrice Chotard Signed-off-by: Jagan Teki --- Changes for v2: - collect Patrice r-b ...m32mp15-

Re: [PATCH v2 8/9] board: stm32: Add Engicam MicroGEA STM32MP1 MicroDev 2.0 board

2021-03-16 Thread Patrick DELAUNAY
On 3/15/21 6:32 PM, Jagan Teki wrote: MicroDev 2.0 is a general purpose miniature carrier board with CAN, LTE and LVDS panel interfaces. Genaral features: - Ethernet 10/100 - USB Type A - Audio Out - microSD - LVDS panel connector - Wifi/BT (option) - UMTS LTE with sim connector (option) Micr

Re: [PATCH u-boot v3 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Pratyush Yadav
On 16/03/21 01:25PM, Marek Behún wrote: > There is a serious bug in regmap_read() and regmap_write() functions > where an uint pointer is cast to (void *) which is then cast to (u8 *), > (u16 *), (u32 *) or (u64 *), depending on register width of the map. > > For example given a regmap with 16-bit

Re: [PATCH u-boot v3 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Marek Behun
On Tue, 16 Mar 2021 19:28:46 +0530 Pratyush Yadav wrote: > On 16/03/21 01:25PM, Marek Behún wrote: > > There is a serious bug in regmap_read() and regmap_write() functions > > where an uint pointer is cast to (void *) which is then cast to (u8 *), > > (u16 *), (u32 *) or (u64 *), depending on reg

Re: [PATCH v2 9/9] board: stm32: Add Engicam MicroGEA STM32MP1 MicroDev 2.0 7" OF

2021-03-16 Thread Patrick DELAUNAY
On 3/15/21 6:32 PM, Jagan Teki wrote: 7" OF is a capacitive touch 7" Open Frame panel solutions with - 7" AUO B101AW03 LVDS panel - EDT, FT5526 Touch MicroGEA STM32MP1 is a STM32MP157A based Micro SoM. MicroDev 2.0 is a general purpose miniature carrier board with CAN, LTE and LVDS panel inte

Re: [PATCH v2 7/9] ARM: dts: stm32: Add Engicam MicroGEA STM32MP1 1X4Gb DDR3

2021-03-16 Thread Jagan Teki
Hi Patrick, On Tue, Mar 16, 2021 at 7:16 PM Patrick DELAUNAY wrote: > > Hi Jagan, > > On 3/15/21 6:32 PM, Jagan Teki wrote: > > Engicam MicroGEA STM32MP1 Micro SOM has mounted 1x4Gb DDR3 > > which has 16bits width 533Mhz frequency. > > > > Add DDR configurations via dtsi. > > > > Reviewed-by: Pat

[PATCH u-boot v3.1 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Marek Behún
There is a serious bug in regmap_read() and regmap_write() functions where an uint pointer is cast to (void *) which is then cast to (u8 *), (u16 *), (u32 *) or (u64 *), depending on register width of the map. For example given a regmap with 16-bit register width the code int val = 0x12340

Re: [PATCH] scmi: correctly configure MMU for SCMI buffer

2021-03-16 Thread Etienne Carriere
Hello Patrick, On Tue, 16 Mar 2021 at 09:29, Patrick Delaunay wrote: > > Align the MMU area for SCMI shared buffer on section size; > use the ALIGN macro in mmu_set_region_dcache_behaviour call. > > Since commit d877f8fd0f09 ("arm: provide a function for boards init > code to modify MMU virtual-p

regmap bug fix

2021-03-16 Thread Marek Behun
Simon, Heiko, Bin, Pratyush discovered that the solution implemented by the patch regmap: fix a serious pointer casting bug is wrong. The cpu_to_le32() / le32_to_cpu() shifts data to the correct position, but on big endian machines it also reverses byte order. Somehow this went right through my

Re: [PATCH u-boot v3 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Pratyush Yadav
On 16/03/21 03:15PM, Marek Behun wrote: > On Tue, 16 Mar 2021 19:28:46 +0530 > Pratyush Yadav wrote: > > > On 16/03/21 01:25PM, Marek Behún wrote: > > > There is a serious bug in regmap_read() and regmap_write() functions > > > where an uint pointer is cast to (void *) which is then cast to (u8 *

U-boot : Request for support - Adding more u-boot environment variables to /inlcude/configs/.h does not allow u-boot to start

2021-03-16 Thread Kumar, Naveen AVL/DE
Dear Denx Team, I was facing an issue with uboot when I add more environment variables to #define CONFIG_EXTRA_ENV_SETTINGS in the file /inlcude/configs/.h CASE 1: WORKING When I add fewer env variables CASE 2: HANGS at BL31 before the u-boot is loaded. See logs below: >[ 0.000147] NOTICE: BL

Re: [PATCH u-boot v3 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Marek Behun
On Tue, 16 Mar 2021 20:59:55 +0530 Pratyush Yadav wrote: > On 16/03/21 03:15PM, Marek Behun wrote: > > On Tue, 16 Mar 2021 19:28:46 +0530 > > Pratyush Yadav wrote: > > > > > On 16/03/21 01:25PM, Marek Behún wrote: > > > > There is a serious bug in regmap_read() and regmap_write() functions

Re: [PATCH v2 2/5] configs: Add imx8mm-common header

2021-03-16 Thread Tim Harvey
On Mon, Mar 15, 2021 at 10:46 AM Jagan Teki wrote: > > Move the redundant config item like SPL, memory-related > across all imx8mm config files in the common config header, > imx8mm-common.h > > Verified the built files, seems almost the same as before. > > Cc: Tim Harvey > Cc: Adam Ford > Cc: P

[PATCH v3 0/8] stm32: Add Engicam STM32MP1 SoM

2021-03-16 Thread Jagan Teki
Patch series for Engicam i.Core and MicroGEA SoM and it's associated carrier board dts(i) support. Changes for v3: - collect Patrick Delaunay r-b - fixed comments from Patrick Delaunay Changes for v2: - add Linux dts commit ids in commit messages - drop CONFIG_BOARD_EARLY_INIT_F - order dts files

[PATCH v3 1/8] ARM: dts: stm32: Add Engicam i.Core STM32MP1 SoM

2021-03-16 Thread Jagan Teki
i.Core STM32MP1 is an EDIMM SoM based on STM32MP157A from Engicam. General features: - STM32MP157A - Up to 1GB DDR3L - 4GB eMMC - 10/100 Ethernet - USB 2.0 Host/OTG - I2S - MIPI DSI to LVDS - rest of STM32MP157A features i.Core STM32MP1 needs to mount on top of Engicam baseboards for creating com

[PATCH v3 2/8] ARM: dts: stm32: Add Engicam i.Core STM32MP1 1X4Gb DDR3

2021-03-16 Thread Jagan Teki
Engicam i.Core STM32MP1 SODIMM SoM has mounted 1x4Gb DDR3 which has 32bits width 528000Khz frequency. Add DDR configuration via dtsi. Reviewed-by: Patrick Delaunay Reviewed-by: Patrice Chotard Signed-off-by: Jagan Teki --- Changes for v3: - fixed cosmetic s/Khz/kHz - collect Patrice r-b Chang

[PATCH v3 3/8] ARM: stm32: Imply SPL_SPI_LOAD

2021-03-16 Thread Jagan Teki
SPI Load isn't mandatory for STM32 builds. Let's imply instead of select it to get rid of build issues for non-SPI defconfigs. Reviewed-by: Patrick Delaunay Reviewed-by: Patrice Chotard Signed-off-by: Jagan Teki --- Changes for v3: - add if SPL_SPI_SUPPORT - collect Patrice r-b Changes for v2:

[PATCH v3 4/8] board: stm32: Add Engicam i.Core STM32MP1 EDIMM2.2 Starter Kit

2021-03-16 Thread Jagan Teki
Engicam EDIMM2.2 Starter Kit is an EDIMM 2.2 Form Factor Capacitive Evaluation Board. Genaral features: - LCD 7" C.Touch - microSD slot - Ethernet 1Gb - Wifi/BT - 2x LVDS Full HD interfaces - 3x USB 2.0 - 1x USB 3.0 - HDMI Out - Mini PCIe - MIPI CSI - 2x CAN - Audio Out i.Core STM32MP1 is an EDIM

[PATCH v3 5/8] board: stm32: Add Engicam i.Core STM32MP1 C.TOUCH 2.0

2021-03-16 Thread Jagan Teki
Engicam C.TOUCH 2.0 is an EDIMM compliant general purpose Carrier board. Genaral features: - Ethernet 10/100 - Wifi/BT - USB Type A/OTG - Audio Out - CAN - LVDS panel connector i.Core STM32MP1 is an EDIMM SoM based on STM32MP157A from Engicam. i.Core STM32MP1 needs to mount on top of this Carrie

[PATCH v3 6/8] ARM: dts: stm32: Add Engicam MicroGEA STM32MP1 Micro SoM

2021-03-16 Thread Jagan Teki
MicroGEA STM32MP1 is a STM32MP157A based Micro SoM. General features: - STM32MP157AAC - Up to 1GB DDR3L-800 - 512MB Nand flash - I2S MicroGEA STM32MP1 needs to mount on top of Engicam MicroDev carrier boards for creating complete platform solutions. Linux dts commit details: commit <0be81dfaeaf

[PATCH v3 7/8] board: stm32: Add Engicam MicroGEA STM32MP1 MicroDev 2.0 board

2021-03-16 Thread Jagan Teki
MicroDev 2.0 is a general purpose miniature carrier board with CAN, LTE and LVDS panel interfaces. Genaral features: - Ethernet 10/100 - USB Type A - Audio Out - microSD - LVDS panel connector - Wifi/BT (option) - UMTS LTE with sim connector (option) MicroGEA STM32MP1 is a STM32MP157A based Micro

[PATCH v3 8/8] board: stm32: Add Engicam MicroGEA STM32MP1 MicroDev 2.0 7" OF

2021-03-16 Thread Jagan Teki
7" OF is a capacitive touch 7" Open Frame panel solutions with - 7" AUO B101AW03 LVDS panel - EDT, FT5526 Touch MicroGEA STM32MP1 is a STM32MP157A based Micro SoM. MicroDev 2.0 is a general purpose miniature carrier board with CAN, LTE and LVDS panel interfaces. MicroGEA STM32MP1 needs to mount

[PATCH v2 1/8] riscv: dts: add fu740 support

2021-03-16 Thread Green Wan
Add dts support for fu740. The HiFive Unmatched support is based on fu740 cpu and drivers in following patch set. Signed-off-by: Green Wan Reviewed-by: Bin Meng --- arch/riscv/dts/Makefile | 1 + arch/riscv/dts/fu740-c000-u-boot.dtsi | 105 arch/riscv/dt

[PATCH v2 2/8] riscv: cpu: fu740: Add support for cpu fu740

2021-03-16 Thread Green Wan
Add SiFive fu740 cpu to support RISC-V arch Signed-off-by: Green Wan Reviewed-by: Bin Meng --- arch/riscv/Kconfig| 1 + arch/riscv/cpu/fu740/Kconfig | 37 + arch/riscv/cpu/fu740/Makefile | 12 +++ arch/riscv/cpu/fu740/cac

[PATCH v2 0/8] Add FU740 chip and HiFive Unmatched board support

2021-03-16 Thread Green Wan
This patch set is to add SiFive fu740 chip and HiFive Unmatched board support. Patches are split into several parts: - [PATCH 1/8] dts for fu740 - [PATCH 2/8] support for fu740 cpu - [PATCH 3/8- 5/8] support for fu740 clk and ram - [PATCH 6/8] add pcie driver - [PATCH 7/8] add unmatched

[PATCH v2 4/8] drivers: ram: sifive: rename fu540_ddr to sifive_ddr

2021-03-16 Thread Green Wan
Rename fu540_ddr.c to sifive_ddr.c for supporting both of fu540 and fu740. To avoid 'git mv' info missing, sifive_ddr.c chagnes are included in next patch. Signed-off-by: Green Wan --- drivers/ram/sifive/Kconfig | 6 +- drivers/ram/sifive/Makefile | 2 +- drivers/ram/sifive/fu540_dd

[PATCH v2 5/8] drivers: ram: add fu740 support

2021-03-16 Thread Green Wan
Add fu740 support for ram Signed-off-by: Green Wan --- drivers/ram/sifive/Kconfig | 2 +- drivers/ram/sifive/sifive_ddr.c | 88 - 2 files changed, 45 insertions(+), 45 deletions(-) diff --git a/drivers/ram/sifive/Kconfig b/drivers/ram/sifive/Kconfig

[PATCH v2 8/8] drivers: net: macb: add fu740 support

2021-03-16 Thread Green Wan
From: David Abdurachmanov Add fu740 support to macb ethernet driver Signed-off-by: David Abdurachmanov Signed-off-by: Green Wan Reviewed-by: Ramon Fried --- drivers/net/macb.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/net/macb.c b/drivers/net/macb.c i

[PATCH v2 3/8] drivers: clk: add fu740 support

2021-03-16 Thread Green Wan
Add fu740 support. One abstract layer is added for supporting multiple chips such as fu540 and fu740. Signed-off-by: Green Wan --- drivers/clk/sifive/Kconfig | 8 +- drivers/clk/sifive/Makefile | 4 +- drivers/clk/sifive/fu540-prci.c | 769 ++-

[PATCH v2 6/8] drivers: pci: add pcie support for fu740

2021-03-16 Thread Green Wan
Add pcie driver for SiFive fu740, the driver depends on fu740 gpio, clk and reset driver to do init. Force running at Gen1 for better capatible enumeration. Several devices are tested: a) M.2 NVMe SSD b) USB-to-PCI adapter c) Ethernet adapter (E1000 compatible) Signed-off-by: Green Wan --- driv

Re: [PATCH u-boot v3.1 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Pratyush Yadav
Hi Marek, On 16/03/21 04:07PM, Marek Behún wrote: > There is a serious bug in regmap_read() and regmap_write() functions > where an uint pointer is cast to (void *) which is then cast to (u8 *), > (u16 *), (u32 *) or (u64 *), depending on register width of the map. > > For example given a regmap

Re: Pull request for efi-2021-04-rc5

2021-03-16 Thread Tom Rini
On Tue, Mar 16, 2021 at 12:34:42PM +0100, Heinrich Schuchardt wrote: > Dear Tom, > > The following changes since commit 4103e13534141c31e4e9bf40848ab3a61dabce81: > > Prepare v2021.04-rc4 (2021-03-15 12:06:41 -0400) > > are available in the Git repository at: > > https://source.denx.de/u-bo

Re: [PATCH u-boot v3.1 01/39] regmap: fix a serious pointer casting bug

2021-03-16 Thread Marek Behun
On Tue, 16 Mar 2021 22:04:17 +0530 Pratyush Yadav wrote: > > + switch (map->width) { > > + case REGMAP_SIZE_8: > > + *valp = u.v8; > > + break; > > + case REGMAP_SIZE_16: > > + *valp = u.v16; > > + break; > > + case REGMAP_SIZE_32: > > + *

[PATCH] efi_loader: NULL dereference in EFI console

2021-03-16 Thread Heinrich Schuchardt
Even if CONFIG_DM_VIDEO=y and stdout="vidconsole" a video device may not be available. Check the return values of the relevant functions. If no video output device is available, assume that the serial console is in use. Signed-off-by: Heinrich Schuchardt --- lib/efi_loader/efi_console.c | 51 ++

Re: [PATCH] arm: omap3: Make try_unlock_memory() static

2021-03-16 Thread Adam Ford
On Mon, Mar 15, 2021 at 1:43 AM Lokesh Vutla wrote: > > > > On 07/03/21 9:23 am, Adam Ford wrote: > > try_unlock_memory() is only used in one file, so make it static > > in that file and remove it from the sys_proto header file. This > > may help with some further optimization in the future. > > >

Re: [PATCH] arm: omap3: Make try_unlock_memory() static

2021-03-16 Thread Tom Rini
On Tue, Mar 16, 2021 at 12:18:05PM -0500, Adam Ford wrote: > On Mon, Mar 15, 2021 at 1:43 AM Lokesh Vutla wrote: > > > > > > > > On 07/03/21 9:23 am, Adam Ford wrote: > > > try_unlock_memory() is only used in one file, so make it static > > > in that file and remove it from the sys_proto header fi

[PATCH v2 7/8] board: sifive: add HiFive Unmatched board support

2021-03-16 Thread Green Wan
Add dts, defconfig and board support for HiFive Unmatched. Signed-off-by: Green Wan --- arch/riscv/Kconfig |4 + arch/riscv/dts/fu740-hifive-unmatched-a00-ddr.dtsi | 1489 arch/riscv/dts/hifive-unmatched-a00-u-boot.dtsi| 40 + arch/r

[PATCH] ahci: mediatek: fix undefined reference of dev_err

2021-03-16 Thread Frank Wunderlich
From: Frank Wunderlich building with MTK_AHCI enabled results in implicit declaration and undefined reference of dev_err followed by a segfault of gcc drivers/ata/mtk_ahci.c: In function 'mtk_ahci_parse_property': drivers/ata/mtk_ahci.c:65:4: warning: implicit declaration of function 'dev_err' d

Re: Flaky EFI test

2021-03-16 Thread Heinrich Schuchardt
On 16.03.21 02:57, Bin Meng wrote: > On Tue, Mar 16, 2021 at 3:08 AM Tom Rini wrote: >> >> On Tue, Mar 16, 2021 at 07:23:23AM +1300, Simon Glass wrote: >> >>> Hi Heinrich, >>> >>> This job failed: >>> >>> https://source.denx.de/u-boot/custodians/u-boot-sh/-/jobs/238476 >>> >>> Do you think this is

Re: [PATCH 1/6 v3] efi_selftest: Remove loadfile2 for initrd selftests

2021-03-16 Thread Heinrich Schuchardt
On 3/14/21 8:05 PM, Ilias Apalodimas wrote: We are redefining how u-boot locates the initrd to load via the kernel LoadFile2 protocol. This selftest is not relevant any more, so remove it. A new one will be added later Signed-off-by: Ilias Apalodimas Reviewed-by: Heinrich Schuchardt Applied

Re: [PATCH 5/6 v3] efidebug: add multiple device path instances on Boot####

2021-03-16 Thread Heinrich Schuchardt
On 3/14/21 8:05 PM, Ilias Apalodimas wrote: The UEFI spec allows a packed array of UEFI device paths in the FilePathList[] of an EFI_LOAD_OPTION. The first file path must describe the loaded image but the rest are OS specific. Previous patches parse the device path and try to use the second memb

[PATCH 1/1] imx6: icorem6: chmod 644 enigcam.bmp

2021-03-16 Thread Heinrich Schuchardt
Bitmap files should not be executable. Signed-off-by: Heinrich Schuchardt --- tools/logos/engicam.bmp | Bin 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 tools/logos/engicam.bmp diff --git a/tools/logos/engicam.bmp b/tools/logos/engicam.bmp old mode 100755 new m

  1   2   >