Greentime Hu | e71ea3b | 2017-10-25 15:03:49 +0800 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
| 2 | // Copyright (C) 2005-2017 Andes Technology Corporation |
| 3 | |
| 4 | #include <asm/page.h> |
| 5 | #include <asm/thread_info.h> |
| 6 | #include <asm/cache.h> |
| 7 | #include <asm/memory.h> |
| 8 | |
| 9 | #define LOAD_OFFSET (PAGE_OFFSET - PHYS_OFFSET) |
| 10 | #include <asm-generic/vmlinux.lds.h> |
| 11 | |
| 12 | OUTPUT_ARCH(nds32) |
| 13 | ENTRY(_stext_lma) |
| 14 | jiffies = jiffies_64; |
| 15 | |
| 16 | SECTIONS |
| 17 | { |
| 18 | _stext_lma = TEXTADDR - LOAD_OFFSET; |
| 19 | . = TEXTADDR; |
| 20 | __init_begin = .; |
| 21 | HEAD_TEXT_SECTION |
| 22 | INIT_TEXT_SECTION(PAGE_SIZE) |
| 23 | INIT_DATA_SECTION(16) |
| 24 | PERCPU_SECTION(L1_CACHE_BYTES) |
| 25 | __init_end = .; |
| 26 | |
| 27 | . = ALIGN(PAGE_SIZE); |
| 28 | _stext = .; |
| 29 | /* Real text segment */ |
| 30 | .text : AT(ADDR(.text) - LOAD_OFFSET) { |
| 31 | _text = .; /* Text and read-only data */ |
| 32 | TEXT_TEXT |
| 33 | SCHED_TEXT |
| 34 | CPUIDLE_TEXT |
| 35 | LOCK_TEXT |
| 36 | KPROBES_TEXT |
| 37 | IRQENTRY_TEXT |
| 38 | *(.fixup) |
| 39 | } |
| 40 | |
| 41 | _etext = .; /* End of text and rodata section */ |
| 42 | |
| 43 | _sdata = .; |
| 44 | RO_DATA_SECTION(PAGE_SIZE) |
| 45 | RW_DATA_SECTION(L1_CACHE_BYTES, PAGE_SIZE, THREAD_SIZE) |
| 46 | _edata = .; |
| 47 | |
| 48 | EXCEPTION_TABLE(16) |
| 49 | NOTES |
| 50 | BSS_SECTION(4, 4, 4) |
| 51 | _end = .; |
| 52 | |
| 53 | STABS_DEBUG |
| 54 | DWARF_DEBUG |
| 55 | |
| 56 | DISCARDS |
| 57 | } |