1/* 2 * Copyright (c) 2022 Arm Limited 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 * 16 * 17 * This file is derivative of ../armclang/musca_ns.sct 18 */ 19 20#include "region_defs.h" 21 22 23define block ER_CODE with fixed order, alignment = 8 { 24 section .intvec, 25 readonly}; 26define block LR_CODE with fixed order, maximum size = NS_CODE_SIZE {block ER_CODE}; 27place at address NS_CODE_START {block LR_CODE}; 28 29define block ER_DATA with alignment = 8 {readwrite}; 30define block CSTACK with alignment = 32, size = NS_STACK_SIZE { }; 31define block HEAP with alignment = 8, size = NS_HEAP_SIZE { }; 32define block ARM_LIB_HEAP with alignment = 8, size = NS_HEAP_SIZE { }; 33define overlay HEAP_OVL {block HEAP}; 34define overlay HEAP_OVL {block ARM_LIB_HEAP}; 35keep {block CSTACK, block HEAP, block ARM_LIB_HEAP}; 36 37do not initialize { section .noinit }; 38initialize by copy { readwrite }; 39if (isdefinedsymbol(__USE_DLIB_PERTHREAD)) 40{ 41 // Required in a multi-threaded application 42 initialize by copy with packing = none { section __DLIB_PERTHREAD }; 43} 44 45define block DATA with fixed order, maximum size = NS_DATA_SIZE { 46 block ER_DATA, 47 block CSTACK, 48 overlay HEAP_OVL 49}; 50place at address NS_DATA_START {block DATA}; 51