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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [or1ksim/] [testsuite/] [libsim.tests/] [jtag-go-command-write.exp] - Blame information for rev 98

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 98 jeremybenn
# jtag-go-command-write.exp. Tests of the library JTAG GO_COMMAND for writing
2
 
3
# Copyright (C) 2010 Embecosm Limited
4
 
5
# Contributor Jeremy Bennett 
6
 
7
# This file is part of OpenRISC 1000 Architectural Simulator.
8
 
9
# This program is free software; you can redistribute it and/or modify it
10
# under the terms of the GNU General Public License as published by the Free
11
# Software Foundation; either version 3 of the License, or (at your option)
12
# any later version.
13
 
14
# This program is distributed in the hope that it will be useful, but WITHOUT
15
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
16
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
17
# more details.
18
 
19
# You should have received a copy of the GNU General Public License along
20
# with this program.  If not, see .  */
21
 
22
# -----------------------------------------------------------------------------
23
# This code is commented throughout for use with Doxygen.
24
# -----------------------------------------------------------------------------
25
 
26
 
27
# These tests check all the behavior associated with the JTAG GO_COMMAND when
28
# writing.
29
 
30
# NOTE. All these tests return timing information, but we ignore it, since in
31
#       general it will not be repeatable.
32
 
33
# Tests of the GO_COMMAND for writing to different modules. This should work
34
# fine for Wishbone and CPU0. Other modules will have been weeded out by the
35
# prior WRITE_COMMAND. We specify 4 bytes to read each time.
36
 
37
# We use the loop-report OpenRISC program here, since we must be sure that
38
# values written make it to the target As SPR's we use MACLO (0x2801) and
39
# MACHI (0x2802). As Wishbone we use address 0x100000 - 0x12ffff. Changes to
40
# values in the first 16 bytes following 0x100000, 0x110000 and 0x120000 are
41
# reported.
42
 
43
# When testing GO_COMMAND (write) after invalid module selection, we cannot
44
# guarantee a CRC mismatch (or at least I can't do the maths to prove that no
45
# register of all zeros can have a valid CRC field for the possible GO_COMMAND
46
# register lengths, although it is highly likely), so we just look for the
47
# error message.
48
 
49
# GO_COMMAND writing with no module selection (address 0x100000).
50
run_libsim "JTAG SELECT_MODULE GO_COMMAND (write) no module"    \
51
    [list "Initalization succeeded."                            \
52
          "Execution step completed OK."                        \
53
          "Resetting JTAG."                                     \
54
          "Execution step completed OK."                        \
55
          "Shifting instruction."                               \
56
          "  shifting in:  0x01"                                \
57
          "  shifted out:  0x01"                                \
58
          "  time taken: "                                      \
59
          "Execution step completed OK."                        \
60
          "Processing WRITE_COMMAND."                           \
61
          "  shifting in:  0x00000000018f4396f780000000100088"  \
62
          "ERROR: JTAG WRITE_COMMAND with no module selected."  \
63
          "  shifted out:  0x164841bc600000000000000000000000"  \
64
          "  status:       0x0"                                 \
65
          "  time taken:"                                       \
66
          "Execution step completed OK."                        \
67
          "Processing GO_COMMAND_WRITE."                        \
68
          "  shifting in:  0x00000000001a6f47467eefb6af60"      \
69
          "ERROR: JTAG GO_COMMAND with no prior WRITE_COMMAND." \
70
          "  shifted out:  0x0000000000000000000000000000"      \
71
          "  status:       0x0"                                 \
72
          "  time taken:"                                       \
73
          "Execution step completed OK."                        \
74
          "Test completed successfully."]                       \
75
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" "8"   \
76
         "WRITE_COMMAND" "2" "100000" "4" "GO_COMMAND_WRITE" "deadbeef"
77
 
78
# GO_COMMAND writing with only invalid module selected.
79
run_libsim "JTAG GO_COMMAND (write) invalid module"             \
80
    [list "Initalization succeeded."                            \
81
          "Execution step completed OK."                        \
82
          "Resetting JTAG."                                     \
83
          "Execution step completed OK."                        \
84
          "Shifting instruction."                               \
85
          "  shifting in:  0x01"                                \
86
          "  shifted out:  0x01"                                \
87
          "  time taken:"                                       \
88
          "Execution step completed OK."                        \
89
          "Selecting module."                                   \
90
          "  shifting in:  0x00000000001993c98e69"              \
91
          "  shifted out:  0x0164841bc60000000000"              \
92
          "  status:       0x0"                                 \
93
          "  time taken:"                                       \
94
          "Execution step completed OK."                        \
95
          "Processing WRITE_COMMAND."                           \
96
          "  shifting in:  0x0000000001933eb7e580010028000088"  \
97
          "ERROR: JTAG WRITE_COMMAND for CPU1 not supported."   \
98
          "  shifted out:  0x164841bc600000000000000000000000"  \
99
          "  status:       0x0"                                 \
100
          "  time taken:"                                       \
101
          "Execution step completed OK."                        \
102
          "Processing GO_COMMAND_WRITE."                        \
103
          "  shifting in:  0x00000000001a6f47467eefb6af60"      \
104
          "ERROR: JTAG GO_COMMAND with no prior WRITE_COMMAND." \
105
          "  shifted out:  0x0000000000000000000000000000"      \
106
          "  status:       0x0"                                 \
107
          "  time taken:"                                       \
108
          "Execution step completed OK."                        \
109
          "Test completed successfully."]                       \
110
    "lib-jtag/lib-jtag-full" "" "loop/loop-init" "RESET" "INSTRUCTION" \
111
         "8" "SELECT_MODULE" "2" "WRITE_COMMAND" "2" "2801" "4"        \
112
         "GO_COMMAND_WRITE" "deadbeef"
113
 
114
# GO_COMMAND writing with invalid module selected after valid module
115
run_libsim "JTAG GO_COMMAND (write) invalid after valid module" \
116
    [list "Initalization succeeded."                            \
117
          "Execution step completed OK."                        \
118
          "Resetting JTAG."                                     \
119
          "Execution step completed OK."                        \
120
          "Shifting instruction."                               \
121
          "  shifting in:  0x01"                                \
122
          "  shifted out:  0x01"                                \
123
          "  time taken:"                                       \
124
          "Execution step completed OK."                        \
125
          "Selecting module."                                   \
126
          "  shifting in:  0x0000000000174841bc61"              \
127
          "  shifted out:  0x0164841bc60000000000"              \
128
          "  status:       0x0"                                 \
129
          "  time taken:"                                       \
130
          "Execution step completed OK."                        \
131
          "Selecting module."                                   \
132
          "  shifting in:  0x00000000001efe0d976d"              \
133
          "  shifted out:  0x01893c98e68000000000"              \
134
          "  status:       0x2"                                 \
135
          "  time taken:"                                       \
136
          "Execution step completed OK."                        \
137
          "Processing WRITE_COMMAND."                           \
138
          "  shifting in:  0x0000000001933eb7e580010028000088"  \
139
          "ERROR: JTAG WRITE_COMMAND with no module selected."  \
140
          "  shifted out:  0x164841bc600000000000000000000000"  \
141
          "  status:       0x0"                                 \
142
          "  time taken:"                                       \
143
          "Execution step completed OK."                        \
144
          "Processing GO_COMMAND_WRITE."                        \
145
          "  shifting in:  0x00000000001a6f47467eefb6af60"      \
146
          "ERROR: JTAG GO_COMMAND with no prior WRITE_COMMAND." \
147
          "  shifted out:  0x0000000000000000000000000000"      \
148
          "  status:       0x0"                                 \
149
          "  time taken:"                                       \
150
          "Execution step completed OK."                        \
151
          "Test completed successfully."]                       \
152
    "lib-jtag/lib-jtag-full" "" "loop/loop-init" "RESET" "INSTRUCTION"   \
153
         "8" "SELECT_MODULE" "0" "SELECT_MODULE" "6" "WRITE_COMMAND" "2" \
154
         "2801" "4" "GO_COMMAND_WRITE" "deadbeef"
155
 
156
# GO_COMMAND writing with valid module selected after invalid module
157
run_libsim "JTAG GO_COMMAND (write) valid after invalid module" \
158
    [list "Initalization succeeded."                           \
159
          "Execution step completed OK."                       \
160
          "Resetting JTAG."                                    \
161
          "Execution step completed OK."                       \
162
          "Shifting instruction."                              \
163
          "  shifting in:  0x01"                               \
164
          "  shifted out:  0x01"                               \
165
          "  time taken:"                                      \
166
          "Execution step completed OK."                       \
167
          "Selecting module."                                  \
168
          "  shifting in:  0x00000000001efe0d976d"             \
169
          "  shifted out:  0x01893c98e68000000000"             \
170
          "  status:       0x2"                                \
171
          "  time taken:"                                      \
172
          "Execution step completed OK."                       \
173
          "Selecting module."                                  \
174
          "  shifting in:  0x0000000000174841bc61"             \
175
          "  shifted out:  0x0164841bc60000000000"             \
176
          "  status:       0x0"                                \
177
          "  time taken:"                                      \
178
          "Execution step completed OK."                       \
179
          "Processing WRITE_COMMAND."                          \
180
          "  shifting in:  0x00000000018f4396f780000000100088" \
181
          "  shifted out:  0x164841bc600000000000000000000000" \
182
          "  status:       0x0"                                \
183
          "  time taken:"                                      \
184
          "Execution step completed OK."                       \
185
          "Processing GO_COMMAND_WRITE."                       \
186
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
187
          "  shifted out:  0x0164841bc6000000000000000000"     \
188
          "  status:       0x0"                                \
189
          "  time taken:"                                      \
190
          "Execution step completed OK."                       \
191
          "Test completed successfully."]                      \
192
    "lib-jtag/lib-jtag-full" "" "loop/loop-init" "RESET" "INSTRUCTION"   \
193
         "8" "SELECT_MODULE" "6" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" \
194
         "100000" "4" "GO_COMMAND_WRITE" "deadbeef"
195
 
196
# Verify that writing works correctly from both valid modules, WishBone and
197
# CPU0.
198
 
199
# GO_COMMAND writing for Wishbone (address 0x100000).
200
run_libsim "JTAG SELECT_MODULE GO_COMMAND (write) WB"          \
201
    [list "Initalization succeeded."                           \
202
          "Execution step completed OK."                       \
203
          "Resetting JTAG."                                    \
204
          "Execution step completed OK."                       \
205
          "Shifting instruction."                              \
206
          "  shifting in:  0x01"                               \
207
          "  shifted out:  0x01"                               \
208
          "  time taken: "                                     \
209
          "Execution step completed OK."                       \
210
          "Selecting module."                                  \
211
          "  shifting in:  0x0000000000174841bc61"             \
212
          "  shifted out:  0x0164841bc60000000000"             \
213
          "  status:       0x0"                                \
214
          "  time taken:"                                      \
215
          "Execution step completed OK."                       \
216
          "Processing WRITE_COMMAND."                          \
217
          "  shifting in:  0x00000000018f4396f780000000100088" \
218
          "  shifted out:  0x164841bc600000000000000000000000" \
219
          "  status:       0x0"                                \
220
          "  time taken:"                                      \
221
          "Execution step completed OK."                       \
222
          "Processing GO_COMMAND_WRITE."                       \
223
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
224
          "  shifted out:  0x0164841bc6000000000000000000"     \
225
          "  status:       0x0"                                \
226
          "  time taken:"                                      \
227
          "Execution step completed OK."                       \
228
          "Test completed successfully."]                      \
229
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" "8" \
230
         "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "4"         \
231
         "GO_COMMAND_WRITE" "deadbeef"
232
 
233
# GO_COMMAND writing for CPU0 (address 0x2801, MACLO).
234
run_libsim "JTAG SELECT_MODULE GO_COMMAND (write) CPU0"        \
235
    [list "Initalization succeeded."                           \
236
          "Execution step completed OK."                       \
237
          "Resetting JTAG."                                    \
238
          "Execution step completed OK."                       \
239
          "Shifting instruction."                              \
240
          "  shifting in:  0x01"                               \
241
          "  shifted out:  0x01"                               \
242
          "  time taken:"                                      \
243
          "Execution step completed OK."                       \
244
          "Selecting module."                                  \
245
          "  shifting in:  0x00000000000aff51d871"             \
246
          "  shifted out:  0x0164841bc60000000000"             \
247
          "  status:       0x0"                                \
248
          "  time taken:"                                      \
249
          "Execution step completed OK."                       \
250
          "Processing WRITE_COMMAND."                          \
251
          "  shifting in:  0x0000000001933eb7e580010028000088" \
252
          "  shifted out:  0x164841bc600000000000000000000000" \
253
          "  status:       0x0"                                \
254
          "  time taken:"                                      \
255
          "Execution step completed OK."                       \
256
          "Processing GO_COMMAND_WRITE."                       \
257
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
258
          "  shifted out:  0x0164841bc6000000000000000000"     \
259
          "  status:       0x0"                                \
260
          "  time taken:"                                      \
261
          "Execution step completed OK."                       \
262
          "Test completed successfully."]                      \
263
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" "8" \
264
         "SELECT_MODULE" "1" "WRITE_COMMAND" "2" "2801" "4"           \
265
         "GO_COMMAND_WRITE" "deadbeef"
266
 
267
# Tests of GO_COMMAND_WRITE with different access alignments, boundaries and
268
# lengths for WishBone. For this we use the loop-report program, which reports
269
# any changes in values at 0x100000-0x10000f, 0x110000-0x11000f and
270
# 0x120000-0x12000f or the SPRs MACLO (0x2801) and MACHI (0x2800), all of
271
# which are initialized to zero.
272
 
273
# First check that a single aligned unit can be written for each access type
274
# at its allowed alignments.
275
 
276
# GO_COMMAND writing one byte for Wishbone aligned at byte 0.
277
run_libsim "JTAG GO_COMMAND (write) WB 1 byte, aligned byte 0" \
278
    [list "Initalization succeeded."                           \
279
          "Execution step completed OK."                       \
280
          "Resetting JTAG."                                    \
281
          "Execution step completed OK."                       \
282
          "Shifting instruction."                              \
283
          "  shifting in:  0x01"                               \
284
          "  shifted out:  0x01"                               \
285
          "  time taken:"                                      \
286
          "Execution step completed OK."                       \
287
          "Selecting module."                                  \
288
          "  shifting in:  0x0000000000174841bc61"             \
289
          "  shifted out:  0x0164841bc60000000000"             \
290
          "  status:       0x0"                                \
291
          "  time taken:"                                      \
292
          "Execution step completed OK."                       \
293
          "Processing WRITE_COMMAND."                          \
294
          "  shifting in:  0x0000000000319cf96400000000100008" \
295
          "  shifted out:  0x164841bc600000000000000000000000" \
296
          "  status:       0x0"                                \
297
          "  time taken:"                                      \
298
          "Execution step completed OK."                       \
299
          "Processing GO_COMMAND_WRITE."                       \
300
          "  shifting in:  0x000000000006d6fa6e6f60"           \
301
          "  shifted out:  0x0164841bc6000000000000"           \
302
          "  status:       0x0"                                \
303
          "  time taken:"                                      \
304
          "New byte at 0x00100000 = 0xde"                      \
305
          "Execution step completed OK."                       \
306
          "Test completed successfully."]                      \
307
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
308
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "1"        \
309
         "GO_COMMAND_WRITE" "de"
310
 
311
# GO_COMMAND writing one byte for Wishbone aligned at byte 1.
312
run_libsim "JTAG GO_COMMAND (write) WB 1 byte, aligned byte 1" \
313
    [list "Initalization succeeded."                           \
314
          "Execution step completed OK."                       \
315
          "Resetting JTAG."                                    \
316
          "Execution step completed OK."                       \
317
          "Shifting instruction."                              \
318
          "  shifting in:  0x01"                               \
319
          "  shifted out:  0x01"                               \
320
          "  time taken:"                                      \
321
          "Execution step completed OK."                       \
322
          "Selecting module."                                  \
323
          "  shifting in:  0x0000000000174841bc61"             \
324
          "  shifted out:  0x0164841bc60000000000"             \
325
          "  status:       0x0"                                \
326
          "  time taken:"                                      \
327
          "Execution step completed OK."                       \
328
          "Processing WRITE_COMMAND."                          \
329
          "  shifting in:  0x0000000001f3f6ce6400010000100008" \
330
          "  shifted out:  0x164841bc600000000000000000000000" \
331
          "  status:       0x0"                                \
332
          "  time taken:"                                      \
333
          "Execution step completed OK."                       \
334
          "Processing GO_COMMAND_WRITE."                       \
335
          "  shifting in:  0x000000000006d6fa6e6f60"           \
336
          "  shifted out:  0x0164841bc6000000000000"           \
337
          "  status:       0x0"                                \
338
          "  time taken:"                                      \
339
          "New byte at 0x00100001 = 0xde"                      \
340
          "Execution step completed OK."                       \
341
          "Test completed successfully."]                      \
342
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
343
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100001" "1"        \
344
         "GO_COMMAND_WRITE" "de"
345
 
346
# GO_COMMAND writing one byte for Wishbone aligned at byte 2.
347
run_libsim "JTAG GO_COMMAND (write) WB 1 byte, aligned byte 2" \
348
    [list "Initalization succeeded."                           \
349
          "Execution step completed OK."                       \
350
          "Resetting JTAG."                                    \
351
          "Execution step completed OK."                       \
352
          "Shifting instruction."                              \
353
          "  shifting in:  0x01"                               \
354
          "  shifted out:  0x01"                               \
355
          "  time taken:"                                      \
356
          "Execution step completed OK."                       \
357
          "Selecting module."                                  \
358
          "  shifting in:  0x0000000000174841bc61"             \
359
          "  shifted out:  0x0164841bc60000000000"             \
360
          "  status:       0x0"                                \
361
          "  time taken:"                                      \
362
          "Execution step completed OK."                       \
363
          "Processing WRITE_COMMAND."                          \
364
          "  shifting in:  0x0000000000d0a9e2e400008000100008" \
365
          "  shifted out:  0x164841bc600000000000000000000000" \
366
          "  status:       0x0"                                \
367
          "  time taken:"                                      \
368
          "Execution step completed OK."                       \
369
          "Processing GO_COMMAND_WRITE."                       \
370
          "  shifting in:  0x000000000006d6fa6e6f60"           \
371
          "  shifted out:  0x0164841bc6000000000000"           \
372
          "  status:       0x0"                                \
373
          "  time taken:"                                      \
374
          "New byte at 0x00100002 = 0xde"                      \
375
          "Execution step completed OK."                       \
376
          "Test completed successfully."]                      \
377
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
378
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100002" "1"        \
379
         "GO_COMMAND_WRITE" "de"
380
 
381
# GO_COMMAND writing one byte for Wishbone aligned at byte 3.
382
run_libsim "JTAG GO_COMMAND (write) WB 1 byte, aligned byte 3" \
383
    [list "Initalization succeeded."                           \
384
          "Execution step completed OK."                       \
385
          "Resetting JTAG."                                    \
386
          "Execution step completed OK."                       \
387
          "Shifting instruction."                              \
388
          "  shifting in:  0x01"                               \
389
          "  shifted out:  0x01"                               \
390
          "  time taken:"                                      \
391
          "Execution step completed OK."                       \
392
          "Selecting module."                                  \
393
          "  shifting in:  0x0000000000174841bc61"             \
394
          "  shifted out:  0x0164841bc60000000000"             \
395
          "  status:       0x0"                                \
396
          "  time taken:"                                      \
397
          "Execution step completed OK."                       \
398
          "Processing WRITE_COMMAND."                          \
399
          "  shifting in:  0x000000000112c3d5e400018000100008" \
400
          "  shifted out:  0x164841bc600000000000000000000000" \
401
          "  status:       0x0"                                \
402
          "  time taken:"                                      \
403
          "Execution step completed OK."                       \
404
          "Processing GO_COMMAND_WRITE."                       \
405
          "  shifting in:  0x000000000006d6fa6e6f60"           \
406
          "  shifted out:  0x0164841bc6000000000000"           \
407
          "  status:       0x0"                                \
408
          "  time taken:"                                      \
409
          "New byte at 0x00100003 = 0xde"                      \
410
          "Execution step completed OK."                       \
411
          "Test completed successfully."]                      \
412
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
413
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100003" "1"        \
414
         "GO_COMMAND_WRITE" "de"
415
 
416
# GO_COMMAND writing one half word for Wishbone aligned at byte 0.
417
run_libsim "JTAG GO_COMMAND (write) WB 1 half word, aligned byte 0" \
418
    [list "Initalization succeeded."                                \
419
          "Execution step completed OK."                            \
420
          "Resetting JTAG."                                         \
421
          "Execution step completed OK."                            \
422
          "Shifting instruction."                                   \
423
          "  shifting in:  0x01"                                    \
424
          "  shifted out:  0x01"                                    \
425
          "  time taken:"                                           \
426
          "Execution step completed OK."                            \
427
          "Selecting module."                                       \
428
          "  shifting in:  0x0000000000174841bc61"                  \
429
          "  shifted out:  0x0164841bc60000000000"                  \
430
          "  status:       0x0"                                     \
431
          "  time taken:"                                           \
432
          "Execution step completed OK."                            \
433
          "Processing WRITE_COMMAND."                               \
434
          "  shifting in:  0x0000000000fac02ac100000000100108"      \
435
          "  shifted out:  0x164841bc600000000000000000000000"      \
436
          "  status:       0x0"                                     \
437
          "  time taken:"                                           \
438
          "Execution step completed OK."                            \
439
          "Processing GO_COMMAND_WRITE."                            \
440
          "  shifting in:  0x00000000000e463a0ad6af60"              \
441
          "  shifted out:  0x0164841bc600000000000000"              \
442
          "  status:       0x0"                                     \
443
          "  time taken:"                                           \
444
          "New byte at 0x00100000 = 0xde"                           \
445
          "New byte at 0x00100001 = 0xad"                           \
446
          "Execution step completed OK."                            \
447
          "Test completed successfully."]                           \
448
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
449
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "2"        \
450
         "GO_COMMAND_WRITE" "dead"
451
 
452
# GO_COMMAND writing one half word for Wishbone aligned at byte 2.
453
run_libsim "JTAG GO_COMMAND (write) WB 1 half word, aligned byte 2" \
454
    [list "Initalization succeeded."                                \
455
          "Execution step completed OK."                            \
456
          "Resetting JTAG."                                         \
457
          "Execution step completed OK."                            \
458
          "Shifting instruction."                                   \
459
          "  shifting in:  0x01"                                    \
460
          "  shifted out:  0x01"                                    \
461
          "  time taken:"                                           \
462
          "Execution step completed OK."                            \
463
          "Selecting module."                                       \
464
          "  shifting in:  0x0000000000174841bc61"                  \
465
          "  shifted out:  0x0164841bc60000000000"                  \
466
          "  status:       0x0"                                     \
467
          "  time taken:"                                           \
468
          "Execution step completed OK."                            \
469
          "Processing WRITE_COMMAND."                               \
470
          "  shifting in:  0x00000000001bf5314100008000100108"      \
471
          "  shifted out:  0x164841bc600000000000000000000000"      \
472
          "  status:       0x0"                                     \
473
          "  time taken:"                                           \
474
          "Execution step completed OK."                            \
475
          "Processing GO_COMMAND_WRITE."                            \
476
          "  shifting in:  0x00000000000e463a0ad6af60"              \
477
          "  shifted out:  0x0164841bc600000000000000"              \
478
          "  status:       0x0"                                     \
479
          "  time taken:"                                           \
480
          "New byte at 0x00100002 = 0xde"                           \
481
          "New byte at 0x00100003 = 0xad"                           \
482
          "Execution step completed OK."                            \
483
          "Test completed successfully."]                           \
484
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
485
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100002" "2"        \
486
         "GO_COMMAND_WRITE" "dead"
487
 
488
# GO_COMMAND writing one word for Wishbone aligned at byte 0.
489
run_libsim "JTAG GO_COMMAND (write) WB 1 word, aligned byte 0" \
490
    [list "Initalization succeeded."                           \
491
          "Execution step completed OK."                       \
492
          "Resetting JTAG."                                    \
493
          "Execution step completed OK."                       \
494
          "Shifting instruction."                              \
495
          "  shifting in:  0x01"                               \
496
          "  shifted out:  0x01"                               \
497
          "  time taken:"                                      \
498
          "Execution step completed OK."                       \
499
          "Selecting module."                                  \
500
          "  shifting in:  0x0000000000174841bc61"             \
501
          "  shifted out:  0x0164841bc60000000000"             \
502
          "  status:       0x0"                                \
503
          "  time taken:"                                      \
504
          "Execution step completed OK."                       \
505
          "Processing WRITE_COMMAND."                          \
506
          "  shifting in:  0x00000000018f4396f780000000100088" \
507
          "  shifted out:  0x164841bc600000000000000000000000" \
508
          "  status:       0x0"                                \
509
          "  time taken:"                                      \
510
          "Execution step completed OK."                       \
511
          "Processing GO_COMMAND_WRITE."                       \
512
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
513
          "  shifted out:  0x0164841bc6000000000000000000"     \
514
          "  status:       0x0"                                \
515
          "  time taken:"                                      \
516
          "New byte at 0x00100000 = 0xde"                      \
517
          "New byte at 0x00100001 = 0xad"                      \
518
          "New byte at 0x00100002 = 0xbe"                      \
519
          "New byte at 0x00100003 = 0xef"                      \
520
          "Execution step completed OK."                       \
521
          "Test completed successfully."]                      \
522
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
523
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "4"        \
524
         "GO_COMMAND_WRITE" "deadbeef"
525
 
526
# Verify that longer writes work OK, at different boundaries. For byte access
527
# write 9 bytes, for half-word access write 10 bytes and for word access write
528
# 12 bytes.
529
 
530
# GO_COMMAND writing 9 bytes for Wishbone aligned at byte 0.
531
run_libsim "JTAG GO_COMMAND (write) WB 9 bytes, aligned byte 0"      \
532
    [list "Initalization succeeded."                                 \
533
          "Execution step completed OK."                             \
534
          "Resetting JTAG."                                          \
535
          "Execution step completed OK."                             \
536
          "Shifting instruction."                                    \
537
          "  shifting in:  0x01"                                     \
538
          "  shifted out:  0x01"                                     \
539
          "  time taken:"                                            \
540
          "Execution step completed OK."                             \
541
          "Selecting module."                                        \
542
          "  shifting in:  0x0000000000174841bc61"                   \
543
          "  shifted out:  0x0164841bc60000000000"                   \
544
          "  status:       0x0"                                      \
545
          "  time taken:"                                            \
546
          "Execution step completed OK."                             \
547
          "Processing WRITE_COMMAND."                                \
548
          "  shifting in:  0x00000000000af2d9ac20000000100008"       \
549
          "  shifted out:  0x164841bc600000000000000000000000"       \
550
          "  status:       0x0"                                      \
551
          "  time taken:"                                            \
552
          "Execution step completed OK."                             \
553
          "Processing GO_COMMAND_WRITE."                             \
554
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
555
          "  shifted out:  0x0164841bc60000000000000000000000000000" \
556
          "  status:       0x0"                                      \
557
          "  time taken:"                                            \
558
          "New byte at 0x00100000 = 0xde"                            \
559
          "New byte at 0x00100001 = 0xad"                            \
560
          "New byte at 0x00100002 = 0xbe"                            \
561
          "New byte at 0x00100003 = 0xef"                            \
562
          "New byte at 0x00100004 = 0xca"                            \
563
          "New byte at 0x00100005 = 0xfe"                            \
564
          "New byte at 0x00100006 = 0xba"                            \
565
          "New byte at 0x00100007 = 0xbe"                            \
566
          "New byte at 0x00100008 = 0xba"                            \
567
          "Execution step completed OK."                             \
568
          "Test completed successfully."]                            \
569
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
570
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "9"      \
571
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
572
 
573
# GO_COMMAND writing 9 bytes for Wishbone aligned at byte 1.
574
run_libsim "JTAG GO_COMMAND (write) WB 9 bytes, aligned byte 1"      \
575
    [list "Initalization succeeded."                                 \
576
          "Execution step completed OK."                             \
577
          "Resetting JTAG."                                          \
578
          "Execution step completed OK."                             \
579
          "Shifting instruction."                                    \
580
          "  shifting in:  0x01"                                     \
581
          "  shifted out:  0x01"                                     \
582
          "  time taken:"                                            \
583
          "Execution step completed OK."                             \
584
          "Selecting module."                                        \
585
          "  shifting in:  0x0000000000174841bc61"                   \
586
          "  shifted out:  0x0164841bc60000000000"                   \
587
          "  status:       0x0"                                      \
588
          "  time taken:"                                            \
589
          "Execution step completed OK."                             \
590
          "Processing WRITE_COMMAND."                                \
591
          "  shifting in:  0x0000000001c898eeac20010000100008"       \
592
          "  shifted out:  0x164841bc600000000000000000000000"       \
593
          "  status:       0x0"                                      \
594
          "  time taken:"                                            \
595
          "Execution step completed OK."                             \
596
          "Processing GO_COMMAND_WRITE."                             \
597
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
598
          "  shifted out:  0x0164841bc60000000000000000000000000000" \
599
          "  status:       0x0"                                      \
600
          "  time taken:"                                            \
601
          "New byte at 0x00100001 = 0xde"                            \
602
          "New byte at 0x00100002 = 0xad"                            \
603
          "New byte at 0x00100003 = 0xbe"                            \
604
          "New byte at 0x00100004 = 0xef"                            \
605
          "New byte at 0x00100005 = 0xca"                            \
606
          "New byte at 0x00100006 = 0xfe"                            \
607
          "New byte at 0x00100007 = 0xba"                            \
608
          "New byte at 0x00100008 = 0xbe"                            \
609
          "New byte at 0x00100009 = 0xba"                            \
610
          "Execution step completed OK."                             \
611
          "Test completed successfully."]                            \
612
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
613
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100001" "9"      \
614
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
615
 
616
# GO_COMMAND writing 9 bytes for Wishbone aligned at byte 2.
617
run_libsim "JTAG GO_COMMAND (write) WB 9 bytes, aligned byte 2"      \
618
    [list "Initalization succeeded."                                 \
619
          "Execution step completed OK."                             \
620
          "Resetting JTAG."                                          \
621
          "Execution step completed OK."                             \
622
          "Shifting instruction."                                    \
623
          "  shifting in:  0x01"                                     \
624
          "  shifted out:  0x01"                                     \
625
          "  time taken:"                                            \
626
          "Execution step completed OK."                             \
627
          "Selecting module."                                        \
628
          "  shifting in:  0x0000000000174841bc61"                   \
629
          "  shifted out:  0x0164841bc60000000000"                   \
630
          "  status:       0x0"                                      \
631
          "  time taken:"                                            \
632
          "Execution step completed OK."                             \
633
          "Processing WRITE_COMMAND."                                \
634
          "  shifting in:  0x0000000000ebc7c22c20008000100008"       \
635
          "  shifted out:  0x164841bc600000000000000000000000"       \
636
          "  status:       0x0"                                      \
637
          "  time taken:"                                            \
638
          "Execution step completed OK."                             \
639
          "Processing GO_COMMAND_WRITE."                             \
640
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
641
          "  shifted out:  0x0164841bc60000000000000000000000000000" \
642
          "  status:       0x0"                                      \
643
          "  time taken:"                                            \
644
          "New byte at 0x00100002 = 0xde"                            \
645
          "New byte at 0x00100003 = 0xad"                            \
646
          "New byte at 0x00100004 = 0xbe"                            \
647
          "New byte at 0x00100005 = 0xef"                            \
648
          "New byte at 0x00100006 = 0xca"                            \
649
          "New byte at 0x00100007 = 0xfe"                            \
650
          "New byte at 0x00100008 = 0xba"                            \
651
          "New byte at 0x00100009 = 0xbe"                            \
652
          "New byte at 0x0010000a = 0xba"                            \
653
          "Execution step completed OK."                             \
654
          "Test completed successfully."]                            \
655
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
656
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100002" "9"      \
657
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
658
 
659
# GO_COMMAND writing 9 bytes for Wishbone aligned at byte 3.
660
run_libsim "JTAG GO_COMMAND (write) WB 9 bytes, aligned byte 3"      \
661
    [list "Initalization succeeded."                                 \
662
          "Execution step completed OK."                             \
663
          "Resetting JTAG."                                          \
664
          "Execution step completed OK."                             \
665
          "Shifting instruction."                                    \
666
          "  shifting in:  0x01"                                     \
667
          "  shifted out:  0x01"                                     \
668
          "  time taken:"                                            \
669
          "Execution step completed OK."                             \
670
          "Selecting module."                                        \
671
          "  shifting in:  0x0000000000174841bc61"                   \
672
          "  shifted out:  0x0164841bc60000000000"                   \
673
          "  status:       0x0"                                      \
674
          "  time taken:"                                            \
675
          "Execution step completed OK."                             \
676
          "Processing WRITE_COMMAND."                                \
677
          "  shifting in:  0x000000000129adf52c20018000100008"       \
678
          "  shifted out:  0x164841bc600000000000000000000000"       \
679
          "  status:       0x0"                                      \
680
          "  time taken:"                                            \
681
          "Execution step completed OK."                             \
682
          "Processing GO_COMMAND_WRITE."                             \
683
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
684
          "  shifted out:  0x0164841bc60000000000000000000000000000" \
685
          "  status:       0x0"                                      \
686
          "  time taken:"                                            \
687
          "New byte at 0x00100003 = 0xde"                            \
688
          "New byte at 0x00100004 = 0xad"                            \
689
          "New byte at 0x00100005 = 0xbe"                            \
690
          "New byte at 0x00100006 = 0xef"                            \
691
          "New byte at 0x00100007 = 0xca"                            \
692
          "New byte at 0x00100008 = 0xfe"                            \
693
          "New byte at 0x00100009 = 0xba"                            \
694
          "New byte at 0x0010000a = 0xbe"                            \
695
          "New byte at 0x0010000b = 0xba"                            \
696
          "Execution step completed OK."                             \
697
          "Test completed successfully."]                            \
698
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
699
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100003" "9"      \
700
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
701
 
702
# GO_COMMAND writing 5 half words for Wishbone aligned at byte 0.
703
run_libsim "JTAG GO_COMMAND (write) WB 5 half words, aligned byte 0"   \
704
    [list "Initalization succeeded."                                   \
705
          "Execution step completed OK."                               \
706
          "Resetting JTAG."                                            \
707
          "Execution step completed OK."                               \
708
          "Shifting instruction."                                      \
709
          "  shifting in:  0x01"                                       \
710
          "  shifted out:  0x01"                                       \
711
          "  time taken:"                                              \
712
          "Execution step completed OK."                               \
713
          "Selecting module."                                          \
714
          "  shifting in:  0x0000000000174841bc61"                     \
715
          "  shifted out:  0x0164841bc60000000000"                     \
716
          "  status:       0x0"                                        \
717
          "  time taken:"                                              \
718
          "Execution step completed OK."                               \
719
          "Processing WRITE_COMMAND."                                  \
720
          "  shifting in:  0x0000000000c1ae0a0920000000100108"         \
721
          "  shifted out:  0x164841bc600000000000000000000000"         \
722
          "  status:       0x0"                                        \
723
          "  time taken:"                                              \
724
          "Execution step completed OK."                               \
725
          "Processing GO_COMMAND_WRITE."                               \
726
          "  shifting in:  0x0000000000185f4b7296abafabafea7eefb6af60" \
727
          "  shifted out:  0x0164841bc6000000000000000000000000000000" \
728
          "  status:       0x0"                                        \
729
          "  time taken:"                                              \
730
          "New byte at 0x00100000 = 0xde"                              \
731
          "New byte at 0x00100001 = 0xad"                              \
732
          "New byte at 0x00100002 = 0xbe"                              \
733
          "New byte at 0x00100003 = 0xef"                              \
734
          "New byte at 0x00100004 = 0xca"                              \
735
          "New byte at 0x00100005 = 0xfe"                              \
736
          "New byte at 0x00100006 = 0xba"                              \
737
          "New byte at 0x00100007 = 0xbe"                              \
738
          "New byte at 0x00100008 = 0xba"                              \
739
          "New byte at 0x00100009 = 0xad"                              \
740
          "Execution step completed OK."                               \
741
          "Test completed successfully."]                              \
742
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
743
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "a"      \
744
         "GO_COMMAND_WRITE" "deadbeefcafebabebaad"
745
 
746
# GO_COMMAND writing 5 half words for Wishbone aligned at byte 2.
747
run_libsim "JTAG GO_COMMAND (write) WB 5 half words, aligned byte 2"   \
748
    [list "Initalization succeeded."                                   \
749
          "Execution step completed OK."                               \
750
          "Resetting JTAG."                                            \
751
          "Execution step completed OK."                               \
752
          "Shifting instruction."                                      \
753
          "  shifting in:  0x01"                                       \
754
          "  shifted out:  0x01"                                       \
755
          "  time taken:"                                              \
756
          "Execution step completed OK."                               \
757
          "Selecting module."                                          \
758
          "  shifting in:  0x0000000000174841bc61"                     \
759
          "  shifted out:  0x0164841bc60000000000"                     \
760
          "  status:       0x0"                                        \
761
          "  time taken:"                                              \
762
          "Execution step completed OK."                               \
763
          "Processing WRITE_COMMAND."                                  \
764
          "  shifting in:  0x0000000000209b118920008000100108"         \
765
          "  shifted out:  0x164841bc600000000000000000000000"         \
766
          "  status:       0x0"                                        \
767
          "  time taken:"                                              \
768
          "Execution step completed OK."                               \
769
          "Processing GO_COMMAND_WRITE."                               \
770
          "  shifting in:  0x0000000000185f4b7296abafabafea7eefb6af60" \
771
          "  shifted out:  0x0164841bc6000000000000000000000000000000" \
772
          "  status:       0x0"                                        \
773
          "  time taken:"                                              \
774
          "New byte at 0x00100002 = 0xde"                              \
775
          "New byte at 0x00100003 = 0xad"                              \
776
          "New byte at 0x00100004 = 0xbe"                              \
777
          "New byte at 0x00100005 = 0xef"                              \
778
          "New byte at 0x00100006 = 0xca"                              \
779
          "New byte at 0x00100007 = 0xfe"                              \
780
          "New byte at 0x00100008 = 0xba"                              \
781
          "New byte at 0x00100009 = 0xbe"                              \
782
          "New byte at 0x0010000a = 0xba"                              \
783
          "New byte at 0x0010000b = 0xad"                              \
784
          "Execution step completed OK."                               \
785
          "Test completed successfully."]                              \
786
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
787
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100002" "a"      \
788
         "GO_COMMAND_WRITE" "deadbeefcafebabebaad"
789
 
790
# GO_COMMAND writing 3 words for Wishbone aligned at byte 0.
791
run_libsim "JTAG GO_COMMAND (write) WB 3 words, aligned byte 0"            \
792
    [list "Initalization succeeded."                                       \
793
          "Execution step completed OK."                                   \
794
          "Resetting JTAG."                                                \
795
          "Execution step completed OK."                                   \
796
          "Shifting instruction."                                          \
797
          "  shifting in:  0x01"                                           \
798
          "  shifted out:  0x01"                                           \
799
          "  time taken:"                                                  \
800
          "Execution step completed OK."                                   \
801
          "Selecting module."                                              \
802
          "  shifting in:  0x0000000000174841bc61"                         \
803
          "  shifted out:  0x0164841bc60000000000"                         \
804
          "  status:       0x0"                                            \
805
          "  time taken:"                                                  \
806
          "Execution step completed OK."                                   \
807
          "Processing WRITE_COMMAND."                                      \
808
          "  shifting in:  0x0000000001b42db63fa0000000100088"             \
809
          "  shifted out:  0x164841bc600000000000000000000000"             \
810
          "  status:       0x0"                                            \
811
          "  time taken:"                                                  \
812
          "Execution step completed OK."                                   \
813
          "Processing GO_COMMAND_WRITE."                                   \
814
          "  shifting in:  0x000000000014adb55b7601f6abafabafea7eefb6af60" \
815
          "  shifted out:  0x0164841bc60000000000000000000000000000000000" \
816
          "  status:       0x0"                                            \
817
          "  time taken:"                                                  \
818
          "New byte at 0x00100000 = 0xde"                                  \
819
          "New byte at 0x00100001 = 0xad"                                  \
820
          "New byte at 0x00100002 = 0xbe"                                  \
821
          "New byte at 0x00100003 = 0xef"                                  \
822
          "New byte at 0x00100004 = 0xca"                                  \
823
          "New byte at 0x00100005 = 0xfe"                                  \
824
          "New byte at 0x00100006 = 0xba"                                  \
825
          "New byte at 0x00100007 = 0xbe"                                  \
826
          "New byte at 0x00100008 = 0xba"                                  \
827
          "New byte at 0x00100009 = 0xad"                                  \
828
          "New byte at 0x0010000a = 0xf0"                                  \
829
          "New byte at 0x0010000b = 0x0d"                                  \
830
          "Execution step completed OK."                                   \
831
          "Test completed successfully."]                                  \
832
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
833
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "c"      \
834
         "GO_COMMAND_WRITE" "deadbeefcafebabebaadf00d"
835
 
836
# Test of access for CPU0. Much simpler, since access type, alignment and
837
# length are more prescribed. Make use of loop-report, which monitors MACLO
838
# (0x2801) and MACHI (0x2802). These are 32 bit values and presented in target
839
# endianess (which is big-endian for the OpenRISC, so the MS byte is as the
840
# highest address.
841
 
842
# GO_COMMAND writing 1 word for CPU0 aligned at byte 0.
843
run_libsim "JTAG GO_COMMAND (write) CPU0 1 word, aligned byte 0" \
844
    [list "Initalization succeeded."                             \
845
          "Execution step completed OK."                         \
846
          "Resetting JTAG."                                      \
847
          "Execution step completed OK."                         \
848
          "Shifting instruction."                                \
849
          "  shifting in:  0x01"                                 \
850
          "  shifted out:  0x01"                                 \
851
          "  time taken:"                                        \
852
          "Execution step completed OK."                         \
853
          "Selecting module."                                    \
854
          "  shifting in:  0x00000000000aff51d871"               \
855
          "  shifted out:  0x0164841bc60000000000"               \
856
          "  status:       0x0"                                  \
857
          "  time taken:"                                        \
858
          "Execution step completed OK."                         \
859
          "Processing WRITE_COMMAND."                            \
860
          "  shifting in:  0x0000000001933eb7e580010028000088"   \
861
          "  shifted out:  0x164841bc600000000000000000000000"   \
862
          "  status:       0x0"                                  \
863
          "  time taken:"                                        \
864
          "Execution step completed OK."                         \
865
          "Processing GO_COMMAND_WRITE."                         \
866
          "  shifting in:  0x00000000001a6f47467eefb6af60"       \
867
          "  shifted out:  0x0164841bc6000000000000000000"       \
868
          "  status:       0x0"                                  \
869
          "  time taken:"                                        \
870
          "New MACLO 0xefbeadde" \
871
          "Execution step completed OK."                         \
872
          "Test completed successfully."]                        \
873
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
874
         "8" "SELECT_MODULE" "1" "WRITE_COMMAND" "2" "2801" "4"          \
875
         "GO_COMMAND_WRITE" "deadbeef"
876
 
877
# Check address advances after GO (1 per word for CPU, 4 per word for
878
# WB). Test WB with writing and reading all sizes and lengths 1 through
879
# 0x10000. Test CPU0 with writing and reading words with a range of lengths,
880
# all of which should return length 4.
881
 
882
# - for WB byte access try lengths 1, 2, 3, 4, 5, 8 and 9
883
# - for WB half word access try lengths 2, 4, 6, 8 and 10
884
# - for WB full word access try lengths 4, 8 and 12
885
# - for SPR try length 4
886
 
887
# Advance address after writing 1 byte for WishBone (access type 0)
888
run_libsim "JTAG GO_COMMAND (write) WB write 1 byte address advance" \
889
    [list "Initalization succeeded."                           \
890
          "Execution step completed OK."                       \
891
          "Resetting JTAG."                                    \
892
          "Execution step completed OK."                       \
893
          "Shifting instruction."                              \
894
          "  shifting in:  0x01"                               \
895
          "  shifted out:  0x01"                               \
896
          "  time taken:"                                      \
897
          "Execution step completed OK."                       \
898
          "Selecting module."                                  \
899
          "  shifting in:  0x0000000000174841bc61"             \
900
          "  shifted out:  0x0164841bc60000000000"             \
901
          "  status:       0x0"                                \
902
          "  time taken:"                                      \
903
          "Execution step completed OK."                       \
904
          "Processing WRITE_COMMAND."                          \
905
          "  shifting in:  0x0000000000319cf96400000000100008" \
906
          "  shifted out:  0x164841bc600000000000000000000000" \
907
          "  status:       0x0"                                \
908
          "  time taken:"                                      \
909
          "Execution step completed OK."                       \
910
          "Processing GO_COMMAND_WRITE."                       \
911
          "  shifting in:  0x000000000006d6fa6e6f60"           \
912
          "  shifted out:  0x0164841bc6000000000000"           \
913
          "  status:       0x0"                                \
914
          "  time taken:"                                      \
915
          "Execution step completed OK."                       \
916
          "Processing READ_COMMAND."                           \
917
          "  shifting in:  0x00000000000000000000000b2420de30" \
918
          "  shifted out:  0x0e460cbc200001000010000000000000" \
919
          "  access_type:  0x0"                                \
920
          "  address:      0x100001"                           \
921
          "  length:       0x1"                                \
922
          "  status:       0x0"                                \
923
          "  time taken:"                                      \
924
          "Execution step completed OK."                       \
925
          "Test completed successfully."]                      \
926
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
927
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "1" \
928
         "GO_COMMAND_WRITE" "de" "READ_COMMAND"
929
 
930
# Advance address after writing 2 bytes for WishBone (access type 0)
931
run_libsim "JTAG GO_COMMAND (write) WB write 2 bytes address advance" \
932
    [list "Initalization succeeded."                           \
933
          "Execution step completed OK."                       \
934
          "Resetting JTAG."                                    \
935
          "Execution step completed OK."                       \
936
          "Shifting instruction."                              \
937
          "  shifting in:  0x01"                               \
938
          "  shifted out:  0x01"                               \
939
          "  time taken:"                                      \
940
          "Execution step completed OK."                       \
941
          "Selecting module."                                  \
942
          "  shifting in:  0x0000000000174841bc61"             \
943
          "  shifted out:  0x0164841bc60000000000"             \
944
          "  status:       0x0"                                \
945
          "  time taken:"                                      \
946
          "Execution step completed OK."                       \
947
          "Processing WRITE_COMMAND."                          \
948
          "  shifting in:  0x0000000001eaedff2500000000100008" \
949
          "  shifted out:  0x164841bc600000000000000000000000" \
950
          "  status:       0x0"                                \
951
          "  time taken:"                                      \
952
          "Execution step completed OK."                       \
953
          "Processing GO_COMMAND_WRITE."                       \
954
          "  shifting in:  0x00000000000e463a0ad6af60"         \
955
          "  shifted out:  0x0164841bc600000000000000"         \
956
          "  status:       0x0"                                \
957
          "  time taken:"                                      \
958
          "Execution step completed OK."                       \
959
          "Processing READ_COMMAND."                           \
960
          "  shifting in:  0x00000000000000000000000b2420de30" \
961
          "  shifted out:  0x0ebe2296e10000800010000000000000" \
962
          "  access_type:  0x0"                                \
963
          "  address:      0x100002"                           \
964
          "  length:       0x2"                                \
965
          "  status:       0x0"                                \
966
          "  time taken:"                                      \
967
          "Execution step completed OK."                       \
968
          "Test completed successfully."]                      \
969
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
970
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "2" \
971
         "GO_COMMAND_WRITE" "dead" "READ_COMMAND"
972
 
973
# Advance address after writing 3 bytes for WishBone (access type 0)
974
run_libsim "JTAG GO_COMMAND (write) WB write 3 bytes address advance" \
975
    [list "Initalization succeeded."                           \
976
          "Execution step completed OK."                       \
977
          "Resetting JTAG."                                    \
978
          "Execution step completed OK."                       \
979
          "Shifting instruction."                              \
980
          "  shifting in:  0x01"                               \
981
          "  shifted out:  0x01"                               \
982
          "  time taken:"                                      \
983
          "Execution step completed OK."                       \
984
          "Selecting module."                                  \
985
          "  shifting in:  0x0000000000174841bc61"             \
986
          "  shifted out:  0x0164841bc60000000000"             \
987
          "  status:       0x0"                                \
988
          "  time taken:"                                      \
989
          "Execution step completed OK."                       \
990
          "Processing WRITE_COMMAND."                          \
991
          "  shifting in:  0x0000000000dc247a4480000000100008" \
992
          "  shifted out:  0x164841bc600000000000000000000000" \
993
          "  status:       0x0"                                \
994
          "  time taken:"                                      \
995
          "Execution step completed OK."                       \
996
          "Processing GO_COMMAND_WRITE."                       \
997
          "  shifting in:  0x00000000001599d9120fb6af60"       \
998
          "  shifted out:  0x0164841bc60000000000000000"       \
999
          "  status:       0x0"                                \
1000
          "  time taken:"                                      \
1001
          "Execution step completed OK."                       \
1002
          "Processing READ_COMMAND."                           \
1003
          "  shifting in:  0x00000000000000000000000b2420de30" \
1004
          "  shifted out:  0x0e4a8124808001800010000000000000" \
1005
          "  access_type:  0x0"                                \
1006
          "  address:      0x100003"                           \
1007
          "  length:       0x3"                                \
1008
          "  status:       0x0"                                \
1009
          "  time taken:"                                      \
1010
          "Execution step completed OK."                       \
1011
          "Test completed successfully."]                      \
1012
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1013
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "3" \
1014
         "GO_COMMAND_WRITE" "deadbe" "READ_COMMAND"
1015
 
1016
# Advance address after writing 4 bytes for WishBone (access type 0)
1017
run_libsim "JTAG GO_COMMAND (write) WB write 4 bytes address advance" \
1018
    [list "Initalization succeeded."                           \
1019
          "Execution step completed OK."                       \
1020
          "Resetting JTAG."                                    \
1021
          "Execution step completed OK."                       \
1022
          "Shifting instruction."                              \
1023
          "  shifting in:  0x01"                               \
1024
          "  shifted out:  0x01"                               \
1025
          "  time taken:"                                      \
1026
          "Execution step completed OK."                       \
1027
          "Selecting module."                                  \
1028
          "  shifting in:  0x0000000000174841bc61"             \
1029
          "  shifted out:  0x0164841bc60000000000"             \
1030
          "  status:       0x0"                                \
1031
          "  time taken:"                                      \
1032
          "Execution step completed OK."                       \
1033
          "Processing WRITE_COMMAND."                          \
1034
          "  shifting in:  0x000000000107557c0580000000100008" \
1035
          "  shifted out:  0x164841bc600000000000000000000000" \
1036
          "  status:       0x0"                                \
1037
          "  time taken:"                                      \
1038
          "Execution step completed OK."                       \
1039
          "Processing GO_COMMAND_WRITE."                       \
1040
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
1041
          "  shifted out:  0x0164841bc6000000000000000000"     \
1042
          "  status:       0x0"                                \
1043
          "  time taken:"                                      \
1044
          "Execution step completed OK."                       \
1045
          "Processing READ_COMMAND."                           \
1046
          "  shifting in:  0x00000000000000000000000b2420de30" \
1047
          "  shifted out:  0x0ec23583818000400010000000000000" \
1048
          "  access_type:  0x0"                                \
1049
          "  address:      0x100004"                           \
1050
          "  length:       0x4"                                \
1051
          "  status:       0x0"                                \
1052
          "  time taken:"                                      \
1053
          "Execution step completed OK."                       \
1054
          "Test completed successfully."]                      \
1055
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1056
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "4" \
1057
         "GO_COMMAND_WRITE" "deadbeef" "READ_COMMAND"
1058
 
1059
# Advance address after writing 5 bytes for WishBone (access type 0)
1060
run_libsim "JTAG GO_COMMAND (write) WB write 5 bytes address advance" \
1061
    [list "Initalization succeeded."                           \
1062
          "Execution step completed OK."                       \
1063
          "Resetting JTAG."                                    \
1064
          "Execution step completed OK."                       \
1065
          "Shifting instruction."                              \
1066
          "  shifting in:  0x01"                               \
1067
          "  shifted out:  0x01"                               \
1068
          "  time taken:"                                      \
1069
          "Execution step completed OK."                       \
1070
          "Selecting module."                                  \
1071
          "  shifting in:  0x0000000000174841bc61"             \
1072
          "  shifted out:  0x0164841bc60000000000"             \
1073
          "  status:       0x0"                                \
1074
          "  time taken:"                                      \
1075
          "Execution step completed OK."                       \
1076
          "Processing WRITE_COMMAND."                          \
1077
          "  shifting in:  0x00000000004740b8f440000000100008" \
1078
          "  shifted out:  0x164841bc600000000000000000000000" \
1079
          "  status:       0x0"                                \
1080
          "  time taken:"                                      \
1081
          "Execution step completed OK."                       \
1082
          "Processing GO_COMMAND_WRITE."                       \
1083
          "  shifting in:  0x000000000009ac236c4a7eefb6af60"   \
1084
          "  shifted out:  0x0164841bc600000000000000000000"   \
1085
          "  status:       0x0"                                \
1086
          "  time taken:"                                      \
1087
          "Execution step completed OK."                       \
1088
          "Processing READ_COMMAND."                           \
1089
          "  shifting in:  0x00000000000000000000000b2420de30" \
1090
          "  shifted out:  0x13f75a14604001400010000000000000" \
1091
          "  access_type:  0x0"                                \
1092
          "  address:      0x100005"                           \
1093
          "  length:       0x5"                                \
1094
          "  status:       0x0"                                \
1095
          "  time taken:"                                      \
1096
          "Execution step completed OK."                       \
1097
          "Test completed successfully."]                      \
1098
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1099
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "5" \
1100
         "GO_COMMAND_WRITE" "deadbeefca" "READ_COMMAND"
1101
 
1102
# Advance address after writing 8 bytes for WishBone (access type 0)
1103
run_libsim "JTAG GO_COMMAND (write) WB write 8 bytes address advance" \
1104
    [list "Initalization succeeded."                           \
1105
          "Execution step completed OK."                       \
1106
          "Resetting JTAG."                                    \
1107
          "Execution step completed OK."                       \
1108
          "Shifting instruction."                              \
1109
          "  shifting in:  0x01"                               \
1110
          "  shifted out:  0x01"                               \
1111
          "  time taken:"                                      \
1112
          "Execution step completed OK."                       \
1113
          "Selecting module."                                  \
1114
          "  shifting in:  0x0000000000174841bc61"             \
1115
          "  shifted out:  0x0164841bc60000000000"             \
1116
          "  status:       0x0"                                \
1117
          "  time taken:"                                      \
1118
          "Execution step completed OK."                       \
1119
          "Processing WRITE_COMMAND."                          \
1120
          "  shifting in:  0x000000000171893d95c0000000100008" \
1121
          "  shifted out:  0x164841bc600000000000000000000000" \
1122
          "  status:       0x0"                                \
1123
          "  time taken:"                                      \
1124
          "Execution step completed OK."                       \
1125
          "Processing GO_COMMAND_WRITE."                       \
1126
          "  shifting in:  0x000000000014db90944fabafea7eefb6af60" \
1127
          "  shifted out:  0x0164841bc600000000000000000000000000" \
1128
          "  status:       0x0"                                \
1129
          "  time taken:"                                      \
1130
          "Execution step completed OK."                       \
1131
          "Processing READ_COMMAND."                           \
1132
          "  shifting in:  0x00000000000000000000000b2420de30" \
1133
          "  shifted out:  0x134b2e6d21c000200010000000000000" \
1134
          "  access_type:  0x0"                                \
1135
          "  address:      0x100008"                           \
1136
          "  length:       0x8"                                \
1137
          "  status:       0x0"                                \
1138
          "  time taken:"                                      \
1139
          "Execution step completed OK."                       \
1140
          "Test completed successfully."]                      \
1141
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1142
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "8" \
1143
         "GO_COMMAND_WRITE" "deadbeefcafebabe" "READ_COMMAND"
1144
 
1145
# Advance address after writing 9 bytes for WishBone (access type 0)
1146
run_libsim "JTAG GO_COMMAND (write) WB write 9 bytes address advance" \
1147
    [list "Initalization succeeded."                           \
1148
          "Execution step completed OK."                       \
1149
          "Resetting JTAG."                                    \
1150
          "Execution step completed OK."                       \
1151
          "Shifting instruction."                              \
1152
          "  shifting in:  0x01"                               \
1153
          "  shifted out:  0x01"                               \
1154
          "  time taken:"                                      \
1155
          "Execution step completed OK."                       \
1156
          "Selecting module."                                  \
1157
          "  shifting in:  0x0000000000174841bc61"             \
1158
          "  shifted out:  0x0164841bc60000000000"             \
1159
          "  status:       0x0"                                \
1160
          "  time taken:"                                      \
1161
          "Execution step completed OK."                       \
1162
          "Processing WRITE_COMMAND."                          \
1163
          "  shifting in:  0x00000000000af2d9ac20000000100008" \
1164
          "  shifted out:  0x164841bc600000000000000000000000" \
1165
          "  status:       0x0"                                \
1166
          "  time taken:"                                      \
1167
          "Execution step completed OK."                       \
1168
          "Processing GO_COMMAND_WRITE."                       \
1169
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
1170
          "  shifted out:  0x0164841bc60000000000000000000000000000" \
1171
          "  status:       0x0"                                \
1172
          "  time taken:"                                      \
1173
          "Execution step completed OK."                       \
1174
          "Processing READ_COMMAND."                           \
1175
          "  shifting in:  0x00000000000000000000000b2420de30" \
1176
          "  shifted out:  0x009ea7e8002001200010000000000000" \
1177
          "  access_type:  0x0"                                \
1178
          "  address:      0x100009"                           \
1179
          "  length:       0x9"                                \
1180
          "  status:       0x0"                                \
1181
          "  time taken:"                                      \
1182
          "Execution step completed OK."                       \
1183
          "Test completed successfully."]                      \
1184
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1185
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "9" \
1186
         "GO_COMMAND_WRITE" "deadbeefcafebabeba" "READ_COMMAND"
1187
 
1188
# Advance address after writing 1 half word (2 bytes) for WishBone (access
1189
# type 1)
1190
run_libsim "JTAG GO_COMMAND (write) WB write 1 half word address advance" \
1191
    [list "Initalization succeeded."                           \
1192
          "Execution step completed OK."                       \
1193
          "Resetting JTAG."                                    \
1194
          "Execution step completed OK."                       \
1195
          "Shifting instruction."                              \
1196
          "  shifting in:  0x01"                               \
1197
          "  shifted out:  0x01"                               \
1198
          "  time taken:"                                      \
1199
          "Execution step completed OK."                       \
1200
          "Selecting module."                                  \
1201
          "  shifting in:  0x0000000000174841bc61"             \
1202
          "  shifted out:  0x0164841bc60000000000"             \
1203
          "  status:       0x0"                                \
1204
          "  time taken:"                                      \
1205
          "Execution step completed OK."                       \
1206
          "Processing WRITE_COMMAND."                          \
1207
          "  shifting in:  0x0000000000fac02ac100000000100108" \
1208
          "  shifted out:  0x164841bc600000000000000000000000" \
1209
          "  status:       0x0"                                \
1210
          "  time taken:"                                      \
1211
          "Execution step completed OK."                       \
1212
          "Processing GO_COMMAND_WRITE."                       \
1213
          "  shifting in:  0x00000000000e463a0ad6af60"         \
1214
          "  shifted out:  0x0164841bc600000000000000"         \
1215
          "  status:       0x0"                                \
1216
          "  time taken:"                                      \
1217
          "Execution step completed OK."                       \
1218
          "Processing READ_COMMAND."                           \
1219
          "  shifting in:  0x00000000000000000000000b2420de30" \
1220
          "  shifted out:  0x08c3cb5a010000800010010000000000" \
1221
          "  access_type:  0x1"                                \
1222
          "  address:      0x100002"                           \
1223
          "  length:       0x2"                                \
1224
          "  status:       0x0"                                \
1225
          "  time taken:"                                      \
1226
          "Execution step completed OK."                       \
1227
          "Test completed successfully."]                      \
1228
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1229
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "2" \
1230
         "GO_COMMAND_WRITE" "dead" "READ_COMMAND"
1231
 
1232
# Advance address after writing 2 half words (4 bytes) for WishBone (access
1233
# type 1)
1234
run_libsim "JTAG GO_COMMAND (write) WB write 2 half words address advance" \
1235
    [list "Initalization succeeded."                           \
1236
          "Execution step completed OK."                       \
1237
          "Resetting JTAG."                                    \
1238
          "Execution step completed OK."                       \
1239
          "Shifting instruction."                              \
1240
          "  shifting in:  0x01"                               \
1241
          "  shifted out:  0x01"                               \
1242
          "  time taken:"                                      \
1243
          "Execution step completed OK."                       \
1244
          "Selecting module."                                  \
1245
          "  shifting in:  0x0000000000174841bc61"             \
1246
          "  shifted out:  0x0164841bc60000000000"             \
1247
          "  status:       0x0"                                \
1248
          "  time taken:"                                      \
1249
          "Execution step completed OK."                       \
1250
          "Processing WRITE_COMMAND."                          \
1251
          "  shifting in:  0x00000000001778a9e180000000100108" \
1252
          "  shifted out:  0x164841bc600000000000000000000000" \
1253
          "  status:       0x0"                                \
1254
          "  time taken:"                                      \
1255
          "Execution step completed OK."                       \
1256
          "Processing GO_COMMAND_WRITE."                       \
1257
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
1258
          "  shifted out:  0x0164841bc6000000000000000000"     \
1259
          "  status:       0x0"                                \
1260
          "  time taken:"                                      \
1261
          "Execution step completed OK."                       \
1262
          "Processing READ_COMMAND."                           \
1263
          "  shifting in:  0x00000000000000000000000b2420de30" \
1264
          "  shifted out:  0x08bfdc4f618000400010010000000000" \
1265
          "  access_type:  0x1"                                \
1266
          "  address:      0x100004"                           \
1267
          "  length:       0x4"                                \
1268
          "  status:       0x0"                                \
1269
          "  time taken:"                                      \
1270
          "Execution step completed OK."                       \
1271
          "Test completed successfully."]                      \
1272
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1273
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "4" \
1274
         "GO_COMMAND_WRITE" "deadbeef" "READ_COMMAND"
1275
 
1276
# Advance address after writing 3 half words (6 bytes) for WishBone (access
1277
# type 1)
1278
run_libsim "JTAG GO_COMMAND (write) WB write 3 half words address advance" \
1279
    [list "Initalization succeeded."                           \
1280
          "Execution step completed OK."                       \
1281
          "Resetting JTAG."                                    \
1282
          "Execution step completed OK."                       \
1283
          "Shifting instruction."                              \
1284
          "  shifting in:  0x01"                               \
1285
          "  shifted out:  0x01"                               \
1286
          "  time taken:"                                      \
1287
          "Execution step completed OK."                       \
1288
          "Selecting module."                                  \
1289
          "  shifting in:  0x0000000000174841bc61"             \
1290
          "  shifted out:  0x0164841bc60000000000"             \
1291
          "  status:       0x0"                                \
1292
          "  time taken:"                                      \
1293
          "Execution step completed OK."                       \
1294
          "Processing WRITE_COMMAND."                          \
1295
          "  shifting in:  0x00000000008c1c6b5140000000100108" \
1296
          "  shifted out:  0x164841bc600000000000000000000000" \
1297
          "  status:       0x0"                                \
1298
          "  time taken:"                                      \
1299
          "Execution step completed OK."                       \
1300
          "Processing GO_COMMAND_WRITE."                       \
1301
          "  shifting in:  0x00000000000c6961b84fea7eefb6af60" \
1302
          "  shifted out:  0x0164841bc60000000000000000000000" \
1303
          "  status:       0x0"                                \
1304
          "  time taken:"                                      \
1305
          "Execution step completed OK."                       \
1306
          "Processing READ_COMMAND."                           \
1307
          "  shifting in:  0x00000000000000000000000b2420de30" \
1308
          "  shifted out:  0x15729df2414000c00010010000000000" \
1309
          "  access_type:  0x1"                                \
1310
          "  address:      0x100006"                           \
1311
          "  length:       0x6"                                \
1312
          "  status:       0x0"                                \
1313
          "  time taken:"                                      \
1314
          "Execution step completed OK."                       \
1315
          "Test completed successfully."]                      \
1316
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1317
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "6" \
1318
         "GO_COMMAND_WRITE" "deadbeefcafe" "READ_COMMAND"
1319
 
1320
# Advance address after writing 4 half words (8 bytes) for WishBone (access
1321
# type 1)
1322
run_libsim "JTAG GO_COMMAND (write) WB write 4 half words address advance" \
1323
    [list "Initalization succeeded."                           \
1324
          "Execution step completed OK."                       \
1325
          "Resetting JTAG."                                    \
1326
          "Execution step completed OK."                       \
1327
          "Shifting instruction."                              \
1328
          "  shifting in:  0x01"                               \
1329
          "  shifted out:  0x01"                               \
1330
          "  time taken:"                                      \
1331
          "Execution step completed OK."                       \
1332
          "Selecting module."                                  \
1333
          "  shifting in:  0x0000000000174841bc61"             \
1334
          "  shifted out:  0x0164841bc60000000000"             \
1335
          "  status:       0x0"                                \
1336
          "  time taken:"                                      \
1337
          "Execution step completed OK."                       \
1338
          "Processing WRITE_COMMAND."                          \
1339
          "  shifting in:  0x000000000061a4e871c0000000100108" \
1340
          "  shifted out:  0x164841bc600000000000000000000000" \
1341
          "  status:       0x0"                                \
1342
          "  time taken:"                                      \
1343
          "Execution step completed OK."                       \
1344
          "Processing GO_COMMAND_WRITE."                       \
1345
          "  shifting in:  0x000000000014db90944fabafea7eefb6af60" \
1346
          "  shifted out:  0x0164841bc600000000000000000000000000" \
1347
          "  status:       0x0"                                \
1348
          "  time taken:"                                      \
1349
          "Execution step completed OK."                       \
1350
          "Processing READ_COMMAND."                           \
1351
          "  shifting in:  0x00000000000000000000000b2420de30" \
1352
          "  shifted out:  0x1536c7a1c1c000200010010000000000" \
1353
          "  access_type:  0x1"                                \
1354
          "  address:      0x100008"                           \
1355
          "  length:       0x8"                                \
1356
          "  status:       0x0"                                \
1357
          "  time taken:"                                      \
1358
          "Execution step completed OK."                       \
1359
          "Test completed successfully."]                      \
1360
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1361
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "8" \
1362
         "GO_COMMAND_WRITE" "deadbeefcafebabe" "READ_COMMAND"
1363
 
1364
# Advance address after writing 5 half words (10 bytes) for WishBone (access
1365
# type 1)
1366
run_libsim "JTAG GO_COMMAND (write) WB write 5 half words address advance" \
1367
    [list "Initalization succeeded."                           \
1368
          "Execution step completed OK."                       \
1369
          "Resetting JTAG."                                    \
1370
          "Execution step completed OK."                       \
1371
          "Shifting instruction."                              \
1372
          "  shifting in:  0x01"                               \
1373
          "  shifted out:  0x01"                               \
1374
          "  time taken:"                                      \
1375
          "Execution step completed OK."                       \
1376
          "Selecting module."                                  \
1377
          "  shifting in:  0x0000000000174841bc61"             \
1378
          "  shifted out:  0x0164841bc60000000000"             \
1379
          "  status:       0x0"                                \
1380
          "  time taken:"                                      \
1381
          "Execution step completed OK."                       \
1382
          "Processing WRITE_COMMAND."                          \
1383
          "  shifting in:  0x0000000000c1ae0a0920000000100108" \
1384
          "  shifted out:  0x164841bc600000000000000000000000" \
1385
          "  status:       0x0"                                \
1386
          "  time taken:"                                      \
1387
          "Execution step completed OK."                       \
1388
          "Processing GO_COMMAND_WRITE."                       \
1389
          "  shifting in:  0x0000000000185f4b7296abafabafea7eefb6af60" \
1390
          "  shifted out:  0x0164841bc6000000000000000000000000000000" \
1391
          "  status:       0x0"                                \
1392
          "  time taken:"                                      \
1393
          "Execution step completed OK."                       \
1394
          "Processing READ_COMMAND."                           \
1395
          "  shifting in:  0x00000000000000000000000b2420de30" \
1396
          "  shifted out:  0x061b600e212000a00010010000000000" \
1397
          "  access_type:  0x1"                                \
1398
          "  address:      0x10000a"                           \
1399
          "  length:       0xa"                                \
1400
          "  status:       0x0"                                \
1401
          "  time taken:"                                      \
1402
          "Execution step completed OK."                       \
1403
          "Test completed successfully."]                      \
1404
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1405
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "a" \
1406
         "GO_COMMAND_WRITE" "deadbeefcafebabebaad" "READ_COMMAND"
1407
 
1408
# Advance address after writing 1 word (4 bytes) for WishBone (access type 2)
1409
run_libsim "JTAG GO_COMMAND (write) WB write 1 word address advance" \
1410
    [list "Initalization succeeded."                           \
1411
          "Execution step completed OK."                       \
1412
          "Resetting JTAG."                                    \
1413
          "Execution step completed OK."                       \
1414
          "Shifting instruction."                              \
1415
          "  shifting in:  0x01"                               \
1416
          "  shifted out:  0x01"                               \
1417
          "  time taken:"                                      \
1418
          "Execution step completed OK."                       \
1419
          "Selecting module."                                  \
1420
          "  shifting in:  0x0000000000174841bc61"             \
1421
          "  shifted out:  0x0164841bc60000000000"             \
1422
          "  status:       0x0"                                \
1423
          "  time taken:"                                      \
1424
          "Execution step completed OK."                       \
1425
          "Processing WRITE_COMMAND."                          \
1426
          "  shifting in:  0x00000000018f4396f780000000100088" \
1427
          "  shifted out:  0x164841bc600000000000000000000000" \
1428
          "  status:       0x0"                                \
1429
          "  time taken:"                                      \
1430
          "Execution step completed OK."                       \
1431
          "Processing GO_COMMAND_WRITE."                       \
1432
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
1433
          "  shifted out:  0x0164841bc6000000000000000000"     \
1434
          "  status:       0x0"                                \
1435
          "  time taken:"                                      \
1436
          "Execution step completed OK."                       \
1437
          "Processing READ_COMMAND."                           \
1438
          "  shifting in:  0x00000000000000000000000b2420de30" \
1439
          "  shifted out:  0x104bd101e18000400010008000000000" \
1440
          "  access_type:  0x2"                                \
1441
          "  address:      0x100004"                           \
1442
          "  length:       0x4"                                \
1443
          "  status:       0x0"                                \
1444
          "  time taken:"                                      \
1445
          "Execution step completed OK."                       \
1446
          "Test completed successfully."]                      \
1447
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1448
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "4" \
1449
         "GO_COMMAND_WRITE" "deadbeef" "READ_COMMAND"
1450
 
1451
# Advance address after writing 2 words (8 bytes) for WishBone (access type 2)
1452
run_libsim "JTAG GO_COMMAND (write) WB write 2 words address advance" \
1453
    [list "Initalization succeeded."                           \
1454
          "Execution step completed OK."                       \
1455
          "Resetting JTAG."                                    \
1456
          "Execution step completed OK."                       \
1457
          "Shifting instruction."                              \
1458
          "  shifting in:  0x01"                               \
1459
          "  shifted out:  0x01"                               \
1460
          "  time taken:"                                      \
1461
          "Execution step completed OK."                       \
1462
          "Selecting module."                                  \
1463
          "  shifting in:  0x0000000000174841bc61"             \
1464
          "  shifted out:  0x0164841bc60000000000"             \
1465
          "  status:       0x0"                                \
1466
          "  time taken:"                                      \
1467
          "Execution step completed OK."                       \
1468
          "Processing WRITE_COMMAND."                          \
1469
          "  shifting in:  0x0000000001f99fd767c0000000100088" \
1470
          "  shifted out:  0x164841bc600000000000000000000000" \
1471
          "  status:       0x0"                                \
1472
          "  time taken:"                                      \
1473
          "Execution step completed OK."                       \
1474
          "Processing GO_COMMAND_WRITE."                       \
1475
          "  shifting in:  0x000000000014db90944fabafea7eefb6af60" \
1476
          "  shifted out:  0x0164841bc600000000000000000000000000" \
1477
          "  status:       0x0"                                \
1478
          "  time taken:"                                      \
1479
          "Execution step completed OK."                       \
1480
          "Processing READ_COMMAND."                           \
1481
          "  shifting in:  0x00000000000000000000000b2420de30" \
1482
          "  shifted out:  0x0dc2caef41c000200010008000000000" \
1483
          "  access_type:  0x2"                                \
1484
          "  address:      0x100008"                           \
1485
          "  length:       0x8"                                \
1486
          "  status:       0x0"                                \
1487
          "  time taken:"                                      \
1488
          "Execution step completed OK."                       \
1489
          "Test completed successfully."]                      \
1490
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1491
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "8" \
1492
         "GO_COMMAND_WRITE" "deadbeefcafebabe" "READ_COMMAND"
1493
 
1494
# Advance address after writing 3 words (12 bytes) for WishBone (access type
1495
# 2)
1496
run_libsim "JTAG GO_COMMAND (write) WB write 3 words address advance" \
1497
    [list "Initalization succeeded."                           \
1498
          "Execution step completed OK."                       \
1499
          "Resetting JTAG."                                    \
1500
          "Execution step completed OK."                       \
1501
          "Shifting instruction."                              \
1502
          "  shifting in:  0x01"                               \
1503
          "  shifted out:  0x01"                               \
1504
          "  time taken:"                                      \
1505
          "Execution step completed OK."                       \
1506
          "Selecting module."                                  \
1507
          "  shifting in:  0x0000000000174841bc61"             \
1508
          "  shifted out:  0x0164841bc60000000000"             \
1509
          "  status:       0x0"                                \
1510
          "  time taken:"                                      \
1511
          "Execution step completed OK."                       \
1512
          "Processing WRITE_COMMAND."                          \
1513
          "  shifting in:  0x0000000001b42db63fa0000000100088" \
1514
          "  shifted out:  0x164841bc600000000000000000000000" \
1515
          "  status:       0x0"                                \
1516
          "  time taken:"                                      \
1517
          "Execution step completed OK."                       \
1518
          "Processing GO_COMMAND_WRITE."                       \
1519
          "  shifting in:  0x000000000014adb55b7601f6abafabafea7eefb6af60" \
1520
          "  shifted out:  0x0164841bc60000000000000000000000000000000000" \
1521
          "  status:       0x0"                                \
1522
          "  time taken:"                                      \
1523
          "Execution step completed OK."                       \
1524
          "Processing READ_COMMAND."                           \
1525
          "  shifting in:  0x00000000000000000000000b2420de30" \
1526
          "  shifted out:  0x1e937a55c1a000600010008000000000" \
1527
          "  access_type:  0x2"                                \
1528
          "  address:      0x10000c"                           \
1529
          "  length:       0xc"                                \
1530
          "  status:       0x0"                                \
1531
          "  time taken:"                                      \
1532
          "Execution step completed OK."                       \
1533
          "Test completed successfully."]                      \
1534
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1535
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "c" \
1536
         "GO_COMMAND_WRITE" "deadbeefcafebabebaadf00d" "READ_COMMAND"
1537
 
1538
# Advance address after writing 1 word for CPU0 (access type 2). The address
1539
# should advance by 1 (word, since SPRs are word addressed).
1540
run_libsim "JTAG GO_COMMAND (write) CPU0 write 1 word address advance" \
1541
    [list "Initalization succeeded."                           \
1542
          "Execution step completed OK."                       \
1543
          "Resetting JTAG."                                    \
1544
          "Execution step completed OK."                       \
1545
          "Shifting instruction."                              \
1546
          "  shifting in:  0x01"                               \
1547
          "  shifted out:  0x01"                               \
1548
          "  time taken:"                                      \
1549
          "Execution step completed OK."                       \
1550
          "Selecting module."                                  \
1551
          "  shifting in:  0x00000000000aff51d871"             \
1552
          "  shifted out:  0x0164841bc60000000000"             \
1553
          "  status:       0x0"                                \
1554
          "  time taken:"                                      \
1555
          "Execution step completed OK."                       \
1556
          "Processing WRITE_COMMAND."                          \
1557
          "  shifting in:  0x0000000001933eb7e580010028000088" \
1558
          "  shifted out:  0x164841bc600000000000000000000000" \
1559
          "  status:       0x0"                                \
1560
          "  time taken:"                                      \
1561
          "Execution step completed OK."                       \
1562
          "Processing GO_COMMAND_WRITE."                       \
1563
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
1564
          "  shifted out:  0x0164841bc6000000000000000000"     \
1565
          "  status:       0x0"                                \
1566
          "  time taken:"                                      \
1567
          "Execution step completed OK."                       \
1568
          "Processing READ_COMMAND."                           \
1569
          "  shifting in:  0x00000000000000000000000b2420de30" \
1570
          "  shifted out:  0x0f059be9218000802800008000000000" \
1571
          "  access_type:  0x2"                                \
1572
          "  address:      0x2802"                             \
1573
          "  length:       0x4"                                \
1574
          "  status:       0x0"                                \
1575
          "  time taken:"                                      \
1576
          "Execution step completed OK."                       \
1577
          "Test completed successfully."]                      \
1578
    "lib-jtag/lib-jtag-full" "" "loop/loop" "RESET" "INSTRUCTION" \
1579
         "8" "SELECT_MODULE" "1" "WRITE_COMMAND" "2" "2801" "4"   \
1580
         "GO_COMMAND_WRITE" "deadbeef" "READ_COMMAND"
1581
 
1582
# Tests of overrun and underrun. For Wishbone check both on different access
1583
# sizes.
1584
 
1585
# GO_COMMAND_WRITE for WishBone underrun for byte access
1586
run_libsim "JTAG GO_COMMAND (write) WB byte access underrun"     \
1587
    [list "Initalization succeeded."                             \
1588
          "Execution step completed OK."                         \
1589
          "Resetting JTAG."                                      \
1590
          "Execution step completed OK."                         \
1591
          "Shifting instruction."                                \
1592
          "  shifting in:  0x01"                                 \
1593
          "  shifted out:  0x01"                                 \
1594
          "  time taken:"                                        \
1595
          "Execution step completed OK."                         \
1596
          "Selecting module."                                    \
1597
          "  shifting in:  0x0000000000174841bc61"               \
1598
          "  shifted out:  0x0164841bc60000000000"               \
1599
          "  status:       0x0"                                  \
1600
          "  time taken:"                                        \
1601
          "Execution step completed OK."                         \
1602
          "Processing WRITE_COMMAND."                            \
1603
          "  shifting in:  0x000000000171893d95c0000000100008"   \
1604
          "  shifted out:  0x164841bc600000000000000000000000"   \
1605
          "  status:       0x0"                                  \
1606
          "  time taken:"                                        \
1607
          "Execution step completed OK."                         \
1608
          "Processing GO_COMMAND_WRITE."                         \
1609
          "  shifting in:  0x00000000000c1a78bb0bafea7eefb6af60" \
1610
          "  shifted out:  0x015fea3b0e200000000000000000000000" \
1611
          "  status:       0x8"                                  \
1612
          "  time taken:"                                        \
1613
          "New byte at 0x00100000 = 0xde"                        \
1614
          "New byte at 0x00100001 = 0xad"                        \
1615
          "New byte at 0x00100002 = 0xbe"                        \
1616
          "New byte at 0x00100003 = 0xef"                        \
1617
          "New byte at 0x00100004 = 0xca"                        \
1618
          "New byte at 0x00100005 = 0xfe"                        \
1619
          "New byte at 0x00100006 = 0xba"                        \
1620
          "Execution step completed OK."                         \
1621
          "Test completed successfully."]                        \
1622
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1623
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "8"        \
1624
         "GO_COMMAND_WRITE" "deadbeefcafeba"
1625
 
1626
# GO_COMMAND_WRITE for WishBone overrun for byte access
1627
run_libsim "JTAG GO_COMMAND (write) WB byte access overrun"          \
1628
    [list "Initalization succeeded."                                 \
1629
          "Execution step completed OK."                             \
1630
          "Resetting JTAG."                                          \
1631
          "Execution step completed OK."                             \
1632
          "Shifting instruction."                                    \
1633
          "  shifting in:  0x01"                                     \
1634
          "  shifted out:  0x01"                                     \
1635
          "  time taken:"                                            \
1636
          "Execution step completed OK."                             \
1637
          "Selecting module."                                        \
1638
          "  shifting in:  0x0000000000174841bc61"                   \
1639
          "  shifted out:  0x0164841bc60000000000"                   \
1640
          "  status:       0x0"                                      \
1641
          "  time taken:"                                            \
1642
          "Execution step completed OK."                             \
1643
          "Processing WRITE_COMMAND."                                \
1644
          "  shifting in:  0x000000000171893d95c0000000100008"       \
1645
          "  shifted out:  0x164841bc600000000000000000000000"       \
1646
          "  status:       0x0"                                      \
1647
          "  time taken:"                                            \
1648
          "Execution step completed OK."                             \
1649
          "Processing GO_COMMAND_WRITE."                             \
1650
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
1651
          "  shifted out:  0x015fea3b0e2000000000000000000000000000" \
1652
          "  status:       0x8"                                      \
1653
          "  time taken:"                                            \
1654
          "New byte at 0x00100000 = 0xde"                            \
1655
          "New byte at 0x00100001 = 0xad"                            \
1656
          "New byte at 0x00100002 = 0xbe"                            \
1657
          "New byte at 0x00100003 = 0xef"                            \
1658
          "New byte at 0x00100004 = 0xca"                            \
1659
          "New byte at 0x00100005 = 0xfe"                            \
1660
          "New byte at 0x00100006 = 0xba"                            \
1661
          "New byte at 0x00100007 = 0xbe"                            \
1662
          "Execution step completed OK."                             \
1663
          "Test completed successfully."]                            \
1664
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1665
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "100000" "8"        \
1666
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
1667
 
1668
# GO_COMMAND_WRITE for WishBone underrun for half word access
1669
run_libsim "JTAG GO_COMMAND (write) WB half word access underrun" \
1670
    [list "Initalization succeeded."                              \
1671
          "Execution step completed OK."                          \
1672
          "Resetting JTAG."                                       \
1673
          "Execution step completed OK."                          \
1674
          "Shifting instruction."                                 \
1675
          "  shifting in:  0x01"                                  \
1676
          "  shifted out:  0x01"                                  \
1677
          "  time taken:"                                         \
1678
          "Execution step completed OK."                          \
1679
          "Selecting module."                                     \
1680
          "  shifting in:  0x0000000000174841bc61"                \
1681
          "  shifted out:  0x0164841bc60000000000"                \
1682
          "  status:       0x0"                                   \
1683
          "  time taken:"                                         \
1684
          "Execution step completed OK."                          \
1685
          "Processing WRITE_COMMAND."                             \
1686
          "  shifting in:  0x000000000061a4e871c0000000100108"    \
1687
          "  shifted out:  0x164841bc600000000000000000000000"    \
1688
          "  status:       0x0"                                   \
1689
          "  time taken:"                                         \
1690
          "Execution step completed OK."                          \
1691
          "Processing GO_COMMAND_WRITE."                          \
1692
          "  shifting in:  0x00000000000c1a78bb0bafea7eefb6af60"  \
1693
          "  shifted out:  0x015fea3b0e200000000000000000000000"  \
1694
          "  status:       0x8"                                   \
1695
          "  time taken:"                                         \
1696
          "New byte at 0x00100000 = 0xde"                         \
1697
          "New byte at 0x00100001 = 0xad"                         \
1698
          "New byte at 0x00100002 = 0xbe"                         \
1699
          "New byte at 0x00100003 = 0xef"                         \
1700
          "New byte at 0x00100004 = 0xca"                         \
1701
          "New byte at 0x00100005 = 0xfe"                         \
1702
          "New byte at 0x00100006 = 0xba"                         \
1703
          "Execution step completed OK."                          \
1704
          "Test completed successfully."]                         \
1705
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1706
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "8"        \
1707
         "GO_COMMAND_WRITE" "deadbeefcafeba"
1708
 
1709
# GO_COMMAND_WRITE for WishBone overrun for half word access
1710
run_libsim "JTAG GO_COMMAND (write) WB half word access overrun"     \
1711
    [list "Initalization succeeded."                                 \
1712
          "Execution step completed OK."                             \
1713
          "Resetting JTAG."                                          \
1714
          "Execution step completed OK."                             \
1715
          "Shifting instruction."                                    \
1716
          "  shifting in:  0x01"                                     \
1717
          "  shifted out:  0x01"                                     \
1718
          "  time taken:"                                            \
1719
          "Execution step completed OK."                             \
1720
          "Selecting module."                                        \
1721
          "  shifting in:  0x0000000000174841bc61"                   \
1722
          "  shifted out:  0x0164841bc60000000000"                   \
1723
          "  status:       0x0"                                      \
1724
          "  time taken:"                                            \
1725
          "Execution step completed OK."                             \
1726
          "Processing WRITE_COMMAND."                                \
1727
          "  shifting in:  0x000000000061a4e871c0000000100108"       \
1728
          "  shifted out:  0x164841bc600000000000000000000000"       \
1729
          "  status:       0x0"                                      \
1730
          "  time taken:"                                            \
1731
          "Execution step completed OK."                             \
1732
          "Processing GO_COMMAND_WRITE."                             \
1733
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
1734
          "  shifted out:  0x015fea3b0e2000000000000000000000000000" \
1735
          "  status:       0x8"                                      \
1736
          "  time taken:"                                            \
1737
          "New byte at 0x00100000 = 0xde"                            \
1738
          "New byte at 0x00100001 = 0xad"                            \
1739
          "New byte at 0x00100002 = 0xbe"                            \
1740
          "New byte at 0x00100003 = 0xef"                            \
1741
          "New byte at 0x00100004 = 0xca"                            \
1742
          "New byte at 0x00100005 = 0xfe"                            \
1743
          "New byte at 0x00100006 = 0xba"                            \
1744
          "New byte at 0x00100007 = 0xbe"                            \
1745
          "Execution step completed OK."                             \
1746
          "Test completed successfully."]                            \
1747
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1748
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "100000" "8"        \
1749
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
1750
 
1751
# GO_COMMAND_WRITE for WishBone underrun for word access
1752
run_libsim "JTAG GO_COMMAND (write) WB word access underrun"     \
1753
    [list "Initalization succeeded."                             \
1754
          "Execution step completed OK."                         \
1755
          "Resetting JTAG."                                      \
1756
          "Execution step completed OK."                         \
1757
          "Shifting instruction."                                \
1758
          "  shifting in:  0x01"                                 \
1759
          "  shifted out:  0x01"                                 \
1760
          "  time taken:"                                        \
1761
          "Execution step completed OK."                         \
1762
          "Selecting module."                                    \
1763
          "  shifting in:  0x0000000000174841bc61"               \
1764
          "  shifted out:  0x0164841bc60000000000"               \
1765
          "  status:       0x0"                                  \
1766
          "  time taken:"                                        \
1767
          "Execution step completed OK."                         \
1768
          "Processing WRITE_COMMAND."                            \
1769
          "  shifting in:  0x0000000001f99fd767c0000000100088"   \
1770
          "  shifted out:  0x164841bc600000000000000000000000"   \
1771
          "  status:       0x0"                                  \
1772
          "  time taken:"                                        \
1773
          "Execution step completed OK."                         \
1774
          "Processing GO_COMMAND_WRITE."                         \
1775
          "  shifting in:  0x00000000000c1a78bb0bafea7eefb6af60" \
1776
          "  shifted out:  0x015fea3b0e200000000000000000000000" \
1777
          "  status:       0x8"                                  \
1778
          "  time taken:"                                        \
1779
          "New byte at 0x00100000 = 0xde"                        \
1780
          "New byte at 0x00100001 = 0xad"                        \
1781
          "New byte at 0x00100002 = 0xbe"                        \
1782
          "New byte at 0x00100003 = 0xef"                        \
1783
          "New byte at 0x00100004 = 0xca"                        \
1784
          "New byte at 0x00100005 = 0xfe"                        \
1785
          "New byte at 0x00100006 = 0xba"                        \
1786
          "Execution step completed OK."                         \
1787
          "Test completed successfully."]                        \
1788
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1789
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "8"        \
1790
         "GO_COMMAND_WRITE" "deadbeefcafeba"
1791
 
1792
# GO_COMMAND_WRITE for WishBone overrun for word access
1793
run_libsim "JTAG GO_COMMAND (write) WB word access overrun"          \
1794
    [list "Initalization succeeded."                                 \
1795
          "Execution step completed OK."                             \
1796
          "Resetting JTAG."                                          \
1797
          "Execution step completed OK."                             \
1798
          "Shifting instruction."                                    \
1799
          "  shifting in:  0x01"                                     \
1800
          "  shifted out:  0x01"                                     \
1801
          "  time taken:"                                            \
1802
          "Execution step completed OK."                             \
1803
          "Selecting module."                                        \
1804
          "  shifting in:  0x0000000000174841bc61"                   \
1805
          "  shifted out:  0x0164841bc60000000000"                   \
1806
          "  status:       0x0"                                      \
1807
          "  time taken:"                                            \
1808
          "Execution step completed OK."                             \
1809
          "Processing WRITE_COMMAND."                                \
1810
          "  shifting in:  0x0000000001f99fd767c0000000100088"       \
1811
          "  shifted out:  0x164841bc600000000000000000000000"       \
1812
          "  status:       0x0"                                      \
1813
          "  time taken:"                                            \
1814
          "Execution step completed OK."                             \
1815
          "Processing GO_COMMAND_WRITE."                             \
1816
          "  shifting in:  0x000000000005b486612bafabafea7eefb6af60" \
1817
          "  shifted out:  0x015fea3b0e2000000000000000000000000000" \
1818
          "  status:       0x8"                                      \
1819
          "  time taken:"                                            \
1820
          "New byte at 0x00100000 = 0xde"                            \
1821
          "New byte at 0x00100001 = 0xad"                            \
1822
          "New byte at 0x00100002 = 0xbe"                            \
1823
          "New byte at 0x00100003 = 0xef"                            \
1824
          "New byte at 0x00100004 = 0xca"                            \
1825
          "New byte at 0x00100005 = 0xfe"                            \
1826
          "New byte at 0x00100006 = 0xba"                            \
1827
          "New byte at 0x00100007 = 0xbe"                            \
1828
          "Execution step completed OK."                             \
1829
          "Test completed successfully."]                            \
1830
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1831
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "100000" "8"        \
1832
         "GO_COMMAND_WRITE" "deadbeefcafebabeba"
1833
 
1834
# CPU0 underrun and overrun tests should remember that this is a 32-bit access
1835
# with a big-endian organization.
1836
 
1837
# GO_COMMAND_WRITE for CPU0 underrun for word access
1838
run_libsim "JTAG GO_COMMAND (write) CPU0 word access underrun" \
1839
    [list "Initalization succeeded."                           \
1840
          "Execution step completed OK."                       \
1841
          "Resetting JTAG."                                    \
1842
          "Execution step completed OK."                       \
1843
          "Shifting instruction."                              \
1844
          "  shifting in:  0x01"                               \
1845
          "  shifted out:  0x01"                               \
1846
          "  time taken:"                                      \
1847
          "Execution step completed OK."                       \
1848
          "Selecting module."                                  \
1849
          "  shifting in:  0x00000000000aff51d871"             \
1850
          "  shifted out:  0x0164841bc60000000000"             \
1851
          "  status:       0x0"                                \
1852
          "  time taken:"                                      \
1853
          "Execution step completed OK."                       \
1854
          "Processing WRITE_COMMAND."                          \
1855
          "  shifting in:  0x0000000001933eb7e580010028000088" \
1856
          "  shifted out:  0x164841bc600000000000000000000000" \
1857
          "  status:       0x0"                                \
1858
          "  time taken:"                                      \
1859
          "Execution step completed OK."                       \
1860
          "Processing GO_COMMAND_WRITE."                       \
1861
          "  shifting in:  0x00000000001599d9120fb6af60"       \
1862
          "  shifted out:  0x015fea3b0e2000000000000000"       \
1863
          "  status:       0x8"                                \
1864
          "  time taken:"                                      \
1865
          "New MACLO 0x00beadde"                               \
1866
          "Execution step completed OK."                       \
1867
          "Test completed successfully."]                      \
1868
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1869
         "8" "SELECT_MODULE" "1" "WRITE_COMMAND" "2" "2801" "4"          \
1870
         "GO_COMMAND_WRITE" "deadbe"
1871
 
1872
# GO_COMMAND_WRITE for CPU0 overrun for word access
1873
run_libsim "JTAG GO_COMMAND (write) CPU0 word access overrun"  \
1874
    [list "Initalization succeeded."                           \
1875
          "Execution step completed OK."                       \
1876
          "Resetting JTAG."                                    \
1877
          "Execution step completed OK."                       \
1878
          "Shifting instruction."                              \
1879
          "  shifting in:  0x01"                               \
1880
          "  shifted out:  0x01"                               \
1881
          "  time taken:"                                      \
1882
          "Execution step completed OK."                       \
1883
          "Selecting module."                                  \
1884
          "  shifting in:  0x00000000000aff51d871"             \
1885
          "  shifted out:  0x0164841bc60000000000"             \
1886
          "  status:       0x0"                                \
1887
          "  time taken:"                                      \
1888
          "Execution step completed OK."                       \
1889
          "Processing WRITE_COMMAND."                          \
1890
          "  shifting in:  0x0000000001933eb7e580010028000088" \
1891
          "  shifted out:  0x164841bc600000000000000000000000" \
1892
          "  status:       0x0"                                \
1893
          "  time taken:"                                      \
1894
          "Execution step completed OK."                       \
1895
          "Processing GO_COMMAND_WRITE."                       \
1896
          "  shifting in:  0x000000000009ac236c4a7eefb6af60"   \
1897
          "  shifted out:  0x015fea3b0e20000000000000000000"   \
1898
          "  status:       0x8"                                \
1899
          "  time taken:"                                      \
1900
          "New MACLO 0xefbeadde"                               \
1901
          "Execution step completed OK."                       \
1902
          "Test completed successfully."]                      \
1903
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1904
         "8" "SELECT_MODULE" "1" "WRITE_COMMAND" "2" "2801" "4"          \
1905
         "GO_COMMAND_WRITE" "deadbeefca"
1906
 
1907
# Test access to invalid areas. We can only do this for Wishbone, since all
1908
# SPRs are validly accessible (non-writeable ones just return undefined
1909
# results).
1910
 
1911
# Test each access type with one unit and test blocks spanning start and end
1912
# of writeable blocks.
1913
 
1914
# GO_COMMAND_WRITE for 1 byte write to invalid memory.
1915
run_libsim "JTAG GO_COMMAND (write) WB 1 byte invalid write"   \
1916
    [list "Initalization succeeded."                           \
1917
          "Execution step completed OK."                       \
1918
          "Resetting JTAG."                                    \
1919
          "Execution step completed OK."                       \
1920
          "Shifting instruction."                              \
1921
          "  shifting in:  0x01"                               \
1922
          "  shifted out:  0x01"                               \
1923
          "  time taken:"                                      \
1924
          "Execution step completed OK."                       \
1925
          "Selecting module."                                  \
1926
          "  shifting in:  0x0000000000174841bc61"             \
1927
          "  shifted out:  0x0164841bc60000000000"             \
1928
          "  status:       0x0"                                \
1929
          "  time taken:"                                      \
1930
          "Execution step completed OK."                       \
1931
          "Processing WRITE_COMMAND."                          \
1932
          "  shifting in:  0x0000000001ba7d236600000000080008" \
1933
          "  shifted out:  0x164841bc600000000000000000000000" \
1934
          "  status:       0x0"                                \
1935
          "  time taken:"                                      \
1936
          "Execution step completed OK."                       \
1937
          "Processing GO_COMMAND_WRITE."                       \
1938
          "  shifting in:  0x000000000006d6fa6e6f60"           \
1939
          "  shifted out:  0x0112585a56400000000000"           \
1940
          "  status:       0x4"                                \
1941
          "  time taken:"                                      \
1942
          "Execution step completed OK."                       \
1943
          "Test completed successfully."]                      \
1944
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1945
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "200000" "1"        \
1946
         "GO_COMMAND_WRITE" "de"
1947
 
1948
# GO_COMMAND_WRITE for 2 byte write ending in invalid memory.
1949
run_libsim "JTAG GO_COMMAND (write) WB 2 byte ending invalid write" \
1950
    [list "Initalization succeeded."                                \
1951
          "Execution step completed OK."                            \
1952
          "Resetting JTAG."                                         \
1953
          "Execution step completed OK."                            \
1954
          "Shifting instruction."                                   \
1955
          "  shifting in:  0x01"                                    \
1956
          "  shifted out:  0x01"                                    \
1957
          "  time taken:"                                           \
1958
          "Execution step completed OK."                            \
1959
          "Selecting module."                                       \
1960
          "  shifting in:  0x0000000000174841bc61"                  \
1961
          "  shifted out:  0x0164841bc60000000000"                  \
1962
          "  status:       0x0"                                     \
1963
          "  time taken:"                                           \
1964
          "Execution step completed OK."                            \
1965
          "Processing WRITE_COMMAND."                               \
1966
          "  shifting in:  0x0000000001bbbf3ba70001fffff00008"      \
1967
          "  shifted out:  0x164841bc600000000000000000000000"      \
1968
          "  status:       0x0"                                     \
1969
          "  time taken:"                                           \
1970
          "Execution step completed OK."                            \
1971
          "Processing GO_COMMAND_WRITE."                            \
1972
          "  shifting in:  0x00000000000e463a0ad6af60"              \
1973
          "  shifted out:  0x0112585a5640000000000000"              \
1974
          "  status:       0x4"                                     \
1975
          "  time taken:"                                           \
1976
          "New byte at 0x001fffff = 0xde"                           \
1977
          "Execution step completed OK."                            \
1978
          "Test completed successfully."]                           \
1979
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
1980
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "1fffff" "2"        \
1981
         "GO_COMMAND_WRITE" "dead"
1982
 
1983
# GO_COMMAND_WRITE for 2 byte write starting in invalid memory.
1984
run_libsim "JTAG GO_COMMAND (write) WB 2 byte starting invalid write" \
1985
    [list "Initalization succeeded."                                  \
1986
          "Execution step completed OK."                              \
1987
          "Resetting JTAG."                                           \
1988
          "Execution step completed OK."                              \
1989
          "Shifting instruction."                                     \
1990
          "  shifting in:  0x01"                                      \
1991
          "  shifted out:  0x01"                                      \
1992
          "  time taken:"                                             \
1993
          "Execution step completed OK."                              \
1994
          "Selecting module."                                         \
1995
          "  shifting in:  0x0000000000174841bc61"                    \
1996
          "  shifted out:  0x0164841bc60000000000"                    \
1997
          "  status:       0x0"                                       \
1998
          "  time taken:"                                             \
1999
          "Execution step completed OK."                              \
2000
          "Processing WRITE_COMMAND."                                 \
2001
          "  shifting in:  0x0000000000fd76999f0001fffff7fe08"        \
2002
          "  shifted out:  0x164841bc600000000000000000000000"        \
2003
          "  status:       0x0"                                       \
2004
          "  time taken:"                                             \
2005
          "Execution step completed OK."                              \
2006
          "Processing GO_COMMAND_WRITE."                              \
2007
          "  shifting in:  0x00000000000e463a0ad6af60"                \
2008
          "  shifted out:  0x0112585a5640000000000000"                \
2009
          "  status:       0x4"                                       \
2010
          "  time taken:"                                             \
2011
          "New byte at 0xffe00000 = 0xad"                             \
2012
          "Execution step completed OK."                              \
2013
          "Test completed successfully."]                             \
2014
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2015
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "0" "ffdfffff" "2"      \
2016
         "GO_COMMAND_WRITE" "dead"
2017
 
2018
# GO_COMMAND_WRITE for 1 half word write to invalid memory.
2019
run_libsim "JTAG GO_COMMAND (write) WB 1 half word invalid write" \
2020
    [list "Initalization succeeded."                              \
2021
          "Execution step completed OK."                          \
2022
          "Resetting JTAG."                                       \
2023
          "Execution step completed OK."                          \
2024
          "Shifting instruction."                                 \
2025
          "  shifting in:  0x01"                                  \
2026
          "  shifted out:  0x01"                                  \
2027
          "  time taken:"                                         \
2028
          "Execution step completed OK."                          \
2029
          "Selecting module."                                     \
2030
          "  shifting in:  0x0000000000174841bc61"                \
2031
          "  shifted out:  0x0164841bc60000000000"                \
2032
          "  status:       0x0"                                   \
2033
          "  time taken:"                                         \
2034
          "Execution step completed OK."                          \
2035
          "Processing WRITE_COMMAND."                             \
2036
          "  shifting in:  0x00000000017121f0c300000000080108"    \
2037
          "  shifted out:  0x164841bc600000000000000000000000"    \
2038
          "  status:       0x0"                                   \
2039
          "  time taken:"                                         \
2040
          "Execution step completed OK."                          \
2041
          "Processing GO_COMMAND_WRITE."                          \
2042
          "  shifting in:  0x00000000000e463a0ad6af60"            \
2043
          "  shifted out:  0x0112585a5640000000000000"            \
2044
          "  status:       0x4"                                   \
2045
          "  time taken:"                                         \
2046
          "Execution step completed OK."                          \
2047
          "Test completed successfully."]                         \
2048
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2049
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "200000" "2"        \
2050
         "GO_COMMAND_WRITE" "dead"
2051
 
2052
# GO_COMMAND_WRITE for 2 half word write ending in invalid memory.
2053
run_libsim "JTAG GO_COMMAND (write) WB 2 half word ending invalid write" \
2054
    [list "Initalization succeeded."                                     \
2055
          "Execution step completed OK."                                 \
2056
          "Resetting JTAG."                                              \
2057
          "Execution step completed OK."                                 \
2058
          "Shifting instruction."                                        \
2059
          "  shifting in:  0x01"                                         \
2060
          "  shifted out:  0x01"                                         \
2061
          "  time taken:"                                                \
2062
          "Execution step completed OK."                                 \
2063
          "Selecting module."                                            \
2064
          "  shifting in:  0x0000000000174841bc61"                       \
2065
          "  shifted out:  0x0164841bc60000000000"                       \
2066
          "  status:       0x0"                                          \
2067
          "  time taken:"                                                \
2068
          "Execution step completed OK."                                 \
2069
          "Processing WRITE_COMMAND."                                    \
2070
          "  shifting in:  0x000000000184405a638000fffff00108"           \
2071
          "  shifted out:  0x164841bc600000000000000000000000"           \
2072
          "  status:       0x0"                                          \
2073
          "  time taken:"                                                \
2074
          "Execution step completed OK."                                 \
2075
          "Processing GO_COMMAND_WRITE."                                 \
2076
          "  shifting in:  0x00000000001a6f47467eefb6af60"               \
2077
          "  shifted out:  0x0112585a56400000000000000000"               \
2078
          "  status:       0x4"                                          \
2079
          "  time taken:"                                                \
2080
          "New byte at 0x001ffffe = 0xde"                                \
2081
          "New byte at 0x001fffff = 0xad"                                \
2082
          "Execution step completed OK."                                 \
2083
          "Test completed successfully."]                                \
2084
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2085
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "1ffffe" "4"        \
2086
         "GO_COMMAND_WRITE" "deadbeef"
2087
 
2088
# GO_COMMAND_WRITE for 2 half word write starting in invalid memory.
2089
run_libsim "JTAG GO_COMMAND (write) WB 2 half word starting invalid write" \
2090
    [list "Initalization succeeded."                                       \
2091
          "Execution step completed OK."                                   \
2092
          "Resetting JTAG."                                                \
2093
          "Execution step completed OK."                                   \
2094
          "Shifting instruction."                                          \
2095
          "  shifting in:  0x01"                                           \
2096
          "  shifted out:  0x01"                                           \
2097
          "  time taken:"                                                  \
2098
          "Execution step completed OK."                                   \
2099
          "Selecting module."                                              \
2100
          "  shifting in:  0x0000000000174841bc61"                         \
2101
          "  shifted out:  0x0164841bc60000000000"                         \
2102
          "  status:       0x0"                                            \
2103
          "  time taken:"                                                  \
2104
          "Execution step completed OK."                                   \
2105
          "Processing WRITE_COMMAND."                                      \
2106
          "  shifting in:  0x0000000000c289f85b8000fffff7ff08"             \
2107
          "  shifted out:  0x164841bc600000000000000000000000"             \
2108
          "  status:       0x0"                                            \
2109
          "  time taken:"                                                  \
2110
          "Execution step completed OK."                                   \
2111
          "Processing GO_COMMAND_WRITE."                                   \
2112
          "  shifting in:  0x00000000001a6f47467eefb6af60"                 \
2113
          "  shifted out:  0x0112585a56400000000000000000"                 \
2114
          "  status:       0x4"                                            \
2115
          "  time taken:"                                                  \
2116
          "New byte at 0xffe00000 = 0xbe"                                  \
2117
          "New byte at 0xffe00001 = 0xef"                                  \
2118
          "Execution step completed OK."                                   \
2119
          "Test completed successfully."]                                  \
2120
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION"   \
2121
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "1" "ffdffffe" "4"        \
2122
         "GO_COMMAND_WRITE" "deadbeef"
2123
 
2124
# GO_COMMAND_WRITE for 1 word write to invalid memory.
2125
run_libsim "JTAG GO_COMMAND (write) WB 1 word invalid write"   \
2126
    [list "Initalization succeeded."                           \
2127
          "Execution step completed OK."                       \
2128
          "Resetting JTAG."                                    \
2129
          "Execution step completed OK."                       \
2130
          "Shifting instruction."                              \
2131
          "  shifting in:  0x01"                               \
2132
          "  shifted out:  0x01"                               \
2133
          "  time taken:"                                      \
2134
          "Execution step completed OK."                       \
2135
          "Selecting module."                                  \
2136
          "  shifting in:  0x0000000000174841bc61"             \
2137
          "  shifted out:  0x0164841bc60000000000"             \
2138
          "  status:       0x0"                                \
2139
          "  time taken:"                                      \
2140
          "Execution step completed OK."                       \
2141
          "Processing WRITE_COMMAND."                          \
2142
          "  shifting in:  0x000000000004a24cf580000000080088" \
2143
          "  shifted out:  0x164841bc600000000000000000000000" \
2144
          "  status:       0x0"                                \
2145
          "  time taken:"                                      \
2146
          "Execution step completed OK."                       \
2147
          "Processing GO_COMMAND_WRITE."                       \
2148
          "  shifting in:  0x00000000001a6f47467eefb6af60"     \
2149
          "  shifted out:  0x0112585a56400000000000000000"     \
2150
          "  status:       0x4"                                \
2151
          "  time taken:"                                      \
2152
          "Execution step completed OK."                       \
2153
          "Test completed successfully."]                      \
2154
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2155
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "200000" "4"        \
2156
         "GO_COMMAND_WRITE" "deadbeef"
2157
 
2158
# GO_COMMAND_WRITE for 2 word write ending in invalid memory.
2159
run_libsim "JTAG GO_COMMAND (write) WB 2 word ending invalid write"  \
2160
    [list "Initalization succeeded."                                 \
2161
          "Execution step completed OK."                             \
2162
          "Resetting JTAG."                                          \
2163
          "Execution step completed OK."                             \
2164
          "Shifting instruction."                                    \
2165
          "  shifting in:  0x01"                                     \
2166
          "  shifted out:  0x01"                                     \
2167
          "  time taken:"                                            \
2168
          "Execution step completed OK."                             \
2169
          "Selecting module."                                        \
2170
          "  shifting in:  0x0000000000174841bc61"                   \
2171
          "  shifted out:  0x0164841bc60000000000"                   \
2172
          "  status:       0x0"                                      \
2173
          "  time taken:"                                            \
2174
          "Execution step completed OK."                             \
2175
          "Processing WRITE_COMMAND."                                \
2176
          "  shifting in:  0x00000000008b923f65c0007ffff00088"       \
2177
          "  shifted out:  0x164841bc600000000000000000000000"       \
2178
          "  status:       0x0"                                      \
2179
          "  time taken:"                                            \
2180
          "Execution step completed OK."                             \
2181
          "Processing GO_COMMAND_WRITE."                             \
2182
          "  shifting in:  0x000000000014db90944fabafea7eefb6af60"   \
2183
          "  shifted out:  0x0112585a5640000000000000000000000000"   \
2184
          "  status:       0x4"                                      \
2185
          "  time taken:"                                            \
2186
          "New byte at 0x001ffffc = 0xde"                            \
2187
          "New byte at 0x001ffffd = 0xad"                            \
2188
          "New byte at 0x001ffffe = 0xbe"                            \
2189
          "New byte at 0x001fffff = 0xef"                            \
2190
          "Execution step completed OK."                             \
2191
          "Test completed successfully."]                            \
2192
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2193
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "1ffffc" "8"        \
2194
         "GO_COMMAND_WRITE" "deadbeefcafebabe"
2195
 
2196
# GO_COMMAND_WRITE for 2 word write starting in invalid memory.
2197
run_libsim "JTAG GO_COMMAND (write) WB 2 word starting invalid write" \
2198
    [list "Initalization succeeded."                                  \
2199
          "Execution step completed OK."                              \
2200
          "Resetting JTAG."                                           \
2201
          "Execution step completed OK."                              \
2202
          "Shifting instruction."                                     \
2203
          "  shifting in:  0x01"                                      \
2204
          "  shifted out:  0x01"                                      \
2205
          "  time taken:"                                             \
2206
          "Execution step completed OK."                              \
2207
          "Selecting module."                                         \
2208
          "  shifting in:  0x0000000000174841bc61"                    \
2209
          "  shifted out:  0x0164841bc60000000000"                    \
2210
          "  status:       0x0"                                       \
2211
          "  time taken:"                                             \
2212
          "Execution step completed OK."                              \
2213
          "Processing WRITE_COMMAND."                                 \
2214
          "  shifting in:  0x0000000001cd5b9d5dc0007ffff7fe88"        \
2215
          "  shifted out:  0x164841bc600000000000000000000000"        \
2216
          "  status:       0x0"                                       \
2217
          "  time taken:"                                             \
2218
          "Execution step completed OK."                              \
2219
          "Processing GO_COMMAND_WRITE."                              \
2220
          "  shifting in:  0x000000000014db90944fabafea7eefb6af60"    \
2221
          "  shifted out:  0x0112585a5640000000000000000000000000"    \
2222
          "  status:       0x4"                                       \
2223
          "  time taken:"                                             \
2224
          "New byte at 0xffe00000 = 0xca"                             \
2225
          "New byte at 0xffe00001 = 0xfe"                             \
2226
          "New byte at 0xffe00002 = 0xba"                             \
2227
          "New byte at 0xffe00003 = 0xbe"                             \
2228
          "Execution step completed OK."                              \
2229
          "Test completed successfully."]                             \
2230
    "lib-jtag/lib-jtag-full" "" "loop/loop-report" "RESET" "INSTRUCTION" \
2231
         "8" "SELECT_MODULE" "0" "WRITE_COMMAND" "2" "ffdffffc" "8"      \
2232
         "GO_COMMAND_WRITE" "deadbeefcafebabe"

powered by: WebSVN 2.1.0

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