1 |
786 |
skrzyp |
# ====================================================================
|
2 |
|
|
#
|
3 |
|
|
# watchdog.cdl
|
4 |
|
|
#
|
5 |
|
|
# eCos watchdog 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, 2009 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): jskov
|
43 |
|
|
# Original data: nickg
|
44 |
|
|
# Contributors:
|
45 |
|
|
# Date: 1999-07-13
|
46 |
|
|
#
|
47 |
|
|
#####DESCRIPTIONEND####
|
48 |
|
|
#
|
49 |
|
|
# ====================================================================
|
50 |
|
|
|
51 |
|
|
cdl_package CYGPKG_IO_WATCHDOG {
|
52 |
|
|
display "Watchdog IO device"
|
53 |
|
|
define_header watchdog.h
|
54 |
|
|
include_dir cyg/io
|
55 |
|
|
description "
|
56 |
|
|
The watchdog IO device allows applications to make use of a
|
57 |
|
|
timer facility. Depending on the underlying hardware device
|
58 |
|
|
driver, a watchdog timeout will either cause a board reset
|
59 |
|
|
or an action routine to be called. The application must call
|
60 |
|
|
the watchdog reset function at regular intervals, or else the
|
61 |
|
|
device will timeout. The assumption is that the watchdog timer
|
62 |
|
|
should never trigger unless there has been a serious fault in
|
63 |
|
|
either the hardware or the software."
|
64 |
|
|
|
65 |
|
|
compile watchdog.cxx
|
66 |
|
|
|
67 |
|
|
cdl_interface CYGINT_WATCHDOG_HW_IMPLEMENTATIONS {
|
68 |
|
|
display "Number of watchdog hardware implementations"
|
69 |
|
|
no_define
|
70 |
|
|
}
|
71 |
|
|
|
72 |
|
|
cdl_interface CYGINT_WATCHDOG_IMPLEMENTATIONS {
|
73 |
|
|
display "Number of watchdog implementations"
|
74 |
|
|
no_define
|
75 |
|
|
requires 1 == CYGINT_WATCHDOG_IMPLEMENTATIONS
|
76 |
|
|
}
|
77 |
|
|
|
78 |
|
|
cdl_component CYGPKG_IO_WATCHDOG_IMPLEMENTATION {
|
79 |
|
|
display "Watchdog implementation"
|
80 |
|
|
flavor none
|
81 |
|
|
no_define
|
82 |
|
|
description "Implementations of the watchdog device."
|
83 |
|
|
|
84 |
|
|
cdl_option CYGPKG_WATCHDOG_EMULATE {
|
85 |
|
|
default_value { 0 == CYGINT_WATCHDOG_HW_IMPLEMENTATIONS }
|
86 |
|
|
display "Watchdog emulator"
|
87 |
|
|
implements CYGINT_WATCHDOG_IMPLEMENTATIONS
|
88 |
|
|
requires CYGVAR_KERNEL_COUNTERS_CLOCK
|
89 |
|
|
compile emulate.cxx
|
90 |
|
|
description "
|
91 |
|
|
When this option is enabled, a watchdog device will be
|
92 |
|
|
emulated using the kernel real-time clock."
|
93 |
|
|
}
|
94 |
|
|
|
95 |
|
|
cdl_option CYGIMP_WATCHDOG_NONE {
|
96 |
|
|
display "No watchdog"
|
97 |
|
|
default_value 0
|
98 |
|
|
implements CYGINT_WATCHDOG_IMPLEMENTATIONS
|
99 |
|
|
description "Disables the watchdog."
|
100 |
|
|
}
|
101 |
|
|
}
|
102 |
|
|
|
103 |
|
|
cdl_interface CYGINT_WATCHDOG_RESETS_ON_TIMEOUT {
|
104 |
|
|
display "Set if device causes a reset on timeout"
|
105 |
|
|
no_define
|
106 |
|
|
}
|
107 |
|
|
|
108 |
|
|
cdl_option CYGSEM_WATCHDOG_RESETS_ON_TIMEOUT {
|
109 |
|
|
display "Set if device causes a reset on timeout"
|
110 |
|
|
calculated { CYGINT_WATCHDOG_RESETS_ON_TIMEOUT == 1 }
|
111 |
|
|
description "
|
112 |
|
|
Some watchdog devices reset the board on timeout - for these
|
113 |
|
|
implementations it does not make sense to register timeout
|
114 |
|
|
actions so the code gets disabled when this option is set.
|
115 |
|
|
When this option is not set, it is the application's
|
116 |
|
|
responsibility to register an action handler which can force
|
117 |
|
|
a board reset when it gets called."
|
118 |
|
|
}
|
119 |
|
|
|
120 |
|
|
cdl_option CYGPKG_IO_WATCHDOG_BUILD_INTERACTIVE_TEST {
|
121 |
|
|
display "Build interactive watchdog test"
|
122 |
|
|
flavor bool
|
123 |
|
|
no_define
|
124 |
|
|
default_value 0
|
125 |
|
|
description "
|
126 |
|
|
This option enables the building of a watchdog test
|
127 |
|
|
which can be used to test that the board resets on
|
128 |
|
|
watchdog timeout. This test is built separately since
|
129 |
|
|
it only makes sense to use interactively."
|
130 |
|
|
}
|
131 |
|
|
|
132 |
|
|
cdl_component CYGPKG_IO_WATCHDOG_OPTIONS {
|
133 |
|
|
display "Watchdog build options"
|
134 |
|
|
flavor none
|
135 |
|
|
description "
|
136 |
|
|
Package specific build options including control over
|
137 |
|
|
compiler flags used only in building this package,
|
138 |
|
|
and details of which tests are built."
|
139 |
|
|
|
140 |
|
|
|
141 |
|
|
cdl_option CYGPKG_IO_WATCHDOG_CFLAGS_ADD {
|
142 |
|
|
display "Additional compiler flags"
|
143 |
|
|
flavor data
|
144 |
|
|
no_define
|
145 |
|
|
default_value { "" }
|
146 |
|
|
description "
|
147 |
|
|
This option modifies the set of compiler flags for
|
148 |
|
|
building the watchdog IO device. These flags are used
|
149 |
|
|
in addition to the set of global flags."
|
150 |
|
|
}
|
151 |
|
|
|
152 |
|
|
cdl_option CYGPKG_IO_WATCHDOG_CFLAGS_REMOVE {
|
153 |
|
|
display "Suppressed compiler flags"
|
154 |
|
|
flavor data
|
155 |
|
|
no_define
|
156 |
|
|
default_value { "" }
|
157 |
|
|
description "
|
158 |
|
|
This option modifies the set of compiler flags for
|
159 |
|
|
building the watchdog IO device. These flags are removed from
|
160 |
|
|
the set of global flags if present."
|
161 |
|
|
}
|
162 |
|
|
|
163 |
|
|
cdl_option CYGPKG_IO_WATCHDOG_TESTS {
|
164 |
|
|
display "Watchdog tests"
|
165 |
|
|
flavor data
|
166 |
|
|
no_define
|
167 |
|
|
calculated { CYGPKG_IO_WATCHDOG_BUILD_INTERACTIVE_TEST ?
|
168 |
|
|
CYGSEM_WATCHDOG_RESETS_ON_TIMEOUT ? "tests/watchdog2 tests/watchdog_reset" : "tests/watchdog tests/watchdog2 tests/watchdog_reset" :
|
169 |
|
|
CYGSEM_WATCHDOG_RESETS_ON_TIMEOUT ? "tests/watchdog2" : "tests/watchdog tests/watchdog2" }
|
170 |
|
|
|
171 |
|
|
description "
|
172 |
|
|
This option specifies the set of tests for the
|
173 |
|
|
watchdog IO device."
|
174 |
|
|
}
|
175 |
|
|
}
|
176 |
|
|
}
|