Skip to content

o1553_host: Verification Plan

1. Overview

The host interface is verified through its ports. The far ends are models written from the specifications, independently of the RTL:

  • The host: the UVVM AXI4-Lite VVC (bitvis_vip_axilite) as the master of the host port, with the expected responses (OKAY, SLVERR) checked per access. Reads that depend on a write wait for the write to complete (the VVC runs the channels independently).
  • The protocol engine: a requester model on the memory port that issues reads and writes with the shapes of o1553_rt (lookup pairs in consecutive cycles, single data words, publications, 8-write records, continuous bursts), holds a request until it is accepted, as the RT does, fails on a request that waits more than one cycle, and checks every response: MemLatency cycles after its acceptance, in request order, with the expected data and double error flag. A second requester model on the memory port of the BC issues the shapes of o1553_bc (latch walk with up to 15 reads in flight, slot fetches, data words, results, records), allows waits, can withdraw a request that is not yet accepted, and checks its responses in the same way; a response on a port without a read of that port in flight is an error. A third requester model on the memory port of the BM issues the shapes of o1553_bm (up to 4 reads of the filter table in consecutive cycles, records of up to 44 writes in consecutive cycles), allows waits, can withdraw a request that is not yet accepted, and checks its responses in the same way.
  • A reference model of the buffer memory in the test sequence: every write of the host and of the requester model is applied to it, every read is compared with it. Test data depend on every address bit; write targets are filled with a different pattern first.
  • The state inputs of the RT, the BC, the BM and the codec, the events of the BC and the BM and the indications are driven by the test sequence; the configuration and command outputs, Ecc_DedEvent, Mem_InitDone, Log_WrIdx, Time_Tag and Irq are logged with their clock cycle.
  • Errors are injected through ErrInj_BitFlip and ErrInj_Valid, single and double, in data bits and in parity bits of the codeword, with the scrubber held (CONTROL.SCRUB_EN = '0') where a test needs a stable error.

Expected register values come from the register description and section 3 of the architecture, the default tables from section 6 of the specification, MemLatency from the formula of HI-MEM-03.

2. Test configuration

Testbench Harness DUT and environment
o1553_host_tb o1553_host_th o1553_host; AXI4-Lite VVC; requester models of the memory ports of the RT, the BC and the BM; drivers of the state inputs, the events of the BC and the BM, the indications and the record events; logs of the outputs
VUnit configuration ClkFreq_g, RamRdLatency_g, EccPipeline_g, ScrubPeriod_g Purpose
c100 100 MHz, 1, 1, 0.0 Nominal; all tests
c16 16 MHz, 1, 1, 0.0 Lowest clock
c400 400 MHz, 1, 1, 0.0 Highest clock
l2 100 MHz, 1, 0, 0.0 Smallest MemLatency (2)
l7 100 MHz, 4, 2, 0.0 Largest MemLatency (7)
p1 100 MHz, 1, 1, 1.0e-3 Scrub pacer
c100_bc 100 MHz, 1, 1, 0.0, IncludeBc_g and AllowOpenProfile_g true The two fields of CORE_STATUS
c100_bm 100 MHz, 1, 1, 0.0, IncludeBm_g true The field BM_INCLUDED of CORE_STATUS

IncludeBc_g and AllowOpenProfile_g are false in every configuration except c100_bc, IncludeBm_g in every configuration except c100_bm. The tests marked "all" run in every configuration except c100_bc and c100_bm, the others in c100; TC-HI-15 also runs in c100_bc, TC-HI-17 also in c100_bm. Every test runs under a VUnit watchdog, and every wait has a time-out.

3. Test cases

Test ID Description Requirements
test_reset_init (TC-HI-01) After the reset: every register at its reset value (RESP_TIME = 6.0 us in cycles); Mem_InitDone and INIT_DONE after the 8192 writes; every memory word read through the window and through the requester model: the default tables of the specification (section 6), 0 elsewhere; host reads and writes during the initialisation answered (all) HI-MEM-04, HI-RF-03, HI-FT-01, HI-IF-08
test_registers (TC-HI-02) Every RW field with walking ones and zeros and with byte enables; RO fields not changed by writes; W1 fields read 0 and give exactly one pulse; addresses without a register read 0 and ignore writes, response OKAY HI-RF-01, HI-HP-01, HI-IF-01
test_configuration (TC-HI-03) Every configuration field drives its output of the RT and of the codec, and only that output HI-RF-02, HI-IF-03
test_status (TC-HI-04) Every status field shows its input (random values on every state input of the RT and the codec) HI-RF-05, HI-IF-03
test_commands (TC-HI-05) ADDR_CHECK, ECC_CLR: one-cycle pulses; BIT W1C: the written ones of bits 7 to 0 on Cfg_BitClr for one cycle, HOST bits on Cfg_BitHost; HEALTH W1S: the written ones on Cfg_HealthSet for one cycle, reads Stat_Health HI-RF-04, HI-RF-02
test_memory_window (TC-HI-06) Every word pre-filled through the protocol port, then written and read through the window with address-dependent data; bits 31 to 16 read 0 and are ignored; writes with byte enables 1 or 0 cleared change nothing; back-to-back accesses, a read right after a write of the same word (all) HI-HP-02, HI-HP-03, HI-IF-01
test_arbitration (TC-HI-07) The requester model runs the RT access shapes (lookup pairs, data words, publications, records, a lookup followed by a record, the end of a message), then runs of 16 consecutive requests followed by 48 to 60 free cycles, then a request in every cycle, while the host writes one half of its region and reads the other back to back, with write-only rounds: every request of the protocol engine accepted in its cycle or in the next, never later, and requests that waited one cycle observed; responses MemLatency cycles after acceptance, in order, data of the reference model; every host read answered within 64 cycles; no memory corruption and no lost host write (protocol sweep of every word against the reference model) (all) HI-MEM-02, HI-MEM-03, HI-HP-04, HI-IF-02
test_errors (TC-HI-08) Single errors in data and parity bits: corrected data to the host and to the requester model, ECC_HOST and ECC_PROTOCOL SEC counts, ECC_SEC; double errors: host read answered with SLVERR within ReadTimeoutClks_g + 8 cycles after it was issued, the next host read answered normally, the requester model running its traffic during the stall with every request accepted within one cycle, Mem_Rsp_Ded to the requester model, DED counts, ECC_DED, one Ecc_DedEvent pulse each; the scrubber writes a single error back (a later read without SEC, ECC_SCRUB SEC count) and counts a double error without writing it; SCRUB_EN = '0' stops it; counters cleared by their read and by ECC_CLR; SCRUB_PASSES advances (all) HI-HP-02, HI-HP-05, HI-MEM-01, HI-ECC-01, HI-ECC-02, HI-IF-07
test_event_log (TC-HI-09) Log_WrIdx advances at every Log_Push and wraps at 256; LOG_RD_IDX read and write; LOG_OVF set by a push with 255 unread records and not by one with 254; RECORD only for a push with Log_Irq HI-EV-01, HI-EV-02, HI-EV-03, HI-IF-04
test_interrupts (TC-HI-10) Every flag set by its event, kept by a written '0', cleared by a written '1'; an event one cycle before the cycle of the clear is cleared, an event in that cycle or one cycle later sets the flag (RECORD with LOG_OVF, TIME_SYNC, FRAME_SYNC, RESET_REQ, SELF_TEST, BIT); BIT only for a rising bit 7 to 0 of the BIT word; Irq only with the enable, as a level; SYNC_DATA takes the data of a frame synchronisation HI-EV-03, HI-EV-04, HI-EV-05, HI-IF-06
test_time_base (TC-HI-11) One tick every ClkFreq_g / 1 MHz cycles; Time_Tag and TIME_TAG count microseconds from 0 after the reset (all) HI-TB-02, HI-IF-05
test_reset_input (TC-HI-12) Reset pulses of one cycle, shorter than a cycle and long: Rst asserted and released after the synchroniser; registers, flags, indices and time tag back at their reset values; the memory initialised again HI-TB-01, HI-IF-08, HI-FT-01
test_scrub_pacer (TC-HI-13) In p1: one scrub pass per millisecond (SCRUB_PASSES); a pass that the traffic of the requester model holds back beyond its period sets SCRUB_OVR HI-MEM-01, HI-EV-03
test_two_engines (TC-HI-14) Both requester models together with the host accesses of TC-HI-07: the BC model runs its shapes (the jobs of o1553_bc, latch walks of up to 15 reads in consecutive cycles) and requests in every cycle while the RT model runs the RT shapes, with reads of both interleaved cycle by cycle; every request of the RT accepted in its cycle or in the next, never later, whatever the BC requests; requests of the BC accepted when neither the host access nor the RT takes the memory; every response on the port of its read, in the order of that port, with the data of the reference model (address-dependent data, the two engines on different address ranges and on the same words); the BC model withdraws a request that waits and stops requesting with reads in flight: no access of the withdrawn request, its reads in flight answered on its port only, nothing on the port of the RT; double errors injected into reads of each engine reach only that engine and count in ECC_PROTOCOL (all) HI-MEM-02, HI-MEM-05, HI-MEM-06, HI-IF-09, HI-ECC-03
test_bc_registers (TC-HI-15) The BC registers at their reset values (BC_TIMEOUT = 18.0 us and BC_GAP = 4.0 us in cycles, the others of architecture section 3.3); every BC configuration field drives its input of the BC and only that input, RT_EN and LOG_ERRORS those of the RT and of the BC; BC_STATUS and BC_FRAME_COUNT show random values of the state inputs of the BC; every field of BC_COMMAND alone and together gives one-cycle pulses on Cmd_BcStart, Cmd_BcStop, Cmd_BcTick and each bit of Cmd_BcFsClr, and reads 0; each of the ten BC flags set by its Ev_Bc* input, cleared by a written '1', set by an event in the cycle of the clear, with its enable on Irq; CORE_STATUS.BC_INCLUDED and OPEN_PROFILE as the generics (in c100 and c100_bc) HI-RF-06, HI-RF-07, HI-RF-08, HI-EV-06, HI-CF-04, HI-IF-10
test_bm_port (TC-HI-16) The requester models of the RT and the BM together with the host accesses of TC-HI-07: the BM model runs its shapes (4 reads of the filter table in consecutive cycles, records of 44 and of 6 writes in consecutive cycles) and requests in every cycle while the RT model runs the RT shapes; every request of the RT accepted in its cycle or in the next, never later, whatever the BM requests; requests of the BM accepted in the first cycle in which neither the host access nor the RT takes the memory, and behind the requests of the BC model in a sequence of its own (the arbiter alone: in the core the BC and the BM are never active together); every response on the port of its read, in the order of that port, with the data of the reference model (address-dependent data, the engines on different address ranges and on the same words); the BM model withdraws a request that waits and stops requesting with reads in flight: no access of the withdrawn request, its reads in flight answered on its port only, nothing on the ports of the RT and the BC; double errors injected into reads of the BM reach only the BM, count in ECC_PROTOCOL and set ECC_DED and Ecc_DedEvent, single errors are corrected and count (all) HI-MEM-07, HI-IF-11, HI-ECC-04
test_bm_registers (TC-HI-17) Register map 0.3: ID.VERSION = 0x0003; the BM registers at their reset values (BM_TIMEOUT = 18.0 us in cycles, the others of architecture section 3.3); every BM configuration field drives its input of the BM and only that input (BM_FILTER_BASE bits 7 to 0 read 0 and drive '0'); BM_STATUS, BM_WRITE_INDEX and BM_LOST show random values of the state inputs of the BM; BM_COMMAND.LOST_CLR gives one one-cycle pulse on Cmd_BmLostClr and reads 0; each of the three BM flags set by its Ev_Bm* input, cleared by a written '1', set by an event in the cycle of the clear, with its enable on Irq; CORE_STATUS.BM_INCLUDED as the generic (in c100 and c100_bm) HI-RF-09, HI-RF-10, HI-RF-11, HI-EV-07, HI-CF-05, HI-IF-12
lint/synth_check.py Elaboration and synthesis of o1553_host at 16, 100 and 400 MHz and with MemLatency 2 and 7, without latches; a clock frequency the codec does not accept stops with its message HI-CF-01, HI-CF-02, HI-CF-03

4. Negative tests

Check Proven by
Double error of a host read answered with SLVERR by the read time-out TC-HI-08
Double error passed to the protocol engine TC-HI-08
Event log overflow TC-HI-09
Partial memory writes ignored TC-HI-06
Request of the protocol engine waiting more than one cycle TC-HI-07 (the requester model fails on a second wait cycle)
Host write lost or host read not answered while the protocol engine requests the memory in every cycle TC-HI-07 (host reads against the reference model, protocol sweep of every word)
Request of the RT waiting more than one cycle while the BC requests in every cycle TC-HI-14 (the RT requester model fails on a second wait cycle)
Response delivered to the wrong engine, or a response of a withdrawn request TC-HI-14 (each requester model fails on a response without a read of its own in flight)
Request of the BC waiting two cycles in which the RT makes no request TC-HI-14 (the BC requester model fails on the second such cycle)
Request of the RT waiting more than one cycle while the BM requests in every cycle TC-HI-16 (the RT requester model fails on a second wait cycle)
Response of a read of the BM on another port, or a response of a withdrawn request of the BM TC-HI-16 (each requester model fails on a response without a read of its own in flight)
Request of the BM waiting in a cycle in which neither the host access nor the RT takes the memory TC-HI-16 (the BM requester model fails on such a cycle)

5. Functional coverage

Coverpoint Requirements Bins Goal
ACCESS HI-HP-01 to HI-HP-03 register read, register write, window read, window write, partial window write, address without register 100 %
CONFLICT HI-MEM-02 protocol request while a host read of the memory window waits for its data, protocol request during the initialisation, host read during the initialisation, all three 100 %
ECC HI-ECC-01, HI-ECC-02 single and double error of each source: protocol, host, scrubber 100 %
FLAG HI-EV-03 every interrupt flag set, cleared, set in the cycle of the clear 100 %
LATENCY HI-MEM-03 MemLatency 2, 3, 7 100 %
WAIT HI-MEM-02 protocol request accepted at once, after one wait cycle 100 %
ENGINES HI-MEM-02, HI-MEM-05 RT and BC request in one cycle, BC behind the host access, BC behind the RT, responses of the RT and the BC in consecutive cycles while a host read of the memory window is in flight, BC request withdrawn, BC reads in flight after its last request; BM behind the host access, BM behind the RT, responses of the RT and the BM in consecutive cycles, BM request withdrawn, BM reads in flight after its last request 100 %

6. Generic coverage

Generic Declared range Simulated Synthesised
ClkFreq_g 16 MHz to 400 MHz, multiples of 2 MHz 16, 100, 400 MHz 16, 100, 400 MHz
RamRdLatency_g 1 to 4 1, 4 1, 4
EccPipeline_g 0 to 2 0, 1, 2 0, 2
ScrubPeriod_g 0.0 or at least 1 ms 0.0, 1 ms 0.0, 1 ms
IncludeBc_g, AllowOpenProfile_g false, true false, true false (core synthesis with true, TC-CORE-14)
IncludeBm_g false, true false, true false (core synthesis with true, TC-CORE-28)

7. Traceability

Every requirement of the specification is covered by the test cases of section 3; python tools/compliance.py lists the test cases per requirement and per clause in the compliance matrix.