RTEMS | bsp/aarch64:SMP improvement on aarch64 (!113)
Sebastian Huber (@sebhub)
gitlab at rtems.org
Wed Sep 18 00:24:56 UTC 2024
Sebastian Huber started a new discussion on bsps/aarch64/shared/start/start.S: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/113#note_112155
> _el1_start:
>
> #ifdef RTEMS_SMP
> - /* Read MPIDR and get current processor index */
> - mrs x7, mpidr_el1
> - and x7, x7, #0xff
> + ldr x3, =aarch64_cpu_boot_params
The approach with this table is quite complicated and not necessary for most systems. Why can't you simply call a function which is provided by the BSP? For example:
```
#ifdef RTEMS_SMP
bl _AArch64_Get_current_processor
...
```
The default implementation is:
```
FUNCTION_ENTRY(_AArch64_Get_current_processor)
mrs x0, mpidr_el1
and x0, x0, #0xff
FUNCTION_END(_AArch64_Get_current_processor)
```
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/113#note_112155
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20240918/a80244c2/attachment.htm>
More information about the bugs
mailing list