Re: [PATCH v1 0/7] Add Starfive JH7110 Cadence USB driver

2024-05-19 Thread Minda Chen
> -邮件原件- > 发件人: E Shattow > 发送时间: 2024年5月20日 13:06 > 收件人: Minda Chen > 抄送: Marek Vasut ; Tom Rini ; Roger > Quadros ; Neil Armstrong ; > Alexey Romanov ; Sumit Garg > ; Mark Kettenis ; Nishanth > Menon ; Rick Chen ; Leo Yu-Chi Liang > ; u-boot@lists.denx.de; Heinrich Schuchardt > ; Simo

Re: [PATCH RFC 3/4] pwm: sunxi: Add support Allwinner D1 PWM

2024-05-19 Thread John Watts
After a long time reading the datasheet I found out my approach was actually wrong and led to an off by on error. Signed-off-by: John Watts --- drivers/pwm/sunxi_pwm_d1.c | 57 +- 1 file changed, 32 insertions(+), 25 deletions(-) diff --git a/drivers/pwm/sunx

Re: [PATCH RFC 3/4] pwm: sunxi: Add support Allwinner D1 PWM

2024-05-19 Thread John Watts
After a long time reading the datasheet I found out my approach was actually wrong and led to an off by on error. Signed-off-by: John Watts --- drivers/pwm/sunxi_pwm_d1.c | 57 +- 1 file changed, 32 insertions(+), 25 deletions(-) diff --git a/drivers/pwm/sunx

Re: [PATCH v2 10/10] arch: arm: dts: k3-am62-sk-u-boot: Add missing "bootph-all" property to phy_gmii_sel node

2024-05-19 Thread Chintan Vankar
On 25/04/24 18:06, Chintan Vankar wrote: On 25/04/24 18:01, Roger Quadros wrote: On 25/04/2024 15:08, Chintan Vankar wrote: Add "bootph-all" property to CPSW MAC's PHY node phy_gmii_sel. Signed-off-by: Chintan Vankar --- Changes from v1 to v2: - This patch is newly added in this serie

Re: [PATCH v1 0/7] Add Starfive JH7110 Cadence USB driver

2024-05-19 Thread E Shattow
Hi, there is a compile warning. I don't know why. On Sat, May 4, 2024 at 8:04 AM Minda Chen wrote: > > Add Starfive JH7110 Cadence USB driver and related PHY driver. > So the codes can be used in visionfive2 and milkv 7110 board. > > The driver is almost the same with kernel driver. > > patch1: A

[PATCH 2/2 v4] board: starfive: support Pine64 Star64 board

2024-05-19 Thread H Bell
Add documentation files Signed-off-by: Henry Bell Cc: ycli...@andestech.com Cc: heinrich.schucha...@canonical.com --- Changes since v1 - New patch Changes since v2 - Remove extra params to - Clarification on boot section - Add entry on MAC adresses and how to correct them Changes since v3 -

[PATCH 1/2 v4] board: starfive: support Pine64 Star64 board

2024-05-19 Thread H Bell
Similar to the Milk-V Mars, The Star64 board contains few differences to the VisionFive 2 boards, so can be part of the same U-boot build. Signed-off-by: Henry Bell Cc: ycli...@andestech.com Cc: heinrich.schucha...@canonical.com --- Changes since v1 - Fix typos on naming - Create pine64_star64

Re: [PATCH v2 5/8] drivers: ram: Kconfig: Add CONFIG_K3_INLINE_ECC

2024-05-19 Thread Neha Malcom Francis
Hi Andrew On 15/05/24 21:37, Andrew Davis wrote: On 5/10/24 3:47 AM, Santhosh Kumar K wrote: From: Neha Malcom Francis Add CONFIG_K3_INLINE_ECC so that ECC functions can be compiled into R5 SPL only when the config has been enabled. Signed-off-by: Neha Malcom Francis ---   drivers/ram/Kconf

Re: [PATCH v3 11/12] MIPS: boston: Migrate to OF_UPSTREAM

2024-05-19 Thread Tom Rini
On Sun, May 19, 2024 at 09:57:03PM +0100, Jiaxun Yang wrote: > > > 在2024年5月19日五月 下午7:20,Daniel Schwierzeck写道: > > > > Reviewed-by: Daniel Schwierzeck > > > Hi Daniel, > > Thanks for reviewing the series. > > > [...] > > > > should be 'select' because the switch to upstream DTS is permanent and

Re: [PATCH v3 11/12] MIPS: boston: Migrate to OF_UPSTREAM

2024-05-19 Thread Jiaxun Yang
在2024年5月19日五月 下午7:20,Daniel Schwierzeck写道: > > Reviewed-by: Daniel Schwierzeck > Hi Daniel, Thanks for reviewing the series. > [...] > > should be 'select' because the switch to upstream DTS is permanent and > it does not make sense for the user to be able to deselect this option > Do you wa

[PATCH 10/10] doc: New documentation for qemu-xtensa

2024-05-19 Thread Jiaxun Yang
Introduce the board and provide instructions on how to get it work. Signed-off-by: Jiaxun Yang --- doc/board/emulation/index.rst | 1 + doc/board/emulation/qemu-xtensa.rst | 33 + 2 files changed, 34 insertions(+) diff --git a/doc/board/emulation/index.rst

[PATCH 09/10] board: emulation: New board qemu-xtensa

2024-05-19 Thread Jiaxun Yang
Introduce the new board, define every bits. Signed-off-by: Jiaxun Yang --- arch/xtensa/Kconfig | 5 +++ board/emulation/qemu-xtensa/Kconfig | 41 + board/emulation/qemu-xtensa/MAINTAINERS | 7 board/emulation/qemu-xtensa/Makefile | 5

[PATCH 08/10] dts/upsteam: Add Makefile for xtensa

2024-05-19 Thread Jiaxun Yang
It is required to get it xtensa OF_UPSTREAM work. Signed-off-by: Jiaxun Yang --- dts/upstream/src/xtensa/Makefile | 14 ++ 1 file changed, 14 insertions(+) diff --git a/dts/upstream/src/xtensa/Makefile b/dts/upstream/src/xtensa/Makefile new file mode 100644 index ..2a81a

[PATCH 07/10] drivers: cpu: Add xtensa CPU driver

2024-05-19 Thread Jiaxun Yang
Implement various CPU related functions. I'm actually just using it to get cpu clock frequency. Signed-off-by: Jiaxun Yang --- drivers/cpu/Kconfig | 6 +++ drivers/cpu/Makefile | 1 + drivers/cpu/xtensa_cpu.c | 117 +++ 3 files changed, 12

[PATCH 06/10] drivers: serial: Add xtensa semihosting driver

2024-05-19 Thread Jiaxun Yang
Add xtensa semihosting driver. It can't use regular semihosting driver as Xtensa's has it's own semihosting ABI. Note that semihosting supports puts in serial but I never managed to get it work, so it's putc only for now. Signed-off-by: Jiaxun Yang --- drivers/serial/Kconfig

[PATCH 05/10] xtensa: Bring in semihosting headers and config options

2024-05-19 Thread Jiaxun Yang
They are all directly imported from Linux kernel. Signed-off-by: Jiaxun Yang --- arch/xtensa/Kconfig | 27 ++ arch/xtensa/include/asm/platform/simcall-gdbio.h | 34 +++ arch/xtensa/include/asm/platform/simcall-iss.h | 73 +++ arch/xtensa/incl

[PATCH 04/10] xtensa: Define PLATFORM_ELFFLAGS

2024-05-19 Thread Jiaxun Yang
u-boot.elf target requiures it to work. Signed-off-by: Jiaxun Yang --- arch/xtensa/config.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/xtensa/config.mk b/arch/xtensa/config.mk index b080e403..3ec936272f25 100644 --- a/arch/xtensa/config.mk +++ b/arch/xtensa/config.mk @@ -7,

[PATCH 02/10] xtensa: Correct define of _end symbol

2024-05-19 Thread Jiaxun Yang
So U-Boot is using _end symbol to detect location of devicetree appended at the end of the ROM. It needs to be calculated based on end of .data load address, as in our lds .current address is address in RAM. Signed-off-by: Jiaxun Yang --- arch/xtensa/cpu/u-boot.lds | 2 ++ arch/xtensa/i

[PATCH 03/10] xtensa: Implement phys virt conversion for PTP_MMU

2024-05-19 Thread Jiaxun Yang
For PTP_MMU our physical address is not directly mapped into virtual address space, we need to access physical memory from those fixed map segments. Implement phys_to_virt and virt_to_phys hook to reflect this setting. Signed-off-by: Jiaxun Yang --- arch/xtensa/include/asm/addrspace.h | 2 ++

[PATCH 00/10] xtensa: Enable qemu-xtensa board

2024-05-19 Thread Jiaxun Yang
src/xtensa/Makefile | 14 +++ include/configs/qemu-xtensa.h| 34 +++ 26 files changed, 741 insertions(+), 7 deletions(-) --- base-commit: 3be9f399e911cfc437a37ac826441f1d96da1c9b change-id: 20240519-qemu-xtensa-5fb95bb474e9 Best regards, -- Jiaxun Yang

[PATCH 01/10] xtensa: Move dram_init to xtfpga board file

2024-05-19 Thread Jiaxun Yang
This is a board level stuff. Signed-off-by: Jiaxun Yang --- arch/xtensa/cpu/cpu.c | 5 - board/cadence/xtfpga/xtfpga.c | 5 + 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/arch/xtensa/cpu/cpu.c b/arch/xtensa/cpu/cpu.c index abcd8f7984fa..d2266812229c 100644 --- a

[PATCH] ARM: dts: renesas: Reserve space in 64bit R-Car DTs

2024-05-19 Thread Marek Vasut
Reserve 4 kiB of space in 64bit R-Car DTs when those DTs are compiled to permit patching in OpTee-OS /firmware node, /reserved-memory node, possibly also additional /memory@ nodes and RPC node by TFA. This duplicates behavior in arch/arm/dts/Makefile with OF_UPSTREAM. Signed-off-by: Marek Vasut

[PATCH] ARM: dts: renesas: Remove leftovers after OF_UPSTREAM conversion

2024-05-19 Thread Marek Vasut
Remove leftover DTSI files after OF_UPSTREAM conversion. Those are no longer used and no longer necessary, remove them. No functional change. Signed-off-by: Marek Vasut --- Cc: Adam Ford Cc: Tom Rini --- arch/arm/dts/salvator-common.dtsi| 1104 -- arch/arm/dts/salva

[PATCH v3 3/3] cyclic: make clients embed a struct cyclic_info in their own data structure

2024-05-19 Thread Rasmus Villemoes
There are of course not a whole lot of examples in-tree yet, but before they appear, let's make this API change: Instead of separately allocating a 'struct cyclic_info', make the users embed such an instance in their own structure, and make the convention that the callback simply receives the 'stru

[PATCH v3 0/3] cyclic/watchdog patches

2024-05-19 Thread Rasmus Villemoes
A bit of a mixed bag. I've been wanting to submit something like 3/3 for a while. So when I stumbled on Marek's patch https://lore.kernel.org/u-boot/20240316201416.211480-1-marek.vasut+rene...@mailbox.org/ , I got reminded of that plan, and I think that patch could be more readable if we adopt this

[PATCH v3 2/3] wdt-uclass: prevent multiple cyclic_register calls

2024-05-19 Thread Rasmus Villemoes
Currently, the cyclic_register() done in wdt_start() is not undone in wdt_stop(). Moreover, calling wdt_start multiple times (which is perfectly allowed on an already started device, e.g. to change the timeout value) will result in another struct cyclic_info being registered, referring to the same

[PATCH v3 1/3] cyclic: stop strdup'ing name in cyclic_register()

2024-05-19 Thread Rasmus Villemoes
We are not checking the return value of strdup(), nor freeing the string in cyclic_unregister(). However, all current users either pass a string literal or the dev->name of the client device. So in all cases the name string will live at least as long as the cyclic_info is registered, so just make

Re: [PATCH v2 3/3] cyclic: make clients embed a struct cyclic_info in their own data structure

2024-05-19 Thread Rasmus Villemoes
On 18/05/2024 09.34, Stefan Roese wrote: > This introduces some problems when compiling e.g. sandbox: > > In file included from test/common/cyclic.c:10: > test/common/cyclic.c: In function ‘dm_test_cyclic_running’: > test/common/cyclic.c:25:42: warning: passing argument 1 of > ‘cyclic_register’ f

[PATCH 3/3] abootimg: Implement smart image load feature

2024-05-19 Thread Roman Stratiienko
Load only part of the boot partition that contains valuable information, thus improving the boot time. Signed-off-by: Roman Stratiienko --- boot/image-android.c | 70 cmd/abootimg.c | 40 ++--- include/image.h | 12 +

[PATCH 2/3] avb: Implement get_preloaded_partition callback

2024-05-19 Thread Roman Stratiienko
AVB can reuse already loaded images instead of loading them from the disk. The get_preloaded_partition now looks for the env. variables set by the 'abootimg load' to find the correct partition in RAM. Signed-off-by: Roman Stratiienko --- common/avb_verify.c | 53

[PATCH 1/3] abootcmd: Add load subcommand

2024-05-19 Thread Roman Stratiienko
What it does: 1. Allocates the memory in HEAP to fit the partition 2. Loads partition into memory. In the following patch of this series, loading will be optimized to avoid loading an empty space. 3. Sets buffer start and buffer size value into environment variables abootimg__ptr and abootimg

[PATCH 0/3] Android partition load optimization

2024-05-19 Thread Roman Stratiienko
This series offers an optimization of the Android image loading procedure. The first patch introduces a new 'abootimg load' command, which loads partitions from storage into memory. It uses malloc() to find a free memory region, whereas previously, the developer had to find a free memory region by

[PATCH 2/2 v3] board: starfive: support Pine64 Star64 board

2024-05-19 Thread H Bell
Add documentation files Signed-off-by: Henry Bell Cc: ycli...@andestech.com Cc: heinrich.schucha...@canonical.com --- Changes since v1 - New patch Changes since v2 - Remove extra params to - Clarification on boot section - Add entry on MAC adresses and how to correct them --- doc/board/starf

[PATCH 1/2 v3] board: starfive: support Pine64 Star64 board

2024-05-19 Thread H Bell
Similar to the Milk-V Mars, The Star64 board contains few differences to the VisionFive 2 boards, so can be part of the same U-boot build. Signed-off-by: Henry Bell Cc: ycli...@andestech.com Cc: heinrich.schucha...@canonical.com --- Changes since v1 - Fix typos on naming - Create pine64_star64

Re: [PATCH v3 12/12] mailmap: Update email for Paul Burton

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:15, Jiaxun Yang wrote: Paul had left MIPS a couple of years ago, his email address is no longer valid. Replace it with his kenrel.org email, which has been used in kernel and QEMU, in case we still want to reach him. Signed-off-by: Jiaxun Yang --- .mailmap

Re: [PATCH v3 11/12] MIPS: boston: Migrate to OF_UPSTREAM

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: We can now boot with upstream devicetree. Reviewed-by: Sumit Garg Signed-off-by: Jiaxun Yang --- arch/mips/Kconfig| 1 + arch/mips/dts/Makefile | 1 - arch/mips/dts/boston-u-boot.dtsi | 10 ++ arch/mips/dts/img,boston.

Re: [PATCH v3 10/12] dts/upstream: Add Makefile for MIPS

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: It is required to make OF_UPSTREAM work. Reviewed-by: Sumit Garg Signed-off-by: Jiaxun Yang --- dts/upstream/src/mips/Makefile | 14 ++ 1 file changed, 14 insertions(+) Reviewed-by: Daniel Schwierzeck

Re: [PATCH v3 09/12] clk: boston: Allow to get regmap from parent device

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: In upstream devicetree, clk_boston is a child of syscon node and there is no "regmap" property for clk_boston node. Try to check parent device first to look for syscon. Signed-off-by: Jiaxun Yang --- v2: Move syscon_get_regmap to probe v3: Move syscon de

Re: [PATCH v3 08/12] MIPS: boston: Provide default env vars

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: Provide default environment variables on image loading address to make the board useful. Signed-off-by: Jiaxun Yang --- board/imgtec/boston/Kconfig| 4 board/imgtec/boston/boston.env | 9 + 2 files changed, 13 insertions(+) Reviewe

Re: [PATCH v3 07/12] MIPS: boston: Imply various options

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: This is a PC-like platform board. Enable drivers for most on-board devices to make it useful. Signed-off-by: Jiaxun Yang --- arch/mips/Kconfig | 27 +++ 1 file changed, 27 insertions(+) Reviewed-by: Daniel Schwierzeck

Re: [PATCH v3 06/12] MIPS: Provide dummy acpi_table.h

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: Some drivers need this header. Provide this dummy header as riscv did. Signed-off-by: Jiaxun Yang --- arch/mips/include/asm/acpi_table.h | 10 ++ 1 file changed, 10 insertions(+) Reviewed-by: Daniel Schwierzeck

Re: [PATCH v3 03/12] pci: Enable PCI_MAP_SYSTEM_MEMORY when ARCH_MAP_SYSMEM is not set

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: For MIPS we are always looking gd->dram in virtual address so PCI_MAP_SYSTEM_MEMORY should always be enabled. If in future we ever want to make it physical we have to set ARCH_MAP_SYSMEM. Signed-off-by: Jiaxun Yang --- drivers/pci/Kconfig | 1 + 1 fil

Re: [PATCH v3 02/12] pci: auto: Reduce bridge mem alignment boundary for boston

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: Boston has a very limited memory range for PCI controllers, where 1MB can't easily fit into it. Make alignment boundary of PCI memory resource allocation a Kconfig option and default to 0x1 for boston. Signed-off-by: Jiaxun Yang --- drivers/pci/Kco

Re: [PATCH v3 01/12] pci: xilinx: Handle size of ecam region properly

2024-05-19 Thread Daniel Schwierzeck
On 5/17/24 20:14, Jiaxun Yang wrote: Probe size of ecam from devicetree properly and cap accessible bus number accorading to ecam region size to ensure we don't go beyond hardware address space. Also disable all interrupts to ensure errors are handled silently. Signed-off-by: Jiaxun Yang --

[PATCH] part: efi: Rely on a definition to specify the primary GPT position

2024-05-19 Thread Roman Stratiienko
Use GPT_PRIMARY_PARTITION_TABLE_LBA as the only source for a primary GPT location instead of hardcoding it every time. Sometimes, we need to shift the primary GPT location. Having the location in the single place simplifies such shifting. Signed-off-by: Roman Stratiienko --- disk/part_efi.c | 1

[PATCH 4/4] riscv: dts: sophgo: Replace device clocks with real clocks.

2024-05-19 Thread Kongyang Liu
Replace device clocks with real clocks from the clock controller, and remove dummy clocks. Signed-off-by: Kongyang Liu --- arch/riscv/dts/cv18xx.dtsi | 40 +++--- 1 file changed, 16 insertions(+), 24 deletions(-) diff --git a/arch/riscv/dts/cv18xx.dtsi b/arch/ri

[PATCH 2/4] clk: sophgo: cv1800b: Add clock controller driver for cv1800b SoC

2024-05-19 Thread Kongyang Liu
Add clock controller driver for sophgo cv1800b SoC Signed-off-by: Kongyang Liu --- drivers/clk/Kconfig | 1 + drivers/clk/Makefile | 1 + drivers/clk/sophgo/Kconfig | 14 + drivers/clk/sophgo/Makefile | 6 + drivers/clk/sophgo/clk-common.h | 74 +++

[PATCH 3/4] configs: milkv_duo: Enable clock controller

2024-05-19 Thread Kongyang Liu
Add configs to enable clock controller for Sophgo Milk-V Duo board Signed-off-by: Kongyang Liu --- configs/milkv_duo_defconfig | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/configs/milkv_duo_defconfig b/configs/milkv_duo_defconfig index 0cb2922de4..1186763a73 1006

[PATCH 1/4] dt-bindings: clk: import header for clock controller of sophgo CV1800B

2024-05-19 Thread Kongyang Liu
Import header file of sophgo cv1800b clock controller from kernel Signed-off-by: Kongyang Liu Link: https://lore.kernel.org/all/ia1pr20mb4953637e7a6c121d7a700f1cbb...@ia1pr20mb4953.namprd20.prod.outlook.com/ --- include/dt-bindings/clock/sophgo,cv1800.h | 176 ++ 1 file ch

[PATCH 0/4] clk: sophgo: milkv_duo: Add and enable clock controller driver

2024-05-19 Thread Kongyang Liu
This series of patches introduces the clock controller driver for the Sophgo CV1800B SoC, updates the device tree sources to use the new clock controller, and enables the clock controller in the configuration for the Milk-V Duo board. Kongyang Liu (4): dt-bindings: clk: import header for clock

[PATCH] android: Fix ramdisk loading for bootimage v3+

2024-05-19 Thread Roman Stratiienko
The boot_ramdisk and vendor_ramdisk must be both concatenated together. Without this change, Android root is missing some of the necessary tools to complete virtual AB OTA. Signed-off-by: Roman Stratiienko --- boot/image-android.c | 17 - 1 file changed, 8 insertions(+), 9 deleti

[PATCH 13/13] qemu-arm: Big endian enablement for arm64

2024-05-19 Thread Jiaxun Yang
Select a few config option and generate a new defconfig for big endian arm64. Signed-off-by: Jiaxun Yang --- board/emulation/qemu-arm/Kconfig | 2 + board/emulation/qemu-arm/MAINTAINERS | 1 + configs/qemu_arm64be_defconfig | 71 doc/board/emulati

[PATCH 12/13] config: Use CONFIG_SYS_BIG_ENDIAN in code whenever possible

2024-05-19 Thread Jiaxun Yang
So CONFIG_SYS_BIG_ENDIAN is our cross architecture option for selecting machine endian, while the old CONFIG_CPU_BIG_ENDIAN is defined by Arc only. Use it whenever possible to ensure big endian code path is enabled for all possible big endian machines. Signed-off-by: Jiaxun Yang --- Makefile

[PATCH 11/13] Kconfig: Unify endian support option

2024-05-19 Thread Jiaxun Yang
Move SUPPORT_BIG_ENDIAN, SUPPORT_LITTLE_ENDIAN to top-level arch Kconfig and let architectures select them as necessary. Remove if guard for Endianness selection choice so we can have one of SYS_BIG_ENDIAN, SYS_LITTLE_ENDIAN config symbol defined even on single endian system. Default endian to SY

[PATCH 10/13] lib/crc32: Don't perform byte swap for arm64 crc32b

2024-05-19 Thread Jiaxun Yang
crc32b always calculate results in CPU's native endian, so there is no need to perform any endian swap. Signed-off-by: Jiaxun Yang --- lib/crc32.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/crc32.c b/lib/crc32.c index f36f1763064f..b991e477b31d 100644 --- a/lib/crc

[PATCH 09/13] armv8: spin_table: Perform byte swap for jump address

2024-05-19 Thread Jiaxun Yang
Address comes from spin table is always little endian. Signed-off-by: Jiaxun Yang --- arch/arm/cpu/armv8/spin_table_v8.S | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/cpu/armv8/spin_table_v8.S b/arch/arm/cpu/armv8/spin_table_v8.S index 6d268432702f..023c82261ca6 100644 --- a/ar

[PATCH 08/13] armv8: Allow endianness to be setted at reset entry

2024-05-19 Thread Jiaxun Yang
Provide a option to allow Endian at U-Boot's EL to be setted at reset entry. Signed-off-by: Jiaxun Yang --- arch/arm/cpu/armv8/Kconfig | 9 + arch/arm/cpu/armv8/start.S | 26 ++ 2 files changed, 35 insertions(+) diff --git a/arch/arm/cpu/armv8/Kconfig b/arch/arm

[PATCH 07/13] arm: Perform byte swap for read and write in io.h

2024-05-19 Thread Jiaxun Yang
I/O is always assumed little endian, so perform byte swap if necessary, as what Linux did. Signed-off-by: Jiaxun Yang --- arch/arm/include/asm/io.h | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm/include/asm/io.h b/arch/arm/include/asm/io.h index 89b1015

[PATCH 06/13] armv8: Big Endian enablement for compiler and linker

2024-05-19 Thread Jiaxun Yang
Pass flags to compilers and linkers, also modify linker scripts to set correct output format. Signed-off-by: Jiaxun Yang --- arch/arm/config.mk| 14 ++ arch/arm/cpu/armv8/u-boot-spl.lds | 6 ++ arch/arm/cpu/armv8/u-boot.lds | 4 arch/arm/lib/elf_aarch64

[PATCH 05/13] arm: Define endian related bits in system.h

2024-05-19 Thread Jiaxun Yang
So they can be used at a later point. Signed-off-by: Jiaxun Yang --- arch/arm/include/asm/system.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h index 43f7503571d7..886a9ffbee35 100644 --- a/arch/arm/include/asm/system.h +++

[PATCH 04/13] arm: Introduce CPU_LE/CPU_BE macros

2024-05-19 Thread Jiaxun Yang
They come from the same header in Linux. They are used to conditional select code on different endianness. Signed-off-by: Jiaxun Yang --- arch/arm/include/asm/assembler.h | 18 ++ 1 file changed, 18 insertions(+) diff --git a/arch/arm/include/asm/assembler.h b/arch/arm/include/a

[PATCH 03/13] arm: Fix assembler.h for arm64

2024-05-19 Thread Jiaxun Yang
Header guard is missing, and ret macro is not relevant for arm64. Both fixed. Signed-off-by: Jiaxun Yang --- arch/arm/include/asm/assembler.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/arch/arm/include/asm/assembler.h b/arch/arm/include/asm/assembler.h index 4fda483b8d8d..c3b8f3

[PATCH 02/13] arm: Don't select ARM_ASM_UNIFIED on arm64

2024-05-19 Thread Jiaxun Yang
We don't have thumb on arm64, so that's pointless and causing problems on some headers. Signed-off-by: Jiaxun Yang --- arch/arm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 39ad03acd2e4..46c0d33b3c6e 100644 --- a/arch/arm

[PATCH 01/13] tools/relocate-rela: Fix Big Endian elf64 handling

2024-05-19 Thread Jiaxun Yang
Implement elf64_to_cpu and use it when necessary. Signed-off-by: Jiaxun Yang --- tools/relocate-rela.c | 40 1 file changed, 24 insertions(+), 16 deletions(-) diff --git a/tools/relocate-rela.c b/tools/relocate-rela.c index 613abd25ef46..cbdd2552ec6e 100

[PATCH 00/13] Arm64 big endian enablement

2024-05-19 Thread Jiaxun Yang
Hi all, This series enabled big endian support for arm64, enabled qemu-arm board for arm64be and slightly adjusted our Kconfig handling on endianness. In practical I think most Arm SoCs do support little endian only, for those SoCs with big endian support they are usually bi-endian and expected b

[PATCH] abootimg: Add init_boot image support

2024-05-19 Thread Roman Stratiienko
Quote from [1]: "For devices launching with Android 13, the generic ramdisk is removed from the boot image and placed in a separate init_boot image. This change leaves the boot image with only the GKI kernel." [1]: https://source.android.com/docs/core/architecture/partitions/generic-boot Signed-o