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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [newlib-1.17.0/] [libgloss/] [bfin/] [include/] [sys/] [anomaly_macros_rtl.h] - Blame information for rev 822

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

Line No. Rev Author Line
1 148 jeremybenn
/*
2
 * The authors hereby grant permission to use, copy, modify, distribute,
3
 * and license this software and its documentation for any purpose, provided
4
 * that existing copyright notices are retained in all copies and that this
5
 * notice is included verbatim in any distributions. No written agreement,
6
 * license, or royalty fee is required for any of the authorized uses.
7
 * Modifications to this software may be copyrighted by their authors
8
 * and need not follow the licensing terms described here, provided that
9
 * the new terms are clearly indicated on the first page of each file where
10
 * they apply.
11
 */
12
 
13
/************************************************************************
14
 *
15
 * anomaly_macros_rtl.h : $Revision: 1.1 $
16
 *
17
 * Copyright (C) 2008 Analog Devices, Inc.
18
 *
19
 * This file defines macros used within the run-time libraries to enable
20
 * certain anomaly workarounds for the appropriate chips and silicon
21
 * revisions. Certain macros are defined for silicon-revision none - this
22
 * is to ensure behaviour is unchanged from libraries supplied with
23
 * earlier tools versions, where a small number of anomaly workarounds
24
 * were applied in all library flavours. __FORCE_LEGACY_WORKAROUNDS__
25
 * is defined in this case.
26
 *
27
 * This file defines macros for a subset of all anomalies that may impact
28
 * the run-time libraries.
29
 *
30
 ************************************************************************/
31
 
32
 
33
#if !defined(__SILICON_REVISION__)
34
#define __FORCE_LEGACY_WORKAROUNDS__
35
#endif
36
 
37
 
38
/* 05-00-0096 - PREFETCH, FLUSH, and FLUSHINV must be followed by a CSYNC
39
**
40
**  ADSP-BF531/2/3 - revs 0.0-0.1,
41
**  ADSP-BF561 - revs 0.0-0.1 (not supported in VDSP++ 4.0)
42
**
43
*/
44
#define WA_05000096 \
45
  ((defined(__ADSPBF531__) ||  \
46
    defined(__ADSPBF532__) ||  \
47
    defined(__ADSPBF533__) ||  \
48
    defined(__ADSPBF561__)) && \
49
  ((defined(__SILICON_REVISION__) && \
50
   (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x1)) || \
51
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
52
 
53
 
54
/* 05-00-0109 - Reserved bits in SYSCFG register not set at power on
55
**
56
**  ADSP-BF531/2/3 - revs 0.0-0.2 (fixed 0.3)
57
**  ADSP-BF561 - revs 0.0-0.2 (fixed 0.3. 0.0, 0.1 not supported in VDSP++ 4.0)
58
**
59
** Changes to start code.
60
*/
61
#define WA_05000109 \
62
  ((defined(__ADSPBF531__) ||  \
63
    defined(__ADSPBF532__) ||  \
64
    defined(__ADSPBF533__) ||  \
65
    defined(__ADSPBF561__)) && \
66
  ((defined(__SILICON_REVISION__) && \
67
   (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x2)) || \
68
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
69
 
70
 
71
/* 05-00-0123 - DTEST_COMMAND initiated memory access may be incorrect if
72
** data cache or DMA is active.
73
**
74
**  ADSP-BF531/2/3 - revs 0.1-0.2 (fixed 0.3)
75
**  ADSP-BF561 - revs 0.0-0.2 (0.0 and 0.1 not supported in VDSP++ 4.0)
76
*/
77
#define WA_05000123 \
78
  ((defined(__ADSPBF531__) ||  \
79
    defined(__ADSPBF532__) ||  \
80
    defined(__ADSPBF533__) ||  \
81
    defined(__ADSPBF561__)) && \
82
  ((defined(__SILICON_REVISION__) && \
83
   (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x2)) || \
84
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
85
 
86
 
87
/* 05-00-0125 - Erroneous exception when enabling cache
88
**
89
**  ADSP-BF531/2/3 - revs 0.1-0.2 (fixed 0.3)
90
**  ADSP-BF561 - revs 0.0-0.2 (0.0 and 0.1 not supported in VDSP++ 4.0)
91
**
92
*/
93
#define WA_05000125 \
94
  ((defined(__ADSPBF531__) ||  \
95
    defined(__ADSPBF532__) ||  \
96
    defined(__ADSPBF533__) ||  \
97
    defined(__ADSPBF561__)) && \
98
  ((defined(__SILICON_REVISION__) && \
99
   (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x2)) || \
100
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
101
 
102
 
103
/* 05-00-0137 - DMEM_CONTROL<12> is not set on Reset
104
**
105
**  ADSP-BF531/2/3 - revs 0.0-0.2 (fixed 0.3)
106
**
107
** Changes to start code.
108
**
109
*/
110
#define WA_05000137 \
111
  ((defined(__ADSPBF531__) ||  \
112
    defined(__ADSPBF532__) ||  \
113
    defined(__ADSPBF533__)) && \
114
  ((defined(__SILICON_REVISION__) && \
115
   (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x2)) || \
116
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
117
 
118
 
119
/* 05-00-0158 - "Boot fails when data cache enabled: Data from a Data Cache
120
** fill can be  corrupted after or during instruction DMA if certain core
121
** stalls exist"
122
**
123
**  Impacted:
124
**    BF533/3/1 : 0.0-0.4 (fixed 0.5)
125
**
126
** The workaround we have only works for si-revisions >= 0.3. No workaround for
127
** ealier revisions.
128
*/
129
#define WA_05000158 \
130
  ((defined(__ADSPBF531__) ||  \
131
    defined(__ADSPBF532__) ||  \
132
    defined(__ADSPBF533__)) && \
133
  ((defined(__SILICON_REVISION__) && \
134
   (__SILICON_REVISION__ == 0xffff || \
135
     (__SILICON_REVISION__ >= 0x3 && \
136
      __SILICON_REVISION__ < 0x5))) || \
137
   defined(__FORCE_LEGACY_WORKAROUNDS__)))
138
 
139
 
140
/* 05-00-0204 - "Incorrect data read with write-through cache and
141
** allocate cache lines on reads only mode.
142
**
143
** This problem is cache related with high speed clocks. It apparently does
144
** not impact BF531 and BF532 because they cannot run at high enough clock
145
** to cause the anomaly. We build libs for BF532 though so that means we will
146
** need to do the workaround for BF532 and BF531 also.
147
**
148
** Also the 0.3 to 0.4 revision is not an inflexion for libs BF532 and BF561.
149
** This means a RT check may be required to avoid doing the WA for 0.4.
150
**
151
**  Impacted:
152
**     BF533 - 0.0-0.3 (fixed 0.4)
153
**     BF534 - 0.0 (fixed 0.1)
154
**     BF536 - 0.0 (fixed 0.1)
155
**     BF537 - 0.0 (fixed 0.1)
156
**     BF538 - 0.0 (fixed 0.1)
157
**     BF539 - 0.0 (fixed 0.1)
158
**     BF561 - 0.0-0.3 (fixed 0.4)
159
*/
160
#if defined(__ADI_LIB_BUILD__)
161
#  define __BUILDBF53123 1 /* building one single library for BF531/2/3 */
162
#else
163
#  define __BUILDBF53123 0
164
#endif
165
 
166
#define WA_05000204 \
167
   ((((__BUILDBF53123==1 && \
168
       (defined(__ADSPBF531__) || defined(__ADSPBF532__))) || \
169
      (defined(__ADSPBF533__) || defined(__ADSPBF561__))) && \
170
     (defined(__SILICON_REVISION__) && \
171
      (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ <= 0x3))) || \
172
    ((defined(__ADSPBF534__) || defined(__ADSPBF536__) || \
173
      defined(__ADSPBF537__) || defined(__ADSPBF538__) || \
174
      defined(__ADSPBF539__)) && \
175
     (defined(__SILICON_REVISION__) && \
176
      (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ == 0x0))))
177
 
178
#if ((defined(__ADSPBF531__) || defined(__ADSPBF532__) || \
179
      defined(__ADSPBF533__) || defined(__ADSPBF561__)) && \
180
     (defined(__SILICON_REVISION__) && \
181
      (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ == 0x3)))
182
/* check at RT for 0.4 revs when doing 204 workaround */
183
#  define WA_05000204_CHECK_AVOID_FOR_REV <=3
184
#elif ((defined(__ADSPBF534__) || defined(__ADSPBF536__) || \
185
        defined(__ADSPBF537__) || defined(__ADSPBF538__) || \
186
        defined(__ADSPBF539__)) && \
187
     (defined(__SILICON_REVISION__) && \
188
      (__SILICON_REVISION__ == 0xffff || __SILICON_REVISION__ == 0x0)))
189
/* check at RT for 0.4 revs when doing 204 workaround */
190
#  define WA_05000204_CHECK_AVOID_FOR_REV <1
191
#else
192
/* do not check at RT for 0.4 revs when doing 204 workaround */
193
#endif
194
 
195
/* 05-00-0258 - "Instruction Cache is corrupted when bit 9 and 12 of
196
 * the ICPLB Data registers differ"
197
 *
198
 * When bit 9 and bit 12 of the ICPLB Data MMR differ, the cache may
199
 * not update properly.  For example, for a particular cache line,
200
 * the cache tag may be valid while the contents of that cache line
201
 * are not present in the cache.
202
 *
203
 * Impacted:
204
 *
205
 * BF531/2/3 - 0.0-0.4 (fixed 0.5)
206
 * BF534/6/7/8/9 - 0.0-0.2 (fixed 0.3)
207
 * BF561 - 0.0-0.4 (fixed 0.5)
208
 * BF535/AD6532/AD6900 - all revs
209
 */
210
 
211
#define WA_05000258 \
212
  defined(__SILICON_REVISION__) && \
213
    (__SILICON_REVISION__ == 0xffff || \
214
     !defined(__ADSPLPBLACKFIN__) || \
215
     ((defined(__ADSPBF531__) ||  \
216
       defined(__ADSPBF532__) ||  \
217
       defined(__ADSPBF533__)) && \
218
      (__SILICON_REVISION__ <= 0x4)) || \
219
     ((defined(__ADSPBF534__) ||  \
220
       defined(__ADSPBF536__) ||  \
221
       defined(__ADSPBF537__) ||  \
222
       defined(__ADSPBF538__) ||  \
223
       defined(__ADSPBF539__)) && \
224
      (__SILICON_REVISION__ <= 0x2)) || \
225
     ((defined(__ADSPBF561__)) && \
226
      (__SILICON_REVISION__ <= 0x4)) || \
227
     ((defined(__ADSPBF561__)) && \
228
      (__SILICON_REVISION__ < 0x1)))
229
 
230
/* 05-00-0259 - "Non-deterministic ICPLB descriptors delivered to
231
 * hardware". Whenever ICPLBs are disabled via an MMR write, immediately
232
 * follow this write with a CSYNC, and locate the MMR write and CSYNC
233
 * within the same aligned 64 bit word.
234
 *
235
 * This problem impacts all revisions of Blackfins.
236
 */
237
 
238
#define WA_05000259 \
239
        (defined(__ADSPBLACKFIN__) && defined(__SILICON_REVISION__))
240
 
241
 
242
/* 05-00-0261 - "DCPLB_FAULT_ADDR MMR may be corrupted".
243
 * The DCPLB_FAULT_ADDR MMR may contain the fault address of a
244
 * aborted memory access which generated both a protection exception
245
 * and a stall.
246
 *
247
 * We work around this by initially ignoring a DCPLB miss exception
248
 * on the assumption that the faulting address might be invalid.
249
 * We return without servicing. The exception will be raised
250
 * again when the faulting instruction is re-executed. The fault
251
 * address is correct this time round so the miss exception can
252
 * be serviced as normal. The only complication is we have to
253
 * ensure that we are about to service the same miss rather than
254
 * a miss raised within a higher-priority interrupt handler, where
255
 * the fault address could again be invalid. We therefore record
256
 * the last seen RETX and only service an exception when RETX and
257
 * the last seen RETX are equal.
258
 *
259
 * This problem impacts:
260
 * BF531/2/3 - rev 0.0-0.4 (fixed 0.5)
261
 * BF534/6/7/8/9 - rev 0.0-0.2 (fixed 0.3)
262
 * BF561 - rev 0.0-0.4 (fixed 0.5)
263
 *
264
 */
265
 
266
#define WA_05000261 \
267
        defined(__SILICON_REVISION__) && \
268
         (__SILICON_REVISION__ == 0xffff || \
269
          ((defined(__ADSPBF531__) ||  \
270
            defined(__ADSPBF532__) ||  \
271
            defined(__ADSPBF533__)) && \
272
           (__SILICON_REVISION__ <= 0x4)) || \
273
          ((defined(__ADSPBF534__) ||  \
274
            defined(__ADSPBF536__) ||  \
275
            defined(__ADSPBF537__) ||  \
276
            defined(__ADSPBF538__) ||  \
277
            defined(__ADSPBF539__)) && \
278
           (__SILICON_REVISION__ <= 0x2)) || \
279
          ((defined(__ADSPBF561__)) && \
280
           (__SILICON_REVISION__ <= 0x4)) || \
281
          ((defined(__ADSPBF561__)) && \
282
           (__SILICON_REVISION__ < 0x1)))
283
 
284
/* 05-00-0229 - "SPI Slave Boot Mode Modifies Registers".
285
 * When the SPI slave boot completes, the final DMA IRQ is cleared
286
 * but the DMA5_CONFIG and SPI_CTL registers are not reset to their
287
 * default states.
288
 *
289
 * We work around this by resetting the registers to their default
290
 * values at the beginning of the CRT. The only issue would be when
291
 * users boot from flash and make use of the DMA or serial port.
292
 * In this case, users would need to modify the CRT.
293
 *
294
 * This problem impacts all revisions of ADSP-BF531/2/3/8/9
295
 */
296
 
297
#define WA_05000229 \
298
        (defined(__ADSPBLACKFIN__) && defined (__SILICON_REVISION__) && \
299
         (defined(__ADSPBF531__) || defined(__ADSPBF532__) || \
300
          defined(__ADSPBF533__) || defined(__ADSPBF538__) || \
301
          defined(__ADSPBF539__)))
302
 
303
/* 05-00-0283 - "A system MMR write is stalled indefinitely when killed in a
304
 * particular stage".
305
 *
306
 * Where an interrupt occurs killing a stalled system MMR write, and the ISR
307
 * executes an SSYNC, execution execution may stall indefinitely".
308
 *
309
 * The workaround is to execute a mispredicted jump over a dummy MMR read,
310
 * thus killing the read. Also to avoid a system MMR write in two slots
311
 * after a not predicted conditional jump.
312
 *
313
 * This problem impacts:
314
 * BF531/2/3 - all revs
315
 * BF534/6/7/8/9 - all revs
316
 * BF561/6 - all revs
317
 */
318
 
319
#define WA_05000283 \
320
 defined(__ADSPLPBLACKFIN__) && defined(__SILICON_REVISION__)
321
 
322
 

powered by: WebSVN 2.1.0

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