# zvm_zephyr **Repository Path**: zvm-developer/zvm_zephyr ## Basic Information - **Project Name**: zvm_zephyr - **Description**: 适配运行在zvm发行版上的zephyr源码 - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: Zephyr_4.0.0 - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-11-30 - **Last Updated**: 2026-12-04 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Zephyr OS 镜像编译流程 本文说明如何编译单核/多核的Zephyr OS镜像。 ### 基础操作步骤 #### 一、单核编译 1.执行编译命令 ``` #单核编译 west build -b roc_rk3588_pc samples/shmem/ ``` #### 二、多核编译 1.执行多核编译命令 ``` #多核编译 west build -b roc_rk3588_pc_smp samples/shmem/ ``` #### 三、更改核数操作步骤 1.在boards/firefly/roc_rk3588_pc/roc_rk3588_pc_rk3588_smp_defconfig,找到如下的宏: ``` # 更改支持核数(默认编译双核),如需要3个,更改为3即可 CONFIG_MP_MAX_NUM_CPUS=2 ``` 2.在dts/arm64/rockchip/rk3588_pl011.dtsi,找到如下CPU节点: ``` #根据核的数量来确定节点数,添加核只需要往后依次打开后续注释的CPU子节点即可 cpus { #address-cells = <1>; #size-cells = <0>; cpu@000 { device_type = "cpu"; compatible = "arm,cortex-a55"; enable-method = "psci"; reg = <0x000>; }; cpu@100 { device_type = "cpu"; compatible = "arm,cortex-a55"; enable-method = "psci"; reg = <0x100>; }; // cpu@200 { // device_type = "cpu"; // compatible = "arm,cortex-a55"; // enable-method = "psci"; // reg = <0x200>; // }; } ``` 3.执行多核编译命令