1/* Copyright 2020 The TensorFlow Authors. All Rights Reserved. 2 3Licensed under the Apache License, Version 2.0 (the "License"); 4you may not use this file except in compliance with the License. 5You may obtain a copy of the License at 6 7 http://www.apache.org/licenses/LICENSE-2.0 8 9Unless required by applicable law or agreed to in writing, software 10distributed under the License is distributed on an "AS IS" BASIS, 11WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12See the License for the specific language governing permissions and 13limitations under the License. 14==============================================================================*/ 15 16 17/* 18 * linker script for use with ECM3531 chip. 19 * .text and .ro map to FLASH all else to SRAM. 20 * 21 */ 22 23 /* 24 * Indicate to the linker the entry point. 25 */ 26ENTRY(ResetISR) 27 28/* 29 * FLASH is at 0x01000000 of length 0x00080000 512KB 30 * SRAM is at 0x10000000 of length 0x00020000 128KB 31 */ 32MEMORY 33{ 34 FLASH (RX) : ORIGIN = 0x01000000, LENGTH = 0x00080000 35 SRAM (RWX) : ORIGIN = 0x10000000, LENGTH = 0x00020000 36} 37 38SECTIONS 39{ 40 .text : 41 { 42 _text = .; 43 KEEP(*(.vectors)) 44 . = ALIGN(0x4); 45 *(.text*) 46 . = ALIGN(0x4); 47 *(.rodata*) 48 . = ALIGN(0x4); 49 _etext = .; 50 } > FLASH= 0 51 .dummy : 52 { 53 . = ALIGN(0x4); 54 _eftext = .; 55 } > FLASH 56/* put the stack at the bottom of SRAM*/ 57 .datax (NOLOAD) : 58 { 59 _datax = .; 60 KEEP(*(.mainStack)) 61 . = ALIGN(0x4); 62 . += 16384; 63 _edatax = .; 64 _stack_top = .; 65 } > SRAM 66 .data : 67 { 68 _data = .; 69 *(.data*) 70 KEEP(*(.mainHeap)) 71 _edata = .; 72 } > SRAM AT > FLASH 73 74 .bss (NOLOAD) : 75 { 76 _bss = .; 77 *(.bss*) 78 *(COMMON) 79 _ebss = .; 80 } > SRAM 81 82 83 84} 85 86