Add UEFI supplement document to define some behaviours
on architectures not covered by the original specification.
Signed-off-by: Jiaxun Yang
---
Hi all,
This document is in response to discussion at [1]. It is produced
based on my attempt to port U-Boot UEFI to MIPS and Xtensa. I also
plan
在2024年5月21日五月 下午7:15,Tom Rini写道:
[...]
>
> We have long not done a great job with the U-Boot standalone API stuff,
> and for a number of years at this point a lot of the use cases it was
> used for could instead be filled by making an EFI application. There's a
> well defined API there, there's
to reflect this
nature.
Signed-off-by: Jiaxun Yang
---
v2:
- Remove an unused variable
---
include/efi_api.h| 1 +
lib/efi_loader/efi_gop.c | 8 +++-
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/efi_api.h b/include/efi_api.h
index ab40b1b5ddf6
This driver is implemened based on latest VirtIO spec.
It follows operation prodcure as defined in the spec.
It implemented multihead (mirroring) support as well.
Signed-off-by: Jiaxun Yang
---
v2:
- Add big endian code path
- Reword typical resolution for Kconfig symbol
as a vidconsole. My current
appraoch is to register virtio_init in init_sequence_r, just after
pci_init. Is this a viable approach? Should I introduce a config
like CONFIG_VIRTIO_INIT_R to allow it to be selected by boards?
Thanks
Signed-off-by: Jiaxun Yang
---
Changes in v2:
- Fix left over in previous
在2024年5月23日五月 下午5:26,Heinrich Schuchardt写道:
>> diff --git a/arch/loongarch/lib/reloc_loongarch_efi.c
>> b/arch/loongarch/lib/reloc_loongarch_efi.c
>> new file mode 100644
>> index ..32a7d792103d
>> --- /dev/null
>> +++ b/arch/loongarch/lib/reloc_loongarch_efi.c
>
> The code seems
在2024年5月23日五月 下午5:14,Heinrich Schuchardt写道:
[...]
> Looking at
> https://loongson.github.io/LoongArch-Documentation/LoongArch-toolchain-conventions-EN.html:
>
> There the following symbols are mentioned:
>
> __loongarch__
> __loongarch_grlen
>
>
> Table 15.
> C/C++ Built-in Macros Provided for
在2024年5月23日五月 下午4:25,Tom Rini写道:
> On Wed, May 22, 2024 at 04:34:43PM +0100, Jiaxun Yang wrote:
>
>> Hi all,
>>
>> Sorry for flooding the mailing list recently, yet another huge RFC series
>> ahead.
>>
>> So after working on MIPS, arm64be and Xte
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
Introduce the new board, define every bits.
Signed-off-by: Jiaxun Yang
---
v2:
- Fix maintainers entries
- Refine address mapping for noMMU machine
- Add a dtsi overlay to describe different memory size for noMMU system
---
arch/xtensa/Kconfig | 5
It is required to get it xtensa OF_UPSTREAM work.
Reviewed-by: Sumit Garg
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
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
Add xtensa semihosting driver.
It can't use regular semihosting driver as Xtensa's has it's own
semihosting ABI.
Signed-off-by: Jiaxun Yang
---
v2:
- Fix simc_serial_pending implementation
- Get puts work
---
drivers/serial/Kconfig | 18 +-
drivers
They are all directly imported from Linux kernel.
Reviewed-by: Max Filippov
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
u-boot.elf target requires it to work.
Signed-off-by: Jiaxun Yang
---
v2:
- Concerning big endian CPU
Note: CONFIG_SYS_BIG_ENDIAN will never be set for xtensa
for now, but as we don't have big endian headers for xtensa
core either I think it's fine for now. This will be improved
after
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
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
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
-xtensa-dc232b-elf.tar.gz
Signed-off-by: Jiaxun Yang
---
Changes in v2:
- Fix noMMU memory mappings
- Addressing Max's comments in other patches
- Link to v1:
https://lore.kernel.org/r/20240519-qemu-xtensa-v1-0-8fff0cb11...@flygoat.com
---
Jiaxun Yang (10):
xtensa: Move dram_init to xtfpga
Commit for directories, Kconfig, Makefile and headers
Some of them are copied from linux, some of them are derived
from other architectures, the rest are wriiten on my own.
Signed-off-by: Jiaxun Yang
---
arch/Kconfig | 15 +
arch/loongarch/Kconfig
Implement crt, reloc, linker scripts, wire things up in
Makefiles and Kconfig.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/config.mk | 4 +
arch/loongarch/lib/Makefile | 12 ++
arch/loongarch/lib/crt0_loongarch_efi.S | 182 +++
arch
They are all coming from UEFI spec, Microsoft PE sepc,
or IANA websites.
Signed-off-by: Jiaxun Yang
---
boot/bootmeth_efi.c | 2 ++
include/asm-generic/pe.h | 2 ++
include/config_distro_bootcmd.h | 5 +
include
Yet another generic QEMU VIRT machine.
QEMU placed FDT in memory before launching U-Boot, so we
can just obtian FDT here.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/Kconfig| 5 ++
arch/loongarch/dts/qemu-loongarch64.dts | 9 +++
board/emulation/qemu
Implement a timer driver for LoongArch architecture driver.
It's synced in hardware for every core in a system, and frequency
information can be gathered from CPUCFG instruction.
It is not described in fdt, thus I have to declare a DRVINFO
for it.
Signed-off-by: Jiaxun Yang
---
drivers/timer
Implement a driver for LoongArch CPU solely for gathering
some information bits from FDT and CPU level config registers.
Signed-off-by: Jiaxun Yang
---
drivers/cpu/Kconfig | 6 ++
drivers/cpu/Makefile| 1 +
drivers/cpu/loongarch_cpu.c | 148
Provide a generic CPU type with some common routines
that expected to be implemented at CPU level.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/Kconfig | 1 +
arch/loongarch/cpu/generic/Kconfig | 13 +
arch/loongarch/cpu/generic/Makefile | 7 +++
arch/loongarch
if we tell kernel we are
not efi compatible by setting a0 boot argument to zero.
Link: https://docs.kernel.org/arch/loongarch/booting.html
Signed-off-by: Jiaxun Yang
---
arch/loongarch/lib/Makefile | 2 +
arch/loongarch/lib/bootm.c | 177
arch
Add exception entry assembly code, import stackframe.h
from Linux, provide debug prints when exception happens.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/Kconfig | 3 +
arch/loongarch/cpu/Makefile | 2 +-
arch/loongarch/cpu/genex.S | 21
start.S for initialisation, smp_secondary routine for
a spin-table like interface for secondary cpus.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/cpu/Makefile| 4 +
arch/loongarch/cpu/cpu.c | 28 ++
arch/loongarch/cpu/smp_secondary.S | 55
arch/loongarch
Add some common library routines for the architecture.
Signed-off-by: Jiaxun Yang
---
arch/loongarch/lib/Makefile | 7
arch/loongarch/lib/asm-offsets.c | 66
arch/loongarch/lib/boot.c| 14
arch/loongarch/lib/cache.c | 73
Allocate the next value to IH_ARCH_LOONGARCH.
Signed-off-by: Jiaxun Yang
---
boot/image.c| 1 +
include/image.h | 1 +
2 files changed, 2 insertions(+)
diff --git a/boot/image.c b/boot/image.c
index 073931cd7a3f..8955a095713d 100644
--- a/boot/image.c
+++ b/boot/image.c
@@ -96,6 +96,7
They all come from glibc's elf.h
Signed-off-by: Jiaxun Yang
---
include/elf.h | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/elf.h b/include/elf.h
index a4ba74d8abeb..cb3bb20c4f2e 100644
--- a/include/elf.h
+++ b/include/elf.h
@@ -219,7 +219,8 @@ typedef
For LoongArch the start of the image is not the entry
point to the image.
We refactor the code base to allow entry point to be
supplied by setup_booti.
Signed-off-by: Jiaxun Yang
---
arch/arm/lib/image.c | 3 ++-
arch/riscv/lib/image.c | 4 +++-
arch/sandbox/lib/bootm.c | 2 +-
boot
== PA it has
no impact, for MIPS it has it's own ioremap implementation
in asm/io.h anyway.
Signed-off-by: Jiaxun Yang
---
include/linux/io.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/linux/io.h b/include/linux/io.h
index 79847886be95..ada6525a1c6a 100644
-off-by: Jiaxun Yang
---
lib/fdtdec.c | 137 ---
1 file changed, 83 insertions(+), 54 deletions(-)
diff --git a/lib/fdtdec.c b/lib/fdtdec.c
index b2c59ab3818b..403b363043d6 100644
--- a/lib/fdtdec.c
+++ b/lib/fdtdec.c
@@ -1075,90 +1075,119
OVMF replacement and second stage BL.
Any comments are much appreciated!
Thanks
Signed-off-by: Jiaxun Yang
---
Jiaxun Yang (16):
lib: fdtdec: Handle multiple memory nodes
linux/io.h: Use map_physmem to implement ioremap
image: Take entry point as an output of setup_booti
elf.h De
在2024年5月21日五月 下午6:32,Ilias Apalodimas写道:
[...]
> What's ventoy? Googling it seems to be a tool for writing images?
It's a sophisticated EFI application designed for network booting,
more file system support etc...
>
>> It's nearly impossible to run MIPS OS in virtual (or paged)
>> segment.
在2024年5月21日五月 下午2:58,Ilias Apalodimas写道:
> Hi Jiaxun,
>
> On Fri, 17 May 2024 at 19:33, Jiaxun Yang wrote:
>>
>> Allow runtime relocate to be disabled because on MIPS we
>> never do that. It's guaranteed that OS won't call
>> set_virtual_address_map and
在2024年5月21日五月 上午8:35,Max Filippov写道:
[...]
>> +++ b/board/emulation/qemu-xtensa/MAINTAINERS
>> @@ -0,0 +1,7 @@
>> +QEMU XTENSA 'VIRT' BOARD
>> +M: Jiaxun Yang
>> +S: Maintained
>> +F: board/emulation/qemu-xtensa/
>> +F: board/emulati
在2024年5月21日五月 上午3:31,Max Filippov写道:
> On Sun, May 19, 2024 at 1:53 PM Jiaxun Yang wrote:
>>
>> Add xtensa semihosting driver.
>>
>> It can't use regular semihosting driver as Xtensa's has it's own
>> semihosting ABI.
>>
>> Note that semihostin
在2024年5月20日五月 下午4:18,Max Filippov写道:
> On Sun, May 19, 2024 at 1:53 PM Jiaxun Yang wrote:
>>
>> u-boot.elf target requiures it to work.
>
> Typo.
>
>> Signed-off-by: Jiaxun Yang
>> ---
>> arch/xtensa/config.mk | 3 +++
>> 1 file changed
在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
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
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
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
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
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
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
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
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
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
-xtensa-dc232b-elf.tar.gz
Signed-off-by: Jiaxun Yang
---
Jiaxun Yang (10):
xtensa: Move dram_init to xtfpga board file
xtensa: Correct define of _end symbol
xtensa: Implement phys virt conversion for PTP_MMU
xtensa: Define PLATFORM_ELFFLAGS
xtensa: Bring
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
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
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
-by: Jiaxun Yang
---
arch/Kconfig | 34 ++
arch/mips/Kconfig | 20 +++-
arch/mips/mach-ath79/Kconfig | 8
arch/mips/mach-bmips/Kconfig | 20 ++--
arch/mips/mach-jz47xx/Kconfig | 2 +-
arch/mips/mach
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
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
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
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
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
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
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
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
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
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
can run more test on big endian systems.
Boot tested on qemu.
Please review.
Thanks
Signed-off-by: Jiaxun Yang
---
Jiaxun Yang (13):
tools/relocate-rela: Fix Big Endian elf64 handling
arm: Don't select ARM_ASM_UNIFIED on arm64
arm: Fix assembler.h for arm64
arm: Introduce
在2024年5月17日五月 下午11:09,Jiaxun Yang写道:
[...]
> diff --git a/lib/efi_selftest/efi_selftest_miniapp_exception.c
> b/lib/efi_selftest/efi_selftest_miniapp_exception.c
> index f668cdac4ab2..2dfbb7c74075 100644
> --- a/lib/efi_selftest/efi_selftest_miniapp_exception.c
> +++ b/l
在2024年5月18日五月 上午9:08,Heinrich Schuchardt写道:
> On 5/17/24 13:45, Jiaxun Yang wrote:
[...]
Hi Heinrich,
Ah sorry I should really spell check it before sending it off
It was copied directly from my personal note.
> %s/optinos/options/
>
> Relating to gd->bd->bi_dram[
在2024年5月17日五月 下午10:11,Heinrich Schuchardt写道:
[...]
> As the jumpbuffer is only used inside U-Boot we should be able to use
> the same register sequence independant of the bitness.
Hi Heinrich,
I chose to use ABI's stack frame because GDB requires it to perform proper
unwinding and it helped
nfig.
Signed-off-by: Jiaxun Yang
---
Makefile | 3 ++-
arch/sandbox/Kconfig | 2 +-
arch/sandbox/config.mk | 5 ++---
doc/arch/sandbox/sandbox.rst | 6 --
4 files changed, 5 insertions(+), 11 deletions(-)
diff --git a/Makefile b/Makefile
index 596f6458
Since EFI loader on sandbox requires some architecture
code, make it depend on HOST_ARCH to ensure it's only
compiled on desired host.
Signed-off-by: Jiaxun Yang
---
lib/efi_loader/Kconfig | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/lib/efi_loader/Kconfig b/lib
Move host arch detection to Kconfig so we can make some
options depend on HOST_ARCH.
Also now we are using compiler macros to detect target
arch, which is more robust than looking at uname -a.
Signed-off-by: Jiaxun Yang
---
Makefile | 24
.
Tested on x86_64, cross compile and loosely tesed with qemu-user on
riscv64, arm, aarch64.
Thanks
[1]: https://lore.kernel.org/u-boot/2cd8d385-f0a9-4a1b-827d-1c55cd7e3...@gmx.de/
Signed-off-by: Jiaxun Yang
---
Jiaxun Yang (3):
sandbox: Move HOST_ARCH detection to Kconfig
EFI: Make EFI
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| 3 ++-
board/imgtec/boston
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.dts | 222
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(+)
diff --git a/dts/upstream/src/mips/Makefile b/dts/upstream/src/mips/Makefile
new file mode 100644
index
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 detection code to probe
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(+)
diff --git a/board/imgtec/boston/Kconfig b/board
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(+)
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index eb7f3ad23762..748b5175b2eb
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(+)
diff --git a/arch/mips/include/asm/acpi_table.h
b/arch/mips/include/asm/acpi_table.h
new file mode 100644
Remove hard dependencies to arch headers, get clock from clk
subsystem if arch clock function is not available, align
compatible strings with devicetree binding.
No functional change on existing platforms, just get it build
on other platforms.
Signed-off-by: Jiaxun Yang
---
drivers/ata
address support for dwc_ahsata, ensure
higher bits are written into registers/sg properly.
Use memalign for allocating aligned buffer in dwc_ahsata so we
don't have to do our own alignment in driver.
Signed-off-by: Jiaxun Yang
---
drivers/ata/ahci.c| 34
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 file changed, 1 insertion(+)
diff --
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/Kconfig| 9 +
drivers/pci
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
---
drivers/pci/pcie_xilinx.c | 53
-system-mips64el -M boston -cpu I6500 -bios ./u-boot.bin -nographic
```
This is my first u-boot contribution, please kindly advise if you
have any comments.
Thanks
Signed-off-by: Jiaxun Yang
---
Changes in v3:
- Slight change in clk_boston probe order (Jonas)
- Link to v2:
https
https://sourceforge.net/projects/efify/
>>[5]: https://github.com/loongson-community/grub
>>[6]: https://www.ventoy.net/en/index.html
>>
>>Signed-off-by: Jiaxun Yang
>>---
>>Jiaxun Yang (7):
>> MIPS: Implement setjmp
>> efi: Allow runtime relocate to
elftest block image transfer
> bootefi selftest
>
> Fixes: a75cf70d23ac ("efi: Correct handling of frame buffer")
> Signed-off-by: Heinrich Schuchardt
Reviewed-by: Jiaxun Yang
It turns out that texture copy is only required for 8bpc display, which
we don't ca
Implemented crt, ELF and EFI linking, ELF relocation handling
and other necessary bits for MIPS EFI.
Signed-off-by: Jiaxun Yang
---
arch/mips/config.mk| 9 ++
arch/mips/lib/Makefile | 13 +++
arch/mips/lib/crt0_mips_efi.S | 239
Various file names, instruction defines, magic numbers
related to MIPS's EFI implementation.
PE magic numbers are from winnt.h, DHCP numbers are
from IANA page, boot file names are from other
implementations.
Signed-off-by: Jiaxun Yang
---
include/asm-generic/pe.h | 5
This is necessary for SMBIOS to build on MIPS.
Signed-off-by: Jiaxun Yang
---
arch/mips/include/asm/global_data.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/mips/include/asm/global_data.h
b/arch/mips/include/asm/global_data.h
index 147a95ecea8b..740bbcdb84e9 100644
--- a/arch
EFI AFLAGS/CFLAGS should be enforced for those runtime
supporting files as well, otherwise EFI applications
will fail to compile on MIPS.
Signed-off-by: Jiaxun Yang
---
Makefile | 3 +++
scripts/Makefile.lib | 8 ++--
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git
This is required in performing objcopy to MIPS EFI files.
Signed-off-by: Jiaxun Yang
---
scripts/Makefile.lib | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 62f87517c09c..52aed7a65d47 100644
--- a/scripts/Makefile.lib
+++ b
in this segment, so relocation is totally
unnecessary.
Also U-Boot does not use traditional .dyn.rel to perform
relocation on MIPS, that makes implementation of runtime
relocation pretty hard.
Signed-off-by: Jiaxun Yang
---
include/efi_loader.h | 26 ++
lib/efi_loader
Implement setjmp with o32/n64 ABI's standard stack frame.
Note that those two ABIs slightly disagreed on placement of
registers so they are being implemented in two different
files.
Signed-off-by: Jiaxun Yang
---
arch/mips/include/asm/setjmp.h | 36 +++
arch/mips/lib
://github.com/kontais/EFI-MIPS
[2]: https://github.com/loongson-community/firmware-nonfree
[3]: http://www.kunluntech.com.cn/klbiosxl
[4]: https://sourceforge.net/projects/efify/
[5]: https://github.com/loongson-community/grub
[6]: https://www.ventoy.net/en/index.html
Signed-off-by: Jiaxun Yang
在2024年5月17日五月 下午1:46,Heinrich Schuchardt写道:
> On 11/19/23 20:11, Simon Glass wrote:
>> The efi_gop driver uses private fields from the video uclass to obtain a
>> pointer to the frame buffer. Use the platform data instead.
>>
>> Check the VIDEO_COPY setting to determine which frame buffer to
This serves as a reference for developers on how to handle
all those address spaces for U-Boot.
Signed-off-by: Jiaxun Yang
---
Hi all,
I was trying to clear up long standing myth of virtual
address vs physical adddress mapping on MIPS by having
a clear division betweem virt and phys adddress
在2024年5月17日五月 上午2:56,Heinrich Schuchardt写道:
[...]
>>+config VIRTIO_GPU_SIZE_X
>>+ int "Width of display (X resolution)"
>>+ default 1280
>
> 1920x1080 would look like a reasonable default for me.
1280x1024 was chosen because it is the largest resolution being defined in
VESA VBE, hence
1 - 100 of 144 matches
Mail list logo