OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [rtos/] [rtems/] [c/] [src/] [lib/] [libbsp/] [i386/] [ts_386ex/] [startup/] [linkcmds] - Blame information for rev 493

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 30 unneback
/*
2
 *  This file contains directives for the GNU linker which are specific
3
 *  to the Technologic Systems TS-1325 (i386ex) board.
4
 *
5
 *  Copyright (c) 1989-1998.
6
 *  On-Line Applications Research Corporation (OAR).
7
 *  Copyright assigned to U.S. Government, 1994.
8
 *
9
 *  The license and distribution terms for this file may be
10
 *  found in the file LICENSE in this distribution or at
11
 *  http://www.OARcorp.com/rtems/license.html.
12
 *
13
 *  $Id: linkcmds,v 1.2 2001-09-27 11:59:50 chris Exp $
14
 *
15
 * Memory layout:
16
 *
17
 * 0x0008000 ->    ...    : initial section ( init 386ex, goto protected mode)
18
 *    ...    ->    ...    : text section ( executable code )
19
 *    ...    -> 0x00A0000 : data section ( initialized storage )
20
 * 0x0100000 -> 0x0200000 : bss section, stack space, heap storage
21
 */
22
 
23
        ENTRY(_init_i386ex) ;
24
 
25
SECTIONS
26
{
27
 
28
/***************************************************************************
29
 * initial section:
30
 *
31
 * This subsection of ".text" is the first in memory, and executed by the DOS
32
 * loader. It initializes the i386ex, sets up the gdt in RAM, loads the gdt,
33
 * jumps to protected mode, loads the idt, zeros the bss section, sets up
34
 * the stack and calls the rest of the RTEMS initialization.
35
 ***************************************************************************/
36
 
37
        _DOS_ld_addr    =       0x0008000 ;
38
 
39
/***************************************************************************
40
 * text section:
41
 *
42
 * Nobody here but us opcodes.
43
 ***************************************************************************/
44
 
45
        .text _DOS_ld_addr :
46
        {
47
        CREATE_OBJECT_SYMBOLS
48
        text_start = . ;
49
        _text_start = . ;
50
 
51
        *(.initial);
52
        . = ALIGN(0x20);
53
 
54
        *(.text );
55
        . = ALIGN (0x20);
56
 
57
        *(.eh_frame)
58
        . = ALIGN (0x20);
59
 
60
        *(.gnu.linkonce.t*)
61
        . = ALIGN(0x20);
62
 
63
        /*
64
         * C++ constructors
65
         */
66
 
67
        __CTOR_LIST__ = .;
68
        LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2)
69
        *(.ctors)
70
        LONG(0)
71
        __CTOR_END__ = .;
72
        . = ALIGN (4) ;
73
        __DTOR_LIST__ = .;
74
        LONG((__DTOR_END__ - __DTOR_LIST__) / 4 - 2)
75
        *(.dtors)
76
        LONG(0)
77
        __DTOR_END__ = .;
78
 
79
        _rodata_start = . ;
80
        *(.rodata)
81
        . = ALIGN(0x20);
82
        _erodata = .;
83
 
84
        *(.gnu.linkonce.r*)
85
        . = ALIGN(0x20);
86
        _endtext = . ;
87
        }
88
 
89
/***************************************************************************
90
 * ctor/dtor sections:
91
 *
92
 * These sections house the  global constructors and destructors.
93
 ***************************************************************************/
94
 
95
        .init BLOCK(0x20) :
96
        {
97
        *(.init)
98
        } = 0x9090
99
 
100
        .fini BLOCK(0x20) :
101
        {
102
        *(.fini)
103
        } = 0x9090
104
 
105
/***************************************************************************
106
 * data section:
107
 *
108
 * This section defines the location of the data section in RAM.
109
 ***************************************************************************/
110
 
111
        .data  BLOCK(0x20) :
112
        {
113
        _sdata = .;
114
        *(.data);
115
        . = ALIGN(0x20);
116
        *(.gnu.linkonce.d*)
117
        . = ALIGN(0x20);
118
        *(.gcc_except_table)
119
        . = ALIGN(0x20);
120
        _edata = .;
121
        }
122
        _data_size        = _edata - _sdata ;
123
 
124
/***************************************************************************
125
 * bss section:
126
 *
127
 * The bss section is the first section in extended RAM ( > 1MB).
128
 ***************************************************************************/
129
 
130
        .bss 0x100000 (NOLOAD) :
131
        {
132
        _bss_start = .;
133
        *(.bss);
134
        *(COMMON);
135
        _ebss = ALIGN(0x20);
136
        }
137
        _bss_size   = _ebss - _bss_start ;
138
 
139
/***************************************************************************
140
 * discard section:
141
 *
142
 * This section is used to throw away stuff we don't want.
143
 ***************************************************************************/
144
 
145
        /DISCARD/ :
146
        {
147
        *(.comment);
148
        *(.note);
149
        }
150
 
151
/***************************************************************************
152
 * General variables:
153
 *
154
 * The stack_size variable is customizable here.  The heap is located directly
155
 * after the stack in RAM.  A routine within bspstart.c uses these variables
156
 * to ensure that the heap used by RTEMS is as large as the RAM remaining
157
 * after all workspace configurations are complete.
158
 ***************************************************************************/
159
 
160
        stack_size  = 0x8000 ;
161
        stack_origin = _ebss + stack_size ;
162
        heap_bottom  = stack_origin + 4 ;
163
 
164
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.