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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [rtos/] [ecos-3.0/] [packages/] [hal/] [arm/] [arm9/] [innovator/] [current/] [cdl/] [hal_arm_arm9_innovator.cdl] - Blame information for rev 786

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 786 skrzyp
# ====================================================================
2
#
3
#      hal_arm_arm9_innovator.cdl
4
#
5
#      TI Innovator platform 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 Free Software Foundation, 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
16
## version.
17
##
18
## eCos is distributed in the hope that it will be useful, but WITHOUT
19
## ANY 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
24
## along with eCos; if not, write to the Free Software Foundation, Inc.,
25
## 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
26
##
27
## As a special exception, if other files instantiate templates or use
28
## macros or inline functions from this file, or you compile this file
29
## and link it with other works to produce a work based on this file,
30
## this file does not by itself cause the resulting work to be covered by
31
## the GNU General Public License. However the source code for this file
32
## must still be made available in accordance with section (3) of the GNU
33
## General Public License v2.
34
##
35
## This exception does not invalidate any other reasons why a work based
36
## on this file might be covered by the GNU General Public License.
37
## -------------------------------------------
38
## ####ECOSGPLCOPYRIGHTEND####
39
# ====================================================================
40
######DESCRIPTIONBEGIN####
41
#
42
# Author(s):      Patrick Doyle 
43
# Contributors:   Patrick Doyle 
44
# Date:           2002-11-22
45
#
46
#####DESCRIPTIONEND####
47
#
48
# ====================================================================
49
cdl_package CYGPKG_HAL_ARM_ARM9_INNOVATOR {
50
    display       "Innovator"
51
    parent        CYGPKG_HAL_ARM_ARM9
52
    requires      CYGPKG_HAL_ARM_ARM9_ARM925T
53
    hardware
54
    include_dir   cyg/hal
55
    define_header hal_arm_arm9_innovator.h
56
    description   "
57
        This HAL platform package provides generic
58
        support for the OMAP Innovator platform."
59
 
60
    compile       innovator_misc.c hal_diag.c
61
 
62
    implements    CYGINT_HAL_DEBUG_GDB_STUBS
63
    implements    CYGINT_HAL_DEBUG_GDB_STUBS_BREAK
64
    implements    CYGINT_HAL_VIRTUAL_VECTOR_SUPPORT
65
 
66
    define_proc {
67
        puts $::cdl_system_header "#define CYGBLD_HAL_TARGET_H   "
68
        puts $::cdl_system_header "#define CYGBLD_HAL_VARIANT_H  "
69
        puts $::cdl_system_header "#define CYGBLD_HAL_PLATFORM_H "
70
        puts $::cdl_header "#define HAL_PLATFORM_CPU    \"ARM9\""
71
        puts $::cdl_header "#define HAL_PLATFORM_BOARD  \"Innovator\""
72
        puts $::cdl_header "#define HAL_PLATFORM_EXTRA  \"\""
73
        puts $::cdl_header "#define HAL_ARCH_PROGRAM_NEW_STACK innovator_program_new_stack"
74
        puts $::cdl_header "#define HAL_PLATFORM_MACHINE_TYPE  234"
75
 
76
    }
77
 
78
    cdl_component CYG_HAL_STARTUP {
79
        display       "Startup type"
80
        flavor        data
81
        default_value {"RAM"}
82
        legal_values  {"RAM" "ROM" }
83
        no_define
84
        define -file system.h CYG_HAL_STARTUP
85
        description   "
86
           When targetting the Innovator it is possible to build
87
           the system for either RAM bootstrap or ROM bootstrap(s). Select
88
           'RAM' when building programs to load into RAM using RedBoot.
89
           Select 'ROM' when building a stand-alone application
90
           which will be put into ROM, or for the special cases of
91
           building the eCos GDB stubs or RedBoot."
92
 
93
        cdl_option CYGPRI_HAL_ROM_MLT {
94
            display       "Memory Layout for ROM Startup"
95
            flavor        data
96
            legal_values  {"FLASH" "SRAM"}
97
            default_value {"FLASH"}
98
            description   "
99
                This option selects which memory layout file should be
100
                used when configuring the Innovator for ROM startup.
101
                The FLASH option selects the memory layout for an image
102
                stored at the beginning of the FLASH.  It should be
103
                used almost all of the time.
104
 
105
                The SRAM option is used to place the ROM image in
106
                internal SRAM.  It may be used in order to test startup
107
                code without burning the code into FLASH first." }
108
    }
109
 
110
    # Both PLLs are in bypass mode on startup.
111
    # FIXME: Add proper configury
112
    cdl_option CYGNUM_HAL_ARM_INNOVATOR_CPU_CLOCK {
113
        display       "CPU bus speed"
114
        flavor        data
115
        calculated    { 60000000 }
116
        description   "
117
            This is the actual CPU operating frequency.  Someday you
118
            might be able to change this here."
119
    }
120
 
121
#    cdl_option CYGNUM_HAL_ARM_INNOVATOR_PERIPHERAL_CLOCK {
122
#        display       "Peripheral bus speed"
123
#        flavor        data
124
#        calculated    { CYGNUM_HAL_ARM_INNOVATOR_CPU_CLOCK / 2 }
125
#        description   "
126
#            This is the peripheral bus operating frequency
127
#           (Traffic Controller)."
128
#    }
129
#
130
#    cdl_option CYGNUM_HAL_ARM_INNOVATOR_TIMER_PRESCALE {
131
#        display       "Timer prescale"
132
#        flavor        data
133
#        legal_values  0 to 255
134
#        default_value 16
135
#        description   "
136
#            This is the prescale value used on the clock used to drive
137
#            the kernel counter. Note that some parts of the code may fail
138
#            if this is changed due to over/underflows of expressions."
139
#    }
140
#
141
#    # Real-time clock/counter specifics
142
#    cdl_component CYGNUM_HAL_RTC_CONSTANTS {
143
#        display       "Real-time clock constants.  WARNING -- the Real Time Clock is not fully supported (if at all) yet."
144
#        flavor        none
145
#        no_define
146
#
147
#        cdl_option CYGNUM_HAL_RTC_NUMERATOR {
148
#            display       "Real-time clock numerator"
149
#            flavor        data
150
#            calculated    1000000000
151
#        }
152
#        cdl_option CYGNUM_HAL_RTC_DENOMINATOR {
153
#            display       "Real-time clock denominator"
154
#            flavor        data
155
#            calculated    100
156
#        }
157
#        cdl_option CYGNUM_HAL_RTC_PERIOD {
158
#            display       "Real-time clock period"
159
#            flavor        data
160
#           calculated    1
161
##            calculated    (CYGNUM_HAL_ARM_INNOVATOR_PERIPHERAL_CLOCK/(CYGNUM_HAL_ARM_INNOVATOR_TIMER_PRESCALE*CYGNUM_HAL_RTC_DENOMINATOR))-1
162
#        }
163
#    }
164
#
165
#    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_BAUD {
166
#        display       "Diagnostic serial port baud rate"
167
#        flavor        data
168
#        legal_values  9600 19200 38400 57600 115200
169
#        default_value 115200
170
#        description   "
171
#            This option selects the baud rate used for the diagnostic port.
172
#            Note: this should match the value chosen for the GDB port if the
173
#            diagnostic and GDB port are the same."
174
#    }
175
#
176
#    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_DEBUG_CHANNEL_BAUD {
177
#        display       "GDB serial port baud rate"
178
#        flavor        data
179
#        legal_values  9600 19200 38400 57600 115200
180
#        default_value 115200
181
#        description   "
182
#            This option selects the baud rate used for the diagnostic port.
183
#            Note: this should match the value chosen for the GDB port if the
184
#            diagnostic and GDB port are the same."
185
#    }
186
#
187
    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS {
188
        display      "Number of communication channels on the board"
189
        flavor       data
190
        calculated   1
191
    }
192
 
193
    cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_DEBUG_CHANNEL {
194
        display          "Debug serial port"
195
        active_if        CYGPRI_HAL_VIRTUAL_VECTOR_DEBUG_CHANNEL_CONFIGURABLE
196
        flavor data
197
        legal_values     0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
198
        default_value    0
199
        description      "
200
            The Innovator has two serial ports.  When we add support
201
            for the second one, you will be able to choose which one is
202
            used to connect to a host running GDB."
203
     }
204
 
205
     cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_DEFAULT {
206
         display      "Default console channel."
207
         flavor       data
208
         legal_values     0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
209
         calculated   0
210
     }
211
 
212
     cdl_option CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL {
213
         display          "Diagnostic serial port"
214
         active_if        CYGPRI_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_CONFIGURABLE
215
         flavor data
216
         legal_values     0 to CYGNUM_HAL_VIRTUAL_VECTOR_COMM_CHANNELS-1
217
         default_value    CYGNUM_HAL_VIRTUAL_VECTOR_CONSOLE_CHANNEL_DEFAULT
218
         description      "
219
            The Innovator has two serial ports.  When we add support
220
            for the second one, you will be able to choose which one is
221
            used for diagnostic output."
222
     }
223
 
224
    cdl_component CYGBLD_GLOBAL_OPTIONS {
225
        display "Global build options"
226
        flavor  none
227
        no_define
228
        description   "
229
            Global build options including control over
230
            compiler flags, linker flags and choice of toolchain."
231
 
232
 
233
        parent  CYGPKG_NONE
234
 
235
        cdl_option CYGBLD_GLOBAL_COMMAND_PREFIX {
236
            display "Global command prefix"
237
            flavor  data
238
            no_define
239
            default_value { "arm-eabi"}
240
            description "
241
                This option specifies the command prefix used when
242
                invoking the build tools."
243
        }
244
 
245
        cdl_option CYGBLD_GLOBAL_CFLAGS {
246
            display "Global compiler flags"
247
            flavor  data
248
            no_define
249
            default_value { CYGBLD_GLOBAL_WARNFLAGS . CYGBLD_ARCH_CFLAGS .
250
                            "-mcpu=arm9 -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions " }
251
            description   "
252
                This option controls the global compiler flags which are used to
253
                compile all packages by default. Individual packages may define
254
                options which override these global flags."
255
        }
256
 
257
        cdl_option CYGBLD_GLOBAL_LDFLAGS {
258
            display "Global linker flags"
259
            flavor  data
260
            no_define
261
            default_value { CYGBLD_ARCH_LDFLAGS . "-mcpu=arm9 --no-target-default-spec -Wl,--gc-sections -Wl,-static -g -O2 -nostdlib" }
262
            description   "
263
                This option controls the global linker flags. Individual
264
                packages may define options which override these global flags."
265
        }
266
 
267
        cdl_option CYGBLD_BUILD_GDB_STUBS {
268
            display "Build GDB stub ROM image"
269
            default_value 0
270
            requires { CYG_HAL_STARTUP == "ROM" }
271
            requires CYGSEM_HAL_ROM_MONITOR
272
            requires CYGBLD_BUILD_COMMON_GDB_STUBS
273
            requires CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS
274
            requires CYGDBG_HAL_DEBUG_GDB_BREAK_SUPPORT
275
            requires CYGDBG_HAL_DEBUG_GDB_THREAD_SUPPORT
276
            requires ! CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT
277
            requires ! CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM
278
            no_define
279
            description "
280
                This option enables the building of the GDB stubs for the
281
                board. The common HAL controls takes care of most of the
282
                build process, but the final conversion from ELF image to
283
                binary data is handled by the platform CDL, allowing
284
                relocation of the data if necessary."
285
 
286
            make -priority 320 {
287
                /bin/gdb_module.srec : /bin/gdb_module.img
288
                $(OBJCOPY) --remove-section=.fixed_vectors $< gdb_module.tmp
289
            }
290
        }
291
    }
292
 
293
    cdl_component CYGPKG_HAL_ARM_ARM9_INNOVATOR_OPTIONS {
294
        display "Innovator build options"
295
        flavor  none
296
        no_define
297
        description   "
298
            Package specific build options including control over
299
            compiler flags used only in building this package,
300
            and details of which tests are built."
301
 
302
 
303
        cdl_option CYGPKG_HAL_ARM_ARM9_INNOVATOR_CFLAGS_ADD {
304
            display "Additional compiler flags"
305
            flavor  data
306
            no_define
307
            default_value { "" }
308
            description   "
309
                This option modifies the set of compiler flags for
310
                building the Innovator HAL. These flags are
311
                used in addition to the set of global flags."
312
        }
313
 
314
        cdl_option CYGPKG_HAL_ARM_ARM9_INNOVATOR_CFLAGS_REMOVE {
315
            display "Suppressed compiler flags"
316
            flavor  data
317
            no_define
318
            default_value { "" }
319
            description   "
320
                This option modifies the set of compiler flags for
321
                building the Innovator HAL. These flags are
322
                removed from the set of global flags if present."
323
        }
324
 
325
        cdl_option CYGPKG_HAL_ARM_ARM9_INNOVATOR_TESTS {
326
            display "Innovator tests"
327
            flavor  data
328
            no_define
329
            calculated { "" }
330
            description   "
331
                This option specifies the set of tests for the Innovator."
332
        }
333
    }
334
 
335
    cdl_component CYGHWR_MEMORY_LAYOUT {
336
        display "Memory layout"
337
        flavor data
338
        no_define
339
        calculated { CYG_HAL_STARTUP == "RAM" ? "arm_arm9_innovator_ram" : \
340
                                                "arm_arm9_innovator_rom" }
341
 
342
        cdl_option CYGHWR_MEMORY_LAYOUT_LDI {
343
            display "Memory layout linker script fragment"
344
            flavor data
345
            no_define
346
            define -file system.h CYGHWR_MEMORY_LAYOUT_LDI
347
            calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
348
                         CYGPRI_HAL_ROM_MLT == "FLASH" ? "" : \
349
                                                         "" }
350
        }
351
 
352
        cdl_option CYGHWR_MEMORY_LAYOUT_H {
353
            display "Memory layout header file"
354
            flavor data
355
            no_define
356
            define -file system.h CYGHWR_MEMORY_LAYOUT_H
357
            calculated { CYG_HAL_STARTUP == "RAM" ? "" : \
358
                         CYGPRI_HAL_ROM_MLT == "FLASH" ? "" : \
359
                                                         "" }
360
        }
361
    }
362
 
363
    cdl_option CYGSEM_HAL_ROM_MONITOR {
364
        display       "Behave as a ROM monitor"
365
        flavor        bool
366
        default_value 0
367
        parent        CYGPKG_HAL_ROM_MONITOR
368
        requires      { CYG_HAL_STARTUP == "ROM" }
369
        description   "
370
            Enable this option if this program is to be used as a ROM monitor,
371
            i.e. applications will be loaded into RAM on the board, and this
372
            ROM monitor may process exceptions or interrupts generated from the
373
            application. This enables features such as utilizing a separate
374
            interrupt stack when exceptions are generated."
375
    }
376
 
377
    cdl_option CYGSEM_HAL_USE_ROM_MONITOR {
378
         display       "Work with a ROM monitor"
379
         flavor        booldata
380
         legal_values  { "GDB_stubs" }
381
         default_value { CYG_HAL_STARTUP == "RAM" ? "GDB_stubs" : 0 }
382
         parent        CYGPKG_HAL_ROM_MONITOR
383
         requires      { CYG_HAL_STARTUP == "RAM" }
384
         description   "
385
             Support can be enabled for different varieties of ROM monitor.
386
             This support changes various eCos semantics such as the encoding
387
             of diagnostic output, or the overriding of hardware interrupt
388
             vectors.
389
             \"GDB_stubs\" provides support when GDB stubs are included in
390
             the ROM monitor or boot ROM."
391
     }
392
 
393
    cdl_component CYGPKG_REDBOOT_HAL_OPTIONS {
394
        display       "Redboot HAL options"
395
        flavor        none
396
        no_define
397
        parent        CYGPKG_REDBOOT
398
        active_if     CYGPKG_REDBOOT
399
        description   "
400
            This option lists the target's requirements for a valid Redboot
401
            configuration."
402
 
403
        # RedBoot details
404
        requires { CYGHWR_REDBOOT_ARM_LINUX_EXEC_ADDRESS_DEFAULT == 0x10008000 }
405
        define_proc {
406
            puts $::cdl_header "#define CYGHWR_REDBOOT_ARM_TRAMPOLINE_ADDRESS 0x00001f00"
407
        }
408
 
409
        cdl_option CYGBLD_BUILD_REDBOOT_BIN {
410
            display       "Build Redboot ROM binary image"
411
            active_if     CYGBLD_BUILD_REDBOOT
412
            default_value 1
413
            no_define
414
            description "This option enables the conversion of the Redboot ELF
415
                         image to the various relocated SREC images needed
416
                         for flash updating."
417
 
418
            compile -library=libextras.a redboot_cmds.c
419
 
420
            make -priority 325 {
421
                /bin/redboot.bin : /bin/redboot.elf
422
                $(OBJCOPY) --strip-debug $< $(@:.bin=.img)
423
                $(OBJCOPY) -O srec $< $(@:.bin=.srec)
424
                $(OBJCOPY) -O binary $< $@
425
            }
426
        }
427
    }
428
 
429
}

powered by: WebSVN 2.1.0

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