source: rtems/c/src/lib/libbsp/m68k/gen68360/startup/linkcmds.prom @ e2d79559

4.104.114.84.95
Last change on this file since e2d79559 was e2d79559, checked in by Joel Sherrill <joel.sherrill@…>, on Apr 9, 1997 at 2:05:50 PM

Added ka9q tcpip stack and network driver for the gen68360. This effort
was done based on the 3.6.0 release and had to be autoconf'ed locally.
It is turned on is the bsp enables it and it is not explicitly disabled
via the configure option --disable-tcpip. As many warnings as possible
were removed locally after the code was merged. Only the gen68360
and mvme136 bsps were compiled this way.

The ka9q port and network driver were submitted by Eric Norum
(eric@…).

The network demo programs are not included in the tree at this point.

  • Property mode set to 100644
File size: 4.1 KB
Line 
1/*
2 * This file contains GNU linker directives for a generic MC68360 board.
3 * Variations in hardware type and dynamic memory size can be made
4 * by overriding some values with linker command-line arguments.
5 *
6 * These linker directives are for producing a BOOTP PROM.
7 * To create the PROM image from the linker output you must use objcopy
8 * (--adjust-section-vma) to place the data segment at the end of the text
9 * segment in the PROM.  The start-up code takes care of copying this region
10 * to RAM.
11 *
12 * Saskatchewan Accelerator Laboratory
13 * University of Saskatchewan
14 * Saskatoon, Saskatchewan, CANADA
15 * eric@skatter.usask.ca
16 *
17 *  $Id$
18 */
19
20/*
21 * a.out format doesn't handle prom images very well
22 */
23OUTPUT_FORMAT(coff-m68k)
24
25/*
26 * Declare some sizes.
27 * XXX: The assignment of ". += XyzSize;" fails in older gld's if the
28 *      number used there is not constant.  If this happens to you, edit
29 *      the lines marked XXX below to use a constant value.
30 */
31RamSize = DEFINED(RamSize) ? RamSize : 4M;
32HeapSize = DEFINED(HeapSize) ? HeapSize : 0x10000;
33StackSize = DEFINED(StackSize) ? StackSize : 0x1000;
34
35/*
36 * Declare hardware type
37 */
38MC68360HardwareTypeMotorolaGeneric = 0;
39MC68360HardwareTypeAtlasHSB = 1;
40MC68360HardwareType = DEFINED(MC68360HardwareType) ? MC68360HardwareType : 0;
41
42/*
43 * Declare on-board memory.
44 * It would be nice if the ram length could be given as
45 * LENGTH=RamSize, but gld doesn't allow non-constant
46 * values in the LENGTH expression. 
47 */
48MEMORY {
49          ram : ORIGIN = 0x00000000, LENGTH = 64M
50          rom : ORIGIN = 0xFF000000, LENGTH = 1M
51        dpram : ORIGIN = 0xFE000000, LENGTH = 8k
52}
53
54/*
55 * Declare low-order three octets of Ethernet address.
56 */
57ETHERNET_ADDRESS = DEFINED(ETHERNET_ADDRESS) ? ETHERNET_ADDRESS : 0xDEAD12;
58
59/*
60 * Declare hardware type.
61 * Acceptable values are:
62 *      0 - Generic system as described in the MC68360 User's Manual
63 *          (MC68360UM/AD Rev. 1).
64 *      1 - ATLAS Computer Equipment Incorporated ACE360/HSB.
65 */
66MC68360HardwareType = DEFINED(MC68360HardwareType) ? MC68360HardwareType : 0;
67
68/*
69 * Load objects
70 */
71SECTIONS {
72        /*
73         * Hardware variations
74         */
75        _RamSize = RamSize;
76        __RamSize = RamSize;
77        _MC68360HardwareType = MC68360HardwareType;
78        __MC68360HardwareType = MC68360HardwareType;
79        _MC68360HardwareTypeMotorolaGeneric = MC68360HardwareTypeMotorolaGeneric;
80        __MC68360HardwareTypeMotorolaGeneric = MC68360HardwareTypeMotorolaGeneric;
81        _MC68360HardwareTypeAtlasHSB = MC68360HardwareTypeAtlasHSB;
82        __MC68360HardwareTypeAtlasHSB = MC68360HardwareTypeAtlasHSB;
83
84        /*
85         * Boot PROM
86         */
87        rom : {
88                _RomBase = .;
89                __RomBase = .;
90        } >rom
91
92        /*
93         * Dynamic RAM
94         */
95        ram : {
96                _RamBase = .;
97                __RamBase = .;
98        } >ram
99
100        /*
101         * Text, data and bss segments
102         */
103        .text : {
104                CREATE_OBJECT_SYMBOLS
105                *(.text)
106                . = ALIGN (16);
107                etext = .;
108                _etext = .;
109        } >rom
110        .data : {
111                copy_start = .;
112                *(.data)
113                . = ALIGN (16);
114                _edata = .;
115                copy_end = .;
116        } >ram
117        .bss : {
118                M68Kvec = .;
119                _M68Kvec = .;
120                . += (256 * 4);
121                clear_start = .;
122                *(.bss)
123                *(COMMON)
124                . = ALIGN (16);
125                _end = .;
126
127                _HeapStart = .;
128                __HeapStart = .;
129                . += HeapSize;  /* XXX -- Old gld can't handle this */
130                . += StackSize; /* XXX -- Old gld can't handle this */
131                /* . += 0x10000; */ /* HeapSize for old gld */
132                /* . += 0x1000;  */ /* StackSize for old gld */
133                . = ALIGN (16);
134                stack_init = .;
135                clear_end = .;
136
137                _WorkspaceBase = .;
138                __WorkspaceBase = .;
139        } >ram
140
141        /*
142         * On-chip memory/peripherals
143         */
144        dpram : {
145                m360 = .;
146                _m360 = .;
147                . += (8 * 1024);
148
149        } >dpram
150}
Note: See TracBrowser for help on using the repository browser.