This event has been canceled with a note:
"Hi, Cancelling today as no topic. Regards, Olivier."
TF-A Tech Forum
Thursday Aug 22, 2024 ⋅ 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/Trusted
Firmware is inviting you to a scheduled Zoom meeting.Join Zoom
Meetinghttps://linaro-org.zoom.us/my/trustedfirmware?pwd=VktXcm5MNUUyVVM4R0k3ZUtvdU84QT09
One 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
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
Dear TF-A team,
I have a query regarding the TF-A test. Specifically, I would like to know if there is a method to find out the code coverage for a specific test or for all the tests in current run?
Your direction in this regard will be really appreciated.
Thank you,
Senthil
In my opinion, Arm TF-A (EL3) has higher privileges than Linux Kernel
(EL1), and Secure World should be able to access all memory address in
Normal World. To verify this feature, I added a new SMC call in Arm TF-A
and wrote a kernel module to test it (on a Hikey960 Development Board).
But the program does not run as expected that Arm TF-A stucked while
accessing the memory address passed by Linux Kernel.
Here is my kernel module, which uses `alloc_pages` to acquire a physical
address, and uses `page_address` converting it to a virtual address. And
the module passes the physical address and the virtual address to Arm
TF-A using `smc #0`:
```cpp
static int __init smc_testing_init(void) {
uintptr_t phys_addr, virt_addr;
pr_info("Mmodule loaded\n");
phys_addr = (uintptr_t) alloc_pages(GFP_KERNEL, 2);
virt_addr = (uintptr_t) page_address((struct page *) phys_addr);
memset((void *) virt_addr, 'A', PAGE_SIZE << 2);
printk("phys_addr: 0x%llx, virt_addr: 0x%llx\n", (uint64_t)
phys_addr, (uint64_t) virt_addr);
asm volatile(
"ldr x0, =0xC8000003\n"
"mov x1, %0\n"
"mov x2, %1\n"
"smc #0\n"
:
: "r" (phys_addr), "r" (virt_addr)
: "x0", "x1", "x2"
);
__free_pages((struct page *) phys_addr, 2);
return 0;
}
static void __exit smc_testing_exit(void) {
pr_info("Module unloaded\n");
}
```
And here is the handler's code in Arm TF-A, which prints the addresses
of physical address and virtual address, and access the first element of
the memory address:
```cpp
if (0xC8000003 == smc_fid) {
uintptr_t virt_addr = x3;
NOTICE("phys_addr: 0x%lx, virt_addr: 0x%lx\n", phys_addr, virt_addr);
NOTICE("virt_addr[0] = 0x%x\n", *((uint32_t *)virt_addr));
NOTICE("phys_addr[0] = 0x%x\n", *((uint32_t *)phys_addr));
SMC_RET0(handle);
}
```
Here is the output, Arm TF-A handles the request successfully, but
failed to access the memory address passed by Linux Kernel:
```bash
# insmod ./smc_testing.ko
[ 75.259590] smc_testing: loading out-of-tree module taints kernel.
[ 75.266682] Mmodule loaded
[ 75.269404] phys_addr: 0xfffffc0002dc5e00, virt_addr: 0xffff0000b7178000
NOTICE: phys_addr: 0xfffffc0002dc5e00, virt_addr: 0xffff0000b7178000
[ 96.276605] rcu: INFO: rcu_preempt detected stalls on CPUs/tasks:
[ 96.282741] rcu: 4-...0: (1 ticks this GP)
idle=72ec/1/0x4000000000000000 softirq=204/204 fqs=2592
[ 96.291835] (detected by 0, t=5253 jiffies, g=-643, q=16 ncpus=8)
[ 96.298044] Task dump for CPU 4:
[ 96.301287] task:insmod state:R running task stack:0
pid:201 ppid:185 flags:0x00000006
[ 96.311254] Call trace:
[ 96.313713] __switch_to+0xe4/0x160
[ 96.317241] printk_rb_static+0x30/0x58
```
This event has been canceled with a note:
"No topics scheduled this week so cancelling. Also a lot of people seem to
be away on vacations."
TF-A Tech Forum
Thursday Aug 8, 2024 ⋅ 4pm – 5pm
United Kingdom Time
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/Trusted
Firmware is inviting you to a scheduled Zoom meeting.Join Zoom
Meetinghttps://linaro-org.zoom.us/my/trustedfirmware?pwd=VktXcm5MNUUyVVM4R0k3ZUtvdU84QT09
One 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
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