soc: rockchip: replace MT_NS with MT_DEFAULT_SECURE_STATE for rk3588

Updated the MMU region entries for the GIC device to use
MT_DEFAULT_SECURE_STATE instead of MT_NS,
aligning the security attribute with the default secure sate macro.

Signed-off-by: Niu Zhihong <zhihong@nzhnb.com>
This commit is contained in:
Niu Zhihong
2025-09-15 12:42:43 +08:00
committed by Fabio Baltieri
parent 51f1161329
commit 64e22a62e9

View File

@@ -1,21 +1,22 @@
/*
* Copyright (c) 2025 Syswonder
*
* SPDX-License-Identifier: Apache-2.0
* Copyright The Zephyr Project Contributors
*/
#include <zephyr/arch/arm64/arm_mmu.h>
#include <zephyr/devicetree.h>
#include <zephyr/sys/util.h>
#include <zephyr/arch/arm64/arm_mmu.h>
static const struct arm_mmu_region mmu_regions[] = {
MMU_REGION_FLAT_ENTRY("GIC", DT_REG_ADDR_BY_IDX(DT_NODELABEL(gic), 0),
DT_REG_SIZE_BY_IDX(DT_NODELABEL(gic), 0),
MT_DEVICE_nGnRnE | MT_P_RW_U_NA | MT_NS),
MT_DEVICE_nGnRnE | MT_P_RW_U_NA | MT_DEFAULT_SECURE_STATE),
MMU_REGION_FLAT_ENTRY("GIC", DT_REG_ADDR_BY_IDX(DT_NODELABEL(gic), 1),
DT_REG_SIZE_BY_IDX(DT_NODELABEL(gic), 1),
MT_DEVICE_nGnRnE | MT_P_RW_U_NA | MT_NS),
MT_DEVICE_nGnRnE | MT_P_RW_U_NA | MT_DEFAULT_SECURE_STATE),
};