1 |
27 |
unneback |
# ====================================================================
|
2 |
|
|
#
|
3 |
|
|
# hal_powerpc_ts1000.cdl
|
4 |
|
|
#
|
5 |
|
|
# PowerPC/TS1000 board HAL package configuration data
|
6 |
|
|
#
|
7 |
|
|
# ====================================================================
|
8 |
|
|
#####ECOSGPLCOPYRIGHTBEGIN####
|
9 |
|
|
## -------------------------------------------
|
10 |
|
|
## This file is part of eCos, the Embedded Configurable Operating System.
|
11 |
|
|
## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
|
12 |
|
|
## Copyright (C) 2002 Gary Thomas
|
13 |
|
|
##
|
14 |
|
|
## eCos is free software; you can redistribute it and/or modify it under
|
15 |
|
|
## the terms of the GNU General Public License as published by the Free
|
16 |
|
|
## Software Foundation; either version 2 or (at your option) any later version.
|
17 |
|
|
##
|
18 |
|
|
## eCos is distributed in the hope that it will be useful, but WITHOUT ANY
|
19 |
|
|
## WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
20 |
|
|
## FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
21 |
|
|
## for more details.
|
22 |
|
|
##
|
23 |
|
|
## You should have received a copy of the GNU General Public License along
|
24 |
|
|
## with eCos; if not, write to the Free Software Foundation, Inc.,
|
25 |
|
|
## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
|
26 |
|
|
##
|
27 |
|
|
## As a special exception, if other files instantiate templates or use macros
|
28 |
|
|
## or inline functions from this file, or you compile this file and link it
|
29 |
|
|
## with other works to produce a work based on this file, this file does not
|
30 |
|
|
## by itself cause the resulting work to be covered by the GNU General Public
|
31 |
|
|
## License. However the source code for this file must still be made available
|
32 |
|
|
## in accordance with section (3) of the GNU General Public License.
|
33 |
|
|
##
|
34 |
|
|
## This exception does not invalidate any other reasons why a work based on
|
35 |
|
|
## this file might be covered by the GNU General Public License.
|
36 |
|
|
##
|
37 |
|
|
## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
|
38 |
|
|
## at http://sources.redhat.com/ecos/ecos-license/
|
39 |
|
|
## -------------------------------------------
|
40 |
|
|
#####ECOSGPLCOPYRIGHTEND####
|
41 |
|
|
# ====================================================================
|
42 |
|
|
######DESCRIPTIONBEGIN####
|
43 |
|
|
#
|
44 |
|
|
# Author(s): jskov
|
45 |
|
|
# Original data: hmt
|
46 |
|
|
# Contributors: gthomas
|
47 |
|
|
# Date: 1999-11-02
|
48 |
|
|
#
|
49 |
|
|
#####DESCRIPTIONEND####
|
50 |
|
|
#
|
51 |
|
|
# ====================================================================
|
52 |
|
|
|
53 |
|
|
cdl_package CYGPKG_HAL_POWERPC_TS1000 {
|
54 |
|
|
display "Allied Telesyn TS1000 board"
|
55 |
|
|
parent CYGPKG_HAL_POWERPC
|
56 |
|
|
requires CYGPKG_HAL_POWERPC_MPC8xx
|
57 |
|
|
define_header hal_powerpc_ts1000.h
|
58 |
|
|
include_dir cyg/hal
|
59 |
|
|
description "
|
60 |
|
|
The TS1000 HAL package provides the support needed to run
|
61 |
|
|
eCos on a Allied Telesyn TS1000 board."
|
62 |
|
|
|
63 |
|
|
compile hal_diag.c hal_aux.c ts1000.S
|
64 |
|
|
|
65 |
|
|
implements CYGINT_HAL_DEBUG_GDB_STUBS
|
66 |
|
|
implements CYGINT_HAL_DEBUG_GDB_STUBS_BREAK
|
67 |
|
|
implements CYGINT_HAL_VIRTUAL_VECTOR_SUPPORT
|
68 |
|
|
implements CYGNUM_HAL_QUICC_SMC1
|
69 |
|
|
|
70 |
|
|
define_proc {
|
71 |
|
|
puts $::cdl_system_header "#define CYGBLD_HAL_TARGET_H "
|
72 |
|
|
puts $::cdl_system_header "#define CYGBLD_HAL_PLATFORM_H "
|
73 |
|
|
|
74 |
|
|
puts $::cdl_header "#define HAL_PLATFORM_CPU \"PowerPC 855\""
|
75 |
|
|
puts $::cdl_header "#define HAL_PLATFORM_BOARD \"Allied Telesyn TS1000\""
|
76 |
|
|
puts $::cdl_header "#define HAL_PLATFORM_EXTRA \"\""
|
77 |
|
|
}
|
78 |
|
|
|
79 |
|
|
cdl_component CYG_HAL_STARTUP {
|
80 |
|
|
display "Startup type"
|
81 |
|
|
flavor data
|
82 |
|
|
legal_values {"RAM" "ROM" "ROMRAM"}
|
83 |
|
|
default_value {"RAM"}
|
84 |
|
|
no_define
|
85 |
|
|
define -file system.h CYG_HAL_STARTUP
|
86 |
|
|
description "
|
87 |
|
|
This option is used to control where the application program will
|
88 |
|
|
run, either from RAM or ROM (flash) memory. ROM based applications
|
89 |
|
|
must be self contained, while RAM applications will typically assume
|
90 |
|
|
the existence of a debug environment, such as GDB stubs."
|
91 |
|
|
}
|
92 |
|
|
|
93 |
|
|
cdl_option CYGHWR_HAL_POWERPC_BOARD_SPEED {
|
94 |
|
|
display "Development board clock speed (MHz)"
|
95 |
|
|
flavor data
|
96 |
|
|
legal_values { 25 50 }
|
97 |
|
|
default_value 50
|
98 |
|
|
description "
|
99 |
|
|
TS1000 Development Boards have various system clock speeds
|
100 |
|
|
depending on the processor fitted. Select the clock speed
|
101 |
|
|
appropriate for your board so that the system can set the serial
|
102 |
|
|
baud rate correctly, amongst other things."
|
103 |
|
|
}
|
104 |
|
|
|
105 |
|
|
# Real-time clock/counter specifics
|
106 |
|
|
cdl_component CYGNUM_HAL_RTC_CONSTANTS {
|
107 |
|
|
display "Real-time clock constants."
|
108 |
|
|
description "
|
109 |
|
|
Period is busclock/16/100."
|
110 |
|
|
flavor none
|
111 |
|
|
|
112 |
|
|
cdl_option CYGNUM_HAL_RTC_NUMERATOR {
|
113 |
|
|
display "Real-time clock numerator"
|
114 |
|
|
flavor data
|
115 |
|
|
calculated 1000000000
|
116 |
|
|
}
|
117 |
|
|
cdl_option CYGNUM_HAL_RTC_DENOMINATOR {
|
118 |
|
|
display "Real-time clock denominator"
|
119 |
|
|
flavor data
|
120 |
|
|
calculated 100
|
121 |
|
|
}
|
122 |
|
|
cdl_option CYGNUM_HAL_RTC_PERIOD {
|
123 |
|
|
display "Real-time clock period"
|
124 |
|
|
flavor data
|
125 |
|
|
calculated { (((CYGHWR_HAL_POWERPC_BOARD_SPEED*1000000)/16)/100) }
|
126 |
|
|
}
|
127 |
|
|
}
|
128 |
|
|
|
129 |
|
|
cdl_component CYGBLD_GLOBAL_OPTIONS {
|
130 |
|
|
display "Global build options"
|
131 |
|
|
flavor none
|
132 |
|
|
description "
|
133 |
|
|
Global build options including control over
|
134 |
|
|
compiler flags, linker flags and choice of toolchain."
|
135 |
|
|
|
136 |
|
|
|
137 |
|
|
parent CYGPKG_NONE
|
138 |
|
|
|
139 |
|
|
cdl_option CYGBLD_GLOBAL_COMMAND_PREFIX {
|
140 |
|
|
display "Global command prefix"
|
141 |
|
|
flavor data
|
142 |
|
|
no_define
|
143 |
|
|
default_value { "powerpc-eabi" }
|
144 |
|
|
description "
|
145 |
|
|
This option specifies the command prefix used when
|
146 |
|
|
invoking the build tools."
|
147 |
|
|
}
|
148 |
|
|
|
149 |
|
|
cdl_option CYGBLD_GLOBAL_CFLAGS {
|
150 |
|
|
display "Global compiler flags"
|
151 |
|
|
flavor data
|
152 |
|
|
no_define
|
153 |
|
|
default_value { "-msoft-float -mcpu=860 -Wall -Wpointer-arith -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc -finit-priority" }
|
154 |
|
|
description "
|
155 |
|
|
This option controls the global compiler flags which
|
156 |
|
|
are used to compile all packages by
|
157 |
|
|
default. Individual packages may define
|
158 |
|
|
options which override these global flags."
|
159 |
|
|
}
|
160 |
|
|
|
161 |
|
|
cdl_option CYGBLD_GLOBAL_LDFLAGS {
|
162 |
|
|
display "Global linker flags"
|
163 |
|
|
flavor data
|
164 |
|
|
no_define
|
165 |
|
|
default_value { "-msoft-float -mcpu=860 -g -nostdlib -Wl,--gc-sections -Wl,-static" }
|
166 |
|
|
description "
|
167 |
|
|
This option controls the global linker flags. Individual
|
168 |
|
|
packages may define options which override these global flags."
|
169 |
|
|
}
|
170 |
|
|
|
171 |
|
|
cdl_option CYGBLD_BUILD_GDB_STUBS {
|
172 |
|
|
display "Build GDB stub ROM image"
|
173 |
|
|
default_value 0
|
174 |
|
|
requires { CYG_HAL_STARTUP == "ROM" }
|
175 |
|
|
requires CYGSEM_HAL_ROM_MONITOR
|
176 |
|
|
requires CYGBLD_BUILD_COMMON_GDB_STUBS
|
177 |
|
|
requires CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
|
178 |
|
|
requires CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
|
179 |
|
|
requires CYGDBG_HAL_DEBUG_GDB_THREAD_SUPPORT
|
180 |
|
|
requires ! CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT
|
181 |
|
|
requires ! CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM
|
182 |
|
|
no_define
|
183 |
|
|
description "
|
184 |
|
|
This option enables the building of the GDB stubs for the
|
185 |
|
|
board. The common HAL controls takes care of most of the
|
186 |
|
|
build process, but the platform CDL takes care of creating
|
187 |
|
|
an S-Record data file suitable for programming using
|
188 |
|
|
the board's EPPC-Bug firmware monitor."
|
189 |
|
|
|
190 |
|
|
make -priority 320 {
|
191 |
|
|
/bin/gdb_module.bin : /bin/gdb_module.img
|
192 |
|
|
$(OBJCOPY) -O srec --change-address=0x02000000 $< $(@:.bin=.srec)
|
193 |
|
|
$(OBJCOPY) -O binary $< $@
|
194 |
|
|
}
|
195 |
|
|
}
|
196 |
|
|
}
|
197 |
|
|
|
198 |
|
|
cdl_component CYGPKG_HAL_POWERPC_TS1000_OPTIONS {
|
199 |
|
|
display "TS1000 build options"
|
200 |
|
|
flavor none
|
201 |
|
|
description "
|
202 |
|
|
Package specific build options including control over
|
203 |
|
|
compiler flags used only in building this package,
|
204 |
|
|
and details of which tests are built."
|
205 |
|
|
|
206 |
|
|
|
207 |
|
|
cdl_option CYGPKG_HAL_POWERPC_TS1000_CFLAGS_ADD {
|
208 |
|
|
display "Additional compiler flags"
|
209 |
|
|
flavor data
|
210 |
|
|
no_define
|
211 |
|
|
default_value { "" }
|
212 |
|
|
description "
|
213 |
|
|
This option modifies the set of compiler flags for
|
214 |
|
|
building the TS1000 HAL. These flags are used in addition
|
215 |
|
|
to the set of global flags."
|
216 |
|
|
}
|
217 |
|
|
|
218 |
|
|
cdl_option CYGPKG_HAL_POWERPC_TS1000_CFLAGS_REMOVE {
|
219 |
|
|
display "Suppressed compiler flags"
|
220 |
|
|
flavor data
|
221 |
|
|
no_define
|
222 |
|
|
default_value { "" }
|
223 |
|
|
description "
|
224 |
|
|
This option modifies the set of compiler flags for
|
225 |
|
|
building the TS1000 HAL. These flags are removed from
|
226 |
|
|
the set of global flags if present."
|
227 |
|
|
}
|
228 |
|
|
|
229 |
|
|
cdl_option CYGPKG_HAL_POWERPC_TS1000_TESTS {
|
230 |
|
|
display "TS1000 tests"
|
231 |
|
|
flavor data
|
232 |
|
|
no_define
|
233 |
|
|
calculated { "tests/ts1000time" }
|
234 |
|
|
description "
|
235 |
|
|
This option specifies the set of tests for the TS1000 HAL."
|
236 |
|
|
}
|
237 |
|
|
}
|
238 |
|
|
|
239 |
|
|
cdl_component CYGHWR_MEMORY_LAYOUT {
|
240 |
|
|
display "Memory layout"
|
241 |
|
|
flavor data
|
242 |
|
|
no_define
|
243 |
|
|
calculated { CYG_HAL_STARTUP == "RAM" ? "powerpc_ts1000_ram" : \
|
244 |
|
|
CYG_HAL_STARTUP == "ROMRAM" ? "powerpc_ts1000_romram" : \
|
245 |
|
|
"powerpc_ts1000_rom" }
|
246 |
|
|
|
247 |
|
|
cdl_option CYGHWR_MEMORY_LAYOUT_LDI {
|
248 |
|
|
display "Memory layout linker script fragment"
|
249 |
|
|
flavor data
|
250 |
|
|
no_define
|
251 |
|
|
define -file system.h CYGHWR_MEMORY_LAYOUT_LDI
|
252 |
|
|
calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
|
253 |
|
|
CYG_HAL_STARTUP == "ROMRAM" ? "" : \
|
254 |
|
|
"" }
|
255 |
|
|
}
|
256 |
|
|
|
257 |
|
|
cdl_option CYGHWR_MEMORY_LAYOUT_H {
|
258 |
|
|
display "Memory layout header file"
|
259 |
|
|
flavor data
|
260 |
|
|
no_define
|
261 |
|
|
define -file system.h CYGHWR_MEMORY_LAYOUT_H
|
262 |
|
|
calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
|
263 |
|
|
CYG_HAL_STARTUP == "ROMRAM" ? "" : \
|
264 |
|
|
"" }
|
265 |
|
|
}
|
266 |
|
|
}
|
267 |
|
|
|
268 |
|
|
cdl_option CYGSEM_HAL_ROM_MONITOR {
|
269 |
|
|
display "Behave as a ROM monitor"
|
270 |
|
|
flavor bool
|
271 |
|
|
default_value 0
|
272 |
|
|
parent CYGPKG_HAL_ROM_MONITOR
|
273 |
|
|
requires { CYG_HAL_STARTUP == "ROM" || CYG_HAL_STARTUP == "ROMRAM" }
|
274 |
|
|
description "
|
275 |
|
|
Enable this option if this program is to be used as a ROM monitor,
|
276 |
|
|
i.e. applications will be loaded into RAM on the board, and this
|
277 |
|
|
ROM monitor may process exceptions or interrupts generated from the
|
278 |
|
|
application. This enables features such as utilizing a separate
|
279 |
|
|
interrupt stack when exceptions are generated."
|
280 |
|
|
}
|
281 |
|
|
|
282 |
|
|
cdl_component CYGPKG_REDBOOT_HAL_OPTIONS {
|
283 |
|
|
display "Redboot HAL options"
|
284 |
|
|
flavor none
|
285 |
|
|
no_define
|
286 |
|
|
parent CYGPKG_REDBOOT
|
287 |
|
|
active_if CYGPKG_REDBOOT
|
288 |
|
|
description "
|
289 |
|
|
This option lists the target's requirements for a valid Redboot
|
290 |
|
|
configuration."
|
291 |
|
|
|
292 |
|
|
cdl_option CYGSEM_REDBOOT_HAL_LINUX_BOOT {
|
293 |
|
|
active_if CYGBLD_BUILD_REDBOOT_WITH_EXEC
|
294 |
|
|
display "Support booting Linux via RedBoot"
|
295 |
|
|
flavor bool
|
296 |
|
|
default_value 0
|
297 |
|
|
description "
|
298 |
|
|
This option enables RedBoot to support booting of a Linux kernel."
|
299 |
|
|
|
300 |
|
|
compile -library=libextras.a redboot_linux_exec.c
|
301 |
|
|
}
|
302 |
|
|
|
303 |
|
|
cdl_option CYGBLD_BUILD_REDBOOT_BIN {
|
304 |
|
|
display "Build Redboot ROM binary image"
|
305 |
|
|
active_if CYGBLD_BUILD_REDBOOT
|
306 |
|
|
default_value 1
|
307 |
|
|
no_define
|
308 |
|
|
description "This option enables the conversion of the Redboot ELF
|
309 |
|
|
image to a binary image suitable for ROM programming."
|
310 |
|
|
|
311 |
|
|
# compile -library=libextras.a redboot_cmds.c
|
312 |
|
|
|
313 |
|
|
make -priority 325 {
|
314 |
|
|
/bin/redboot.bin : /bin/redboot.elf
|
315 |
|
|
$(OBJCOPY) -O srec $< $(@:.bin=.srec)
|
316 |
|
|
$(OBJCOPY) -O binary $< $@
|
317 |
|
|
}
|
318 |
|
|
}
|
319 |
|
|
}
|
320 |
|
|
}
|