Skip to content

Commit 2c760ec

Browse files
committed
docs/system/arm: document S32K5 machine
Document the S32K566 Cortex-R52 machine, including the implemented devices, memory map, direct RTOS boot command, LPUART console wiring, test command, and current firmware/Linux limitations. Signed-off-by: Chao Liu <chao.liu@processmission.com>
1 parent 2d5d3b5 commit 2c760ec

2 files changed

Lines changed: 132 additions & 0 deletions

File tree

docs/system/arm/s32k5.rst

Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
.. SPDX-License-Identifier: GPL-2.0-or-later
2+
3+
NXP S32K5 board (``s32k566-cvb-r52``)
4+
=====================================
5+
6+
Overview
7+
--------
8+
9+
The ``s32k566-cvb-r52`` machine models the Cortex-R52 side of the NXP
10+
S32K5XXCVB evaluation board with an S32K566 SoC. It is a minimal board model
11+
intended for RTOS boot smoke tests, including Zephyr images built for the
12+
``s32k5xxcvb/s32k566/r52`` board target.
13+
14+
The model does not aim to provide complete S32K5 automotive SoC coverage. It
15+
implements the CPU, memory, interrupt controller, LPUART console, and the small
16+
Mode Entry (MC_ME) register subset needed by the verified Zephyr startup flow.
17+
It should not be used as a compatibility promise for other S32K5 firmware.
18+
19+
Supported devices
20+
-----------------
21+
22+
The ``s32k566-cvb-r52`` machine currently provides:
23+
24+
* up to two Arm Cortex-R52 CPUs, with one CPU enabled by default;
25+
* GICv3 interrupt controller with architectural timer interrupt wiring;
26+
* Code MRAM mapped at ``0x08000000``;
27+
* SRAM windows at ``0x21000000``, ``0x21080000``, ``0x21100000``, and
28+
``0x22000000``;
29+
* NXP S32 MC_ME register subset at ``0x40498000``;
30+
* NXP LPUART0 at ``0x400e0000``, connected to QEMU serial port 0.
31+
32+
The MC_ME model covers the partition and mode update handshake used during
33+
Zephyr SoC initialization. The LPUART model covers the polling console path
34+
used by Zephyr's MCUX LPUART driver.
35+
36+
Memory map
37+
----------
38+
39+
The machine exposes the following implemented regions:
40+
41+
.. list-table::
42+
:header-rows: 1
43+
44+
* - Address
45+
- Size
46+
- Description
47+
* - ``0x08000000``
48+
- ``32 MiB + 0x100``
49+
- Code MRAM, used as the direct kernel loader address
50+
* - ``0x21000000``
51+
- ``512 KiB``
52+
- Shared SRAM0
53+
* - ``0x21080000``
54+
- ``512 KiB``
55+
- Shared SRAM1
56+
* - ``0x21100000``
57+
- ``512 KiB``
58+
- Shared SRAM2
59+
* - ``0x22000000``
60+
- ``1 MiB`` by default
61+
- CPE SRAM, backed by the machine RAM property
62+
* - ``0x400e0000``
63+
- ``0x4000``
64+
- LPUART0
65+
* - ``0x40498000``
66+
- ``0x4000``
67+
- MC_ME
68+
* - ``0x43000000``
69+
- device-defined
70+
- GICv3 distributor
71+
* - ``0x43100000``
72+
- device-defined
73+
- GICv3 redistributor region
74+
75+
Boot options
76+
------------
77+
78+
Use ``-kernel`` to load an ELF image built for the S32K566 Cortex-R52 memory
79+
map. The loader start address is ``0x08000000``. The default and only
80+
supported CPU type is ``cortex-r52``, so the ``-cpu`` option is optional.
81+
82+
For example, a Zephyr ``hello_world`` image with UART console enabled can be
83+
started with:
84+
85+
.. code-block:: bash
86+
87+
$ qemu-system-arm \
88+
-machine s32k566-cvb-r52 \
89+
-cpu cortex-r52 \
90+
-display none \
91+
-monitor none \
92+
-serial stdio \
93+
-kernel /path/to/zephyr.elf
94+
95+
The first QEMU serial port is connected to LPUART0. For Zephyr, visible
96+
console output requires the image to enable serial console support and to use
97+
LPUART0 as ``zephyr,console``. The upstream board defconfig may leave the
98+
console disabled; in that case the image can still boot, but no UART output is
99+
expected.
100+
101+
The machine has no firmware loader, flash programmer, SD/eMMC controller, or
102+
network device. Boot media such as U-Boot images, SD card images, and Linux
103+
distribution images are therefore not supported by this machine.
104+
105+
Known limitations
106+
-----------------
107+
108+
The machine intentionally stubs or omits many S32K5 peripherals. In
109+
particular, the following areas are not complete hardware models:
110+
111+
* clock controller register blocks;
112+
* SIUL2 pinmux/GPIO blocks;
113+
* SWT startup watchdog;
114+
* xSPI controller;
115+
* eDMA controller;
116+
* flash programming, reset management, and low-power modes.
117+
118+
The current model is suitable for direct RTOS image loading. It does not
119+
implement a firmware boot flow or a general-purpose Linux platform. The
120+
S32K566 side modeled here is an Arm Cortex-R52 real-time core, not an
121+
A-profile Linux board model.
122+
123+
Running tests
124+
-------------
125+
126+
The qtest coverage for this machine checks construction, MC_ME update behavior,
127+
and LPUART reset/read/write behavior:
128+
129+
.. code-block:: bash
130+
131+
$ meson test -C build qtest-arm/s32k5-test

docs/system/target-arm.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ Board-specific documentation
9191
arm/kzm
9292
arm/nrf
9393
arm/nuvoton
94+
arm/s32k5
9495
arm/imx25-pdk
9596
arm/mcimx6ul-evk
9697
arm/mcimx7d-sabre

0 commit comments

Comments
 (0)