OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [rtos/] [ecos-2.0/] [packages/] [hal/] [sh/] [edk7708/] [v2_0/] [cdl/] [hal_sh_edk7708.cdl] - Blame information for rev 249

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

Line No. Rev Author Line
1 27 unneback
# ====================================================================
2
#
3
#      hal_sh_edk7708.cdl
4
#
5
#      EDK7708 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
##
13
## eCos is free software; you can redistribute it and/or modify it under
14
## the terms of the GNU General Public License as published by the Free
15
## Software Foundation; either version 2 or (at your option) any later version.
16
##
17
## eCos is distributed in the hope that it will be useful, but WITHOUT ANY
18
## WARRANTY; without even the implied warranty of MERCHANTABILITY or
19
## FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
20
## for more details.
21
##
22
## You should have received a copy of the GNU General Public License along
23
## with eCos; if not, write to the Free Software Foundation, Inc.,
24
## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
25
##
26
## As a special exception, if other files instantiate templates or use macros
27
## or inline functions from this file, or you compile this file and link it
28
## with other works to produce a work based on this file, this file does not
29
## by itself cause the resulting work to be covered by the GNU General Public
30
## License. However the source code for this file must still be made available
31
## in accordance with section (3) of the GNU General Public License.
32
##
33
## This exception does not invalidate any other reasons why a work based on
34
## this file might be covered by the GNU General Public License.
35
##
36
## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
37
## at http://sources.redhat.com/ecos/ecos-license/
38
## -------------------------------------------
39
#####ECOSGPLCOPYRIGHTEND####
40
# ====================================================================
41
######DESCRIPTIONBEGIN####
42
#
43
# Author(s):      jskov
44
# Original data:  jskov
45
# Contributors:
46
# Date:           1999-10-29
47
#
48
#####DESCRIPTIONEND####
49
#
50
# ====================================================================
51
 
52
cdl_package CYGPKG_HAL_SH_EDK7708 {
53
    display       "Hitachi EDK/SH7708 board"
54
    parent        CYGPKG_HAL_SH
55
    requires      CYGPKG_HAL_SH_7708
56
    define_header hal_sh_edk7708.h
57
    include_dir   cyg/hal
58
    description   "
59
        The edk HAL package provides the support needed to run
60
        eCos on a Hitachi SH3 EDK7708 board."
61
 
62
    compile       hal_diag.c plf_misc.c
63
 
64
    implements    CYGINT_HAL_DEBUG_GDB_STUBS
65
    implements    CYGINT_HAL_DEBUG_GDB_STUBS_BREAK
66
    implements    CYGINT_HAL_VIRTUAL_VECTOR_SUPPORT
67
 
68
    define_proc {
69
        puts $::cdl_system_header "#define CYGBLD_HAL_TARGET_H   "
70
        puts $::cdl_system_header "#define CYGBLD_HAL_PLATFORM_H "
71
 
72
        puts $::cdl_header "#define CYGNUM_HAL_SH_SH3_SCI_PORTS 1"
73
        puts $::cdl_header "#define CYGHWR_HAL_VSR_TABLE 0x88000000"
74
        puts $::cdl_header "#define CYGHWR_HAL_VECTOR_TABLE 0x88000100"
75
    }
76
 
77
    cdl_component CYG_HAL_STARTUP {
78
        display       "Startup type"
79
        flavor        data
80
        legal_values  {"RAM" "ROM" "ROMRAM"}
81
        default_value {"RAM"}
82
        no_define
83
        define -file system.h CYG_HAL_STARTUP
84
        description   "
85
           When targetting the EDK7708 board it is possible to build
86
           the system for either RAM bootstrap or ROM bootstrap.
87
           RAM bootstrap generally requires that the board
88
           is equipped with ROMs containing a suitable ROM monitor or
89
           equivalent software that allows GDB to download the eCos
90
           application on to the board. The ROM bootstrap typically
91
           requires that the eCos application be blown into EPROMs or
92
           equivalent technology.  ROMRAM bootstrap is similar to ROM
93
           bootstrap, but everything is copied to RAM before execution
94
           starts thus improving performace, but at the cost of an
95
           increased RAM footprint."
96
    }
97
 
98
    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS {
99
        display      "Number of communication channels on the board"
100
        flavor       data
101
        calculated   1
102
    }
103
 
104
    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_DEBUG_CHANNEL {
105
        display          "Debug serial port"
106
        flavor data
107
        legal_values     0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
108
        default_value    0
109
        description      "
110
           The EDK/7708 board has only one serial port. This option
111
           chooses which port will be used to connect to a host
112
           running GDB."
113
    }
114
 
115
    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL {
116
        display          "Diagnostic serial port"
117
        flavor data
118
        legal_values     0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
119
        default_value    0
120
        description      "
121
           The EDK/7708 board has only one serial port.  This option
122
           chooses which port will be used for diagnostic output."
123
    }
124
 
125
    cdl_component CYGHWR_HAL_SH_PLF_CLOCK_SETTINGS {
126
        display          "SH on-chip platform clock controls"
127
        description      "
128
            The various clocks used by the system are derived from
129
            these options."
130
        flavor        none
131
        no_define
132
 
133
        cdl_option CYGHWR_HAL_SH_OOC_XTAL {
134
            display          "SH clock crystal"
135
            flavor           data
136
            legal_values     8000000 to 50000000
137
            default_value    15000000
138
            no_define
139
            description      "
140
                This option specifies the frequency of the crystal all
141
                other clocks are derived from."
142
        }
143
 
144
        cdl_option CYGHWR_HAL_SH_OOC_PLL_1 {
145
            display          "SH clock PLL circuit 1"
146
            flavor           data
147
            default_value    1
148
            legal_values     { 0 1 2 4 }
149
            description      "
150
                This selects the multiplication factor provided by
151
                PLL1. If PLL1 is disabled via CAP1, this option should
152
                be set to zero."
153
        }
154
 
155
        cdl_option CYGHWR_HAL_SH_OOC_PLL_2 {
156
            display          "SH clock PLL circuit 2"
157
            flavor           data
158
            default_value    4
159
            legal_values     { 0 1 4 }
160
            no_define
161
            description      "
162
                This selects the multiplication factor provided by
163
                PLL2. If PLL2 is disabled via CAP2, this option should
164
                be set to zero."
165
        }
166
 
167
        cdl_option CYGHWR_HAL_SH_OOC_DIVIDER_1 {
168
            display          "SH clock divider 1"
169
            flavor           data
170
            default_value    1
171
            legal_values     { 1 2 3 4 }
172
            description      "
173
                This divider option affects the CPU core clock."
174
        }
175
 
176
        cdl_option CYGHWR_HAL_SH_OOC_DIVIDER_2 {
177
            display          "SH clock divider 2"
178
            flavor           data
179
            default_value    4
180
            legal_values     { 1 2 3 4 }
181
            description      "
182
                This divider option affects the peripheral clock."
183
        }
184
 
185
        cdl_option CYGHWR_HAL_SH_OOC_CLOCK_MODE {
186
            display          "SH clock mode"
187
            flavor           data
188
            default_value    2
189
            legal_values     { 0 1 2 3 4 7 }
190
            description      "
191
                This option must mirror the clock mode hardwired on
192
                the MD0-MD2 pins of the CPU in order to correctly
193
                initialize the FRQCR register."
194
        }
195
    }
196
 
197
    cdl_component CYGBLD_GLOBAL_OPTIONS {
198
        display "Global build options"
199
        flavor  none
200
        parent  CYGPKG_NONE
201
        no_define
202
        description   "
203
            Global build options including control over
204
            compiler flags, linker flags and choice of toolchain."
205
 
206
 
207
        cdl_option CYGBLD_GLOBAL_COMMAND_PREFIX {
208
            display "Global command prefix"
209
            flavor  data
210
            no_define
211
            default_value { "sh-elf" }
212
            description "
213
                This option specifies the command prefix used when
214
                invoking the build tools."
215
        }
216
 
217
        cdl_option CYGBLD_GLOBAL_CFLAGS {
218
            display "Global compiler flags"
219
            flavor  data
220
            no_define
221
              default_value { CYGHWR_HAL_SH_BIGENDIAN ? "-mb -m3 -Wall -Wpointer-arith -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc -finit-priority" : "-ml -m3 -Wall -Wpointer-arith -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc -finit-priority" }
222
            description   "
223
                This option controls the global compiler flags which
224
                are used to compile all packages by
225
                default. Individual packages may define
226
                options which override these global flags."
227
        }
228
 
229
        cdl_option CYGBLD_GLOBAL_LDFLAGS {
230
            display "Global linker flags"
231
            flavor  data
232
            no_define
233
            default_value { CYGHWR_HAL_SH_BIGENDIAN ? "-mb -m3 -nostdlib -Wl,--gc-sections -Wl,-static" : "-ml -m3 -nostdlib -Wl,--gc-sections -Wl,-static" }
234
            description   "
235
                This option controls the global linker flags. Individual
236
                packages may define options which override these global flags."
237
        }
238
 
239
        cdl_option CYGBLD_BUILD_GDB_STUBS {
240
            display "Build GDB stub ROM image"
241
            default_value 0
242
            requires { CYG_HAL_STARTUP == "ROM" }
243
            requires CYGSEM_HAL_ROM_MONITOR
244
            requires CYGBLD_BUILD_COMMON_GDB_STUBS
245
            requires CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
246
            requires CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
247
            requires CYGDBG_HAL_DEBUG_GDB_THREAD_SUPPORT
248
            requires ! CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT
249
            requires ! CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM
250
            no_define
251
            description "
252
                This option enables the building of the GDB stubs for the
253
                board. The common HAL controls takes care of most of the
254
                build process, but the final conversion from ELF image to
255
                binary data is handled by the platform CDL, allowing
256
                relocation of the data if necessary."
257
 
258
            make -priority 320 {
259
                /bin/gdb_module.bin : /bin/gdb_module.img
260
                $(OBJCOPY) -O binary $< $@
261
            }
262
        }
263
    }
264
 
265
    cdl_component CYGHWR_MEMORY_LAYOUT {
266
        display "Memory layout"
267
        flavor data
268
        no_define
269
        calculated { CYG_HAL_STARTUP == "RAM" ? "sh_edk7708_ram" : \
270
                     CYG_HAL_STARTUP == "ROM" ? "sh_edk7708_rom" : \
271
                                                "sh_edk7708_romram" }
272
 
273
        cdl_option CYGHWR_MEMORY_LAYOUT_LDI {
274
            display "Memory layout linker script fragment"
275
            flavor data
276
            no_define
277
            define -file system.h CYGHWR_MEMORY_LAYOUT_LDI
278
            calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
279
                         CYG_HAL_STARTUP == "ROM" ? "" : \
280
                                                    "" }
281
        }
282
 
283
        cdl_option CYGHWR_MEMORY_LAYOUT_H {
284
            display "Memory layout header file"
285
            flavor data
286
            no_define
287
            define -file system.h CYGHWR_MEMORY_LAYOUT_H
288
            calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
289
                         CYG_HAL_STARTUP == "ROM" ? "" : \
290
                                                    "" }
291
        }
292
    }
293
 
294
    cdl_option CYGSEM_HAL_USE_ROM_MONITOR {
295
        display       "Work with a ROM monitor"
296
        flavor        booldata
297
        legal_values  { "GDB_stubs" }
298
        default_value { CYG_HAL_STARTUP == "RAM" ? "GDB_stubs" : 0 }
299
        requires      { CYG_HAL_STARTUP == "RAM" }
300
        parent        CYGPKG_HAL_ROM_MONITOR
301
        description   "
302
            Support can be enabled for boot ROMs or ROM monitors which contain
303
            GDB stubs. This support changes various eCos semantics such as
304
            the encoding of diagnostic output, and the overriding of hardware
305
            interrupt vectors."
306
    }
307
 
308
    cdl_option CYGSEM_HAL_ROM_MONITOR {
309
        display       "Behave as a ROM monitor"
310
        flavor        bool
311
        default_value 0
312
        parent        CYGPKG_HAL_ROM_MONITOR
313
        requires      { CYG_HAL_STARTUP == "ROM" }
314
        description   "
315
            Enable this option if this program is to be used as a ROM monitor,
316
            i.e. applications will be loaded into RAM on the board, and this
317
            ROM monitor may process exceptions or interrupts generated from the
318
            application. This enables features such as utilizing a separate
319
            interrupt stack when exceptions are generated."
320
    }
321
 
322
    cdl_component CYGPKG_REDBOOT_HAL_OPTIONS {
323
        display       "Redboot HAL options"
324
        flavor        none
325
        no_define
326
        parent        CYGPKG_REDBOOT
327
        active_if     CYGPKG_REDBOOT
328
        description   "
329
            This option lists the target's requirements for a valid Redboot
330
            configuration."
331
 
332
        cdl_option CYGBLD_BUILD_REDBOOT_BIN {
333
            display       "Build Redboot ROM binary image"
334
            active_if     CYGBLD_BUILD_REDBOOT
335
            default_value 1
336
            no_define
337
            description "This option enables the conversion of the Redboot ELF
338
                         image to a binary image suitable for ROM programming."
339
 
340
            make -priority 325 {
341
                /bin/redboot.bin : /bin/redboot.elf
342
                $(OBJCOPY) --strip-debug $< $(@:.bin=.img)
343
                $(OBJCOPY) -O srec $< $(@:.bin=.srec)
344
                $(OBJCOPY) -O binary $< $@
345
            }
346
        }
347
    }
348
}

powered by: WebSVN 2.1.0

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