2 * Linker script for Hexagon kernel
4 * Copyright (c) 2010-2011, Code Aurora Forum. All rights reserved.
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 and
8 * only version 2 as published by the Free Software Foundation.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21 #define LOAD_OFFSET PAGE_OFFSET
23 #include <asm-generic/vmlinux.lds.h>
24 #include <asm/asm-offsets.h> /* Most of the kernel defines are here */
25 #include <asm/mem-layout.h> /* except for page_offset */
26 #include <asm/cache.h> /* and now we're pulling cache line size */
33 See asm-generic/vmlinux.lds.h for expansion of some of these macros.
34 See asm-generic/sections.h for seemingly required labels.
37 #define PAGE_SIZE _PAGE_SIZE
39 /* This LOAD_OFFSET is temporary for debugging on the simulator; it may change
40 for hypervisor pseudo-physical memory. */
45 . = PAGE_OFFSET + LOAD_ADDRESS;
49 INIT_TEXT_SECTION(PAGE_SIZE)
50 PERCPU_SECTION(L1_CACHE_BYTES)
53 . = ALIGN(_PAGE_SIZE);
55 .text : AT(ADDR(.text) - LOAD_OFFSET) {
65 INIT_DATA_SECTION(PAGE_SIZE)
68 RW_DATA_SECTION(32,PAGE_SIZE,PAGE_SIZE)
69 RO_DATA_SECTION(PAGE_SIZE)
75 BSS_SECTION(_PAGE_SIZE, _PAGE_SIZE, _PAGE_SIZE)