Hi,
I am looking at how console flags are used and setup.
In porting guide I see
Function : bl31_plat_runtime_setup() [optional]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
Argument : void
Return : void
The purpose of this function is allow the platform to perform any BL31 runtime
setup just prior to BL31 exit during cold boot. The default weak
implementation of this function will invoke ``console_switch_state()`` to switch
console output to consoles marked for use in the ``runtime`` state.
Some platform are calling it but some of them not (like our Xilinx one).
Tegra has in tegra_pwr_domain_power_down_wfi()
console_flush();
console_switch_state(0);
which is what none other has.
Should console_flush() be called by default all the time when console is
switched and also disabled when system goes down?
Why console_switch_state(CONSOLE_FLAG_RUNTIME) is not called from bl31_main()
when before bl31_plat_runtime_setup() is called we have console_flush() already?
The second part of this how console scope is setup.
Implementation is clear and set.
void console_set_scope(console_t *console, unsigned int scope)
{
assert(console != NULL);
console->flags = (console->flags & ~CONSOLE_FLAG_SCOPE_MASK) | scope;
}
The commit cc5859ca19ff ("Multi-console: Deprecate the `finish_console_register`
macro") when finish_console_register is called (DCC is exception here) is
setting up CONSOLE_FLAG_BOOT and CONSOLE_FLAG_CRASH by default.
And most of platforms is calling console registration with calling
console_set_scope() where new flags are recorded BOOT only, BOOT/RUNTIME,
RUNTIME only or BOOT/RUNTIME/CRASH.
I would like to understand what should be the right behavior.
Why are platforms removing CRASH flag after registration? (I see that a lot of
platforms are having private plat_crash_console_init() but pretty much crash
console is the same with regular console).
Why runtime console is setup directly in bl31_early_platform_setup2 when
guidance is saying that it should be done much later?
Also commit 63c52d0071ef ("plat/common/crash_console_helpers.S: Fix
MULTI_CONSOLE_API support") removed CONSOLE_FLAG_CRASH from
plat_crash_console_init but only from 64bit version. In 32bit version there is
still there. It suggest that any C code should be called.
Do we really need CONSOLE_FLAG_CRASH?
Thanks,
Michal
--
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Xilinx Microblaze
Maintainer of Linux kernel - Xilinx Zynq ARM and ZynqMP/Versal ARM64 SoCs
U-Boot custodian - Xilinx Microblaze/Zynq/ZynqMP/Versal/Versal NET SoCs
TF-A maintainer - Xilinx ZynqMP/Versal/Versal NET SoCs
This event has been canceled with a note:
"Hi, The TF-A Tech Forum instance on Sep 21st 2023 is cancelled due to lack
of topic. Thanks & Regards, Olivier. "
TF-A Tech Forum
Thursday Sep 21, 2023 ⋅ 5pm – 6pm
Central European Time - Paris
We run an open technical forum call for anyone to participate and it is not
restricted to Trusted Firmware project members. It will operate under the
guidance of the TF TSC. Feel free to forward this invite to
colleagues. Invites are via the TF-A mailing list and also published on the
Trusted Firmware website. Details are
here: https://www.trustedfirmware.org/meetings/tf-a-technical-forum/Tr…
Firmware is inviting you to a scheduled Zoom meeting.Join Zoom
Meetinghttps://zoom.us/j/9159704974Meeting ID: 915 970 4974One tap
mobile+16465588656,,9159704974# US (New York)+16699009128,,9159704974# US
(San Jose)Dial by your location +1 646 558
8656 US (New York) +1 669 900
9128 US (San Jose) 877 853 5247 US
Toll-free 888 788 0099 US Toll-freeMeeting ID:
915 970 4974Find your local
number: https://zoom.us/u/ad27hc6t7h
Guests
marek.bykowski(a)gmail.com
okash.khawaja(a)gmail.com
tf-a(a)lists.trustedfirmware.org
~~//~~
Invitation from Google Calendar: https://calendar.google.com/calendar/
You are receiving this email because you are an attendee on the event. To
stop receiving future updates for this event, decline this event.
Forwarding this invitation could allow any recipient to send a response to
the organizer, be added to the guest list, invite others regardless of
their own invitation status, or modify your RSVP.
Learn more https://support.google.com/calendar/answer/37135#forwarding
Hi,
Please find the latest report on new defect(s) introduced to ARM-software/arm-trusted-firmware found with Coverity Scan.
1 new defect(s) introduced to ARM-software/arm-trusted-firmware found with Coverity Scan.
New defect(s) Reported-by: Coverity Scan
Showing 1 of 1 defect(s)
** CID 401729: Integer handling issues (CONSTANT_EXPRESSION_RESULT)
/drivers/st/ddr/stm32mp_ddr_test.c: 134 in stm32mp_ddr_check_size()
________________________________________________________________________________________________________
*** CID 401729: Integer handling issues (CONSTANT_EXPRESSION_RESULT)
/drivers/st/ddr/stm32mp_ddr_test.c: 134 in stm32mp_ddr_check_size()
128 uint32_t stm32mp_ddr_check_size(void)
129 {
130 uint32_t offset = sizeof(uint32_t);
131
132 mmio_write_32(STM32MP_DDR_BASE, DDR_PATTERN);
133
>>> CID 401729: Integer handling issues (CONSTANT_EXPRESSION_RESULT)
>>> "offset < 4294967296UL" is always true regardless of the values of its operands. This occurs as the logical operand of "while".
134 while (offset < STM32MP_DDR_MAX_SIZE) {
135 mmio_write_32(STM32MP_DDR_BASE + offset, DDR_ANTIPATTERN);
136 dsb();
137
138 if (mmio_read_32(STM32MP_DDR_BASE) != DDR_PATTERN) {
139 break;
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my0P…
Hello,
QEMU 8.1 added support for FEAT_RME. It is experimental, enabled with
'-cpu max,x-rme=on', and requires fixes that will be available in QEMU
8.2. I'm working on adding support to TF-A and TF-RMM.
I just submitted some TF-A patches for review (topic qemu-rme) that enable
the feature for the virt platform, and intend to send the necessary
changes for TF-RMM within a week or so. Without RMM, the Test Realm
Payload is included into the FIP for light testing.
After the TF-A and TF-RMM changes, I'd like to add support for the SBSA
platform as well, which should be a relatively small change once the
common QEMU support is merged.
Thanks,
Jean
---
Building TF-A for QEMU with RME support:
make -j CROSS_COMPILE=aarch64-linux-gnu- PLAT=qemu DEBUG=1
RMM=path/to/rmm/build/Debug/rmm.img ENABLE_RME=1
BL33=path/to/QEMU_EFI.fd QEMU_USE_GIC_DRIVER=QEMU_GICV3
all fip
dd if=tf-a/build/qemu/debug/bl1.bin of=flash.bin bs=4096 conv=notrunc
dd if=tf-a//build/qemu/debug/fip.bin of=flash.bin seek=64 bs=4096 conv=notrunc
Running QEMU, for example:
qemu-system-aarch64 -cpu max,x-rme=on,sme=off -m 3G -smp 8
-M virt,gic-version=3,virtualization=on,secure=on,acpi=off
-bios flash.bin
-kernel linux/arch/arm64/boot/Image
-initrd path/to/initrd
-append console=ttyAMA0
-nographic
...
[ 0.825891] kvm [1]: Using prototype RMM support (version 66.0)
SMC_RMM_FEATURES 0 > RMI_SUCCESS 33403e30
Hi all,
I find that the latest Arm A-profile manual (DDI0487_J_a) mention
several registers/instructions related to memory encryption (e.g.,
MECID-related registers). So can I ask two questions about it?
1. Is the FVP (I use the Base RevC AEM) support Memory Encryption
Context (MEC) and Memory Protection Engine (MPE)? They are critical to
memory encryption. If no, do we have some solutions to simulate them
and verify memory encryption?
2. Does current TF-A support managing MPE, or other hardware related
to memory encryption?
Besides that, one problem for curiosity (only related to FVP).
3. I find some PCI-E device can use hardware encryption (example,
NVIDIA H100 GPU). Can we attach this device to FVP's PCI-E port?
Assume it has already connected to my Host PC via PCI-E.
Sincerely,
WANG Chenxu
Hi All,
Note you may have received another instance of this note but when I
attempted to send to all TF ML's simultaneously it seemed to fail, so
sending to each one at a time. Sorry about that. :/
We've created a Discord Server for real time chats/sharing. This solution
comes at no cost to the project, is set up with channels for each project,
includes a #general channel, and supports direct 1-1 chats between members,
all with the goal of improving collaboration between trustedfirmware.org
developers.
We encourage all to join! :) Instructions for joining can be found on
the TF.org
FAQ page <https://www.trustedfirmware.org/faq/>.
See you all there and please don't hesitate to reach out if you have any
questions!
Don Harbin
TrustedFirmware Community Manager
don.harbin(a)linaro.org