<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/arch/arm/include/asm/system.h, branch v2025.04</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/u-boot.git/atom/arch/arm/include/asm/system.h?h=v2025.04</id>
<link rel='self' href='http://cgit.235523.xyz/u-boot.git/atom/arch/arm/include/asm/system.h?h=v2025.04'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<updated>2025-02-15T13:44:43Z</updated>
<entry>
<title>arm64: Add late jump to kernel board hook</title>
<updated>2025-02-15T13:44:43Z</updated>
<author>
<name>Marek Vasut</name>
<email>marek.vasut+renesas@mailbox.org</email>
</author>
<published>2025-01-29T21:59:18Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9f95282f31d28323d0c99b258b648936e5eadf60'/>
<id>urn:sha1:9f95282f31d28323d0c99b258b648936e5eadf60</id>
<content type='text'>
Add empty weak assembler function armv8_switch_to_el2_prep() which is
jumped to just before U-Boot determines which EL it is running in and
decides which path to take to boot the Linux kernel.

This weak function is meant to be used by architecture specific code
to implement jump to a firmware blob, which then returns right past
this weak function and continues execution of U-Boot code which then
boots the Linux kernel. One example of such use case is when U-Boot
jump tp TFA BL31, which switches from EL3 to EL2 and then returns to
U-Boot code newly running in EL2 and starts the Linux kernel.

The weak function is called with caches already disabled and DM shut
down. Any preparatory work or even loading of more data must be done
in board_prep_linux(), this hook is meant only for the final jump to
the firmware and return to U-Boot before booting Linux.

Reviewed-by: Tom Rini &lt;trini@konsulko.com&gt;
Signed-off-by: Marek Vasut &lt;marek.vasut+renesas@mailbox.org&gt;
</content>
</entry>
<entry>
<title>armv8: Fix get_sctlr() return type</title>
<updated>2024-11-17T19:13:22Z</updated>
<author>
<name>Sam Protsenko</name>
<email>semen.protsenko@linaro.org</email>
</author>
<published>2024-11-07T02:58:30Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=be48369f32a5831b032b62603fd9634de9302056'/>
<id>urn:sha1:be48369f32a5831b032b62603fd9634de9302056</id>
<content type='text'>
SCTLR_EL2 is a 64-bit register [1]. Return its value as long (64 bit)
instead of int (32 bit) in get_sctlr() to make sure it's not trimmed.

[1] https://developer.arm.com/documentation/ddi0595/2021-06/AArch64-Registers/SCTLR-EL2--System-Control-Register--EL2-?lang=en

Fixes: 0ae7653128c8 ("arm64: core support")
Suggested-by: Heinrich Schuchardt &lt;xypron.glpk@gmx.de&gt;
Signed-off-by: Sam Protsenko &lt;semen.protsenko@linaro.org&gt;
Reviewed-by: Ilias Apalodimas &lt;ilias.apalodimas@linaro.org&gt;
</content>
</entry>
<entry>
<title>CONFIG_SYS_NONCACHED_MEMORY: Move prototypes to include/cpu_func.h for consistency</title>
<updated>2024-10-29T22:17:18Z</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2024-10-22T16:31:17Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=17e476aa0525905c52e48c19adcb54fdca60d48b'/>
<id>urn:sha1:17e476aa0525905c52e48c19adcb54fdca60d48b</id>
<content type='text'>
Currently, a number of generic cache related functions have their common
prototype declared in include/cpu_func.h. Move the current set of
noncached functions there as well to match.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
</entry>
<entry>
<title>arm: Implement read_mpidr on armv7</title>
<updated>2024-10-27T23:24:13Z</updated>
<author>
<name>Patrick Rudolph</name>
<email>patrick.rudolph@9elements.com</email>
</author>
<published>2024-10-23T13:20:15Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=080be069f5fc4cd0f5a9fbf3e697e0a9ba3ca992'/>
<id>urn:sha1:080be069f5fc4cd0f5a9fbf3e697e0a9ba3ca992</id>
<content type='text'>
Implement read_mpidr() on armv7 to make use of it in generic
code that compiles on both armv7 and armv8.

Signed-off-by: Patrick Rudolph &lt;patrick.rudolph@9elements.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>armv8: mmu: add a way to map additional regions</title>
<updated>2024-09-06T08:47:46Z</updated>
<author>
<name>Caleb Connolly</name>
<email>caleb.connolly@linaro.org</email>
</author>
<published>2024-08-08T23:59:31Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9f2d4561465b42f8cdc478ea5df44b93e12a90d9'/>
<id>urn:sha1:9f2d4561465b42f8cdc478ea5df44b93e12a90d9</id>
<content type='text'>
In some cases we might want to map some memory region after enabling
caches. Introduce a new helper for this.

Reviewed-by: Neil Armstrong &lt;neil.armstrong@linaro.org&gt;
Signed-off-by: Caleb Connolly &lt;caleb.connolly@linaro.org&gt;
</content>
</entry>
<entry>
<title>armv8: generic_timer: Use event stream for udelay</title>
<updated>2024-05-13T22:51:14Z</updated>
<author>
<name>Peter Hoyes</name>
<email>Peter.Hoyes@arm.com</email>
</author>
<published>2024-05-01T08:16:33Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=ebc84d7b60c1ed3398e9f600fe3dc8406500bd35'/>
<id>urn:sha1:ebc84d7b60c1ed3398e9f600fe3dc8406500bd35</id>
<content type='text'>
Polling cntpct_el0 in a tight loop for delays is inefficient.
This is particularly apparent on Arm FVPs, which do not simulate
real time, meaning that a 1s sleep can take a couple of orders
of magnitude longer to execute in wall time.

If running at EL2 or above (where CNTHCTL_EL2 is available), enable
the cntpct_el0 event stream temporarily and use wfe to implement
the delay more efficiently. The event period is chosen as a
trade-off between efficiency and the fact that Arm FVPs do not
typically simulate real time.

This is only implemented for Armv8 boards, where an architectural
timer exists, and only enabled by default for the ARCH_VEXPRESS64
board family.

Signed-off-by: Peter Hoyes &lt;Peter.Hoyes@arm.com&gt;
Reviewed-by: Andre Przywara &lt;andre.przywara@arm.com&gt;
</content>
</entry>
<entry>
<title>arm: Move sev() and wfe() definitions to common Arm header file</title>
<updated>2024-05-13T22:51:14Z</updated>
<author>
<name>Peter Hoyes</name>
<email>Peter.Hoyes@arm.com</email>
</author>
<published>2024-05-01T08:16:32Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=b18a3c183d20812933d192d4b0d622b11ef2bf29'/>
<id>urn:sha1:b18a3c183d20812933d192d4b0d622b11ef2bf29</id>
<content type='text'>
The sev() and wfe() asm macros are currently defined only for
mach-exynos. As these are common Arm instructions, move them to the
common asm/system.h header file, for both Armv7 and Armv8, so they
can be used by other machines.

wfe may theoretically trigger a context switch if an interrupt occurs
so add a memory barrier to this call.

Signed-off-by: Peter Hoyes &lt;Peter.Hoyes@arm.com&gt;
Reviewed-by: Andre Przywara&lt;andre.przywara@arm.com&gt;
</content>
</entry>
<entry>
<title>arm: caches: Make DCACHE_DEFAULT_OPTION accessible for ARM64 arch</title>
<updated>2023-11-13T09:55:38Z</updated>
<author>
<name>Patrice Chotard</name>
<email>patrice.chotard@foss.st.com</email>
</author>
<published>2023-10-27T14:42:56Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=2f9886c66864ffc52f6a7ab5be9be97fec47ef1d'/>
<id>urn:sha1:2f9886c66864ffc52f6a7ab5be9be97fec47ef1d</id>
<content type='text'>
This fixes the following compilation error in ARM64:
arch/arm/mach-stm32mp/dram_init.c: In function ‘board_get_usable_ram_top’:
arch/arm/mach-stm32mp/dram_init.c:59:45: error: ‘DCACHE_DEFAULT_OPTION’ undeclared (first use in this function)
   59 |  mmu_set_region_dcache_behaviour(reg, size, DCACHE_DEFAULT_OPTION);
      |                                             ^~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Patrice Chotard &lt;patrice.chotard@foss.st.com&gt;
Reviewed-by: Patrick Delaunay &lt;patrick.delaunay@foss.st.com&gt;
</content>
</entry>
<entry>
<title>driver: rng: Add DM_RNG interface for ARMv8.5 RNDR registers</title>
<updated>2023-10-11T17:22:32Z</updated>
<author>
<name>Andre Przywara</name>
<email>andre.przywara@arm.com</email>
</author>
<published>2023-08-30T11:32:30Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=31565bb0aa2d76b6941e96bcdbd204bae49ca828'/>
<id>urn:sha1:31565bb0aa2d76b6941e96bcdbd204bae49ca828</id>
<content type='text'>
The ARMv8.5 architecture extension defines architectural RNDR/RNDRRS
system registers, that provide 64 bits worth of randomness on every
read. Since it's an extension, and implementing it is optional, there is
a field in the ID_AA64ISAR0_EL1 ID register to query the availability
of those registers.

Add a UCLASS_RNG driver that returns entropy via repeated reads from
those system registers, if the extension is implemented.
The driver always binds, but checks the availability in the probe()
routine.

This helps systems which suffer from low boot entropy, since U-Boot can
provide entropy via the generic UEFI entropy gathering protocol to the OS,
at an early stage.

Signed-off-by: Andre Przywara &lt;andre.przywara@arm.com&gt;
Reviewed-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
</entry>
<entry>
<title>armv8: Always unmask SErrors</title>
<updated>2022-03-02T18:59:29Z</updated>
<author>
<name>Andre Przywara</name>
<email>andre.przywara@arm.com</email>
</author>
<published>2022-02-11T11:29:35Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=6c7691edd55bc13c221d7283c238d305f6923236'/>
<id>urn:sha1:6c7691edd55bc13c221d7283c238d305f6923236</id>
<content type='text'>
The ARMv8 architecture describes the "SError interrupt" as the fourth
kind of exception, next to synchronous exceptions, IRQs, and FIQs.
Those SErrors signal exceptional conditions from which the system might
not easily recover, and are normally generated by the interconnect as a
response to some bus error. A typical situation is access to a
non-existing memory address or device, but it might be deliberately
triggered by a device as well.
The SError interrupt replaces the Armv7 asynchronous abort.

Trusted Firmware enters U-Boot (BL33) typically with SErrors masked,
and we never enable them. However any SError condition still triggers
the SError interrupt, and this condition stays pending, it just won't be
handled. If now later on the Linux kernel unmasks the "A" bit in PState,
it will immediately take the exception, leading to a kernel crash.
This leaves many people scratching their head about the reason for
this, and leads to long debug sessions, possibly looking at the wrong
places (the kernel, but not U-Boot).

To avoid the situation, just unmask SErrors early in the ARMv8 boot
process, so that the U-Boot exception handlers reports them in a timely
manner. As SErrors are typically asynchronous, the register dump does
not need to point at the actual culprit, but it should happen very
shortly after the condition.

For those exceptions to be taken, we also need to route them to EL2,
if U-Boot is running in this exception level.

This removes the respective code snippet from the Freescale lowlevel
routine, as this is now handled in generic ARMv8 code.

Reported-by: Nishanth Menon &lt;nm@ti.com&gt;
Signed-off-by: Andre Przywara &lt;andre.przywara@arm.com&gt;
</content>
</entry>
</feed>
