Xi5tester



next up previous
Next: About this document Up: A Test Suite for Previous: Interactive Mode

Xi5tester

 

The xi5tester (master/kernel/kernel/machdep/arm/xi5tester.c) is a test suite for both Xi5 and Xi6 bits. Xi5tester is expected to be a continuing evolving program. As of the time of writing this document, xi5tester performs the following basic tests:

Most of these tests are self-explanatory. "Send Cells (MDH)" and "Send Cells (NEW)" are both working version of single cell test which expects the cell to be loop back through the loopback FIFO or the transmission FIFO. However, the Send Cells (NEW) has correct handling of the situation with lost cells and replicated cells (when doing serial multicast).

The xi5tester uses a greatly simplified version of FIQ code where the only action to take when a FIQ happens is to post an always IRQ. Thus when a FPC is booted with a xi5tester kernel, it is not able to perform normal communications on the ATM interfaces. If the FPC also has Ethernet interfaces, you should still be able to have communications with it and perform operations like remote reset (wreset).

Adding Tests to Xi5tester

Xi5tester has been designed to be modular and allows easy addition of further tests. Each test is executed independently and has been written with few side-effects.

The structure that requires particular attention is xi5test, defined in xi5tester.h, whose fields are as shown in Table 5:

 
Table 5:   xi5test

For each new test added, you would need to increment the NUM_TESTS in xi5tester.c and initialised a new entry in tblock. Five routines are needed for each test. For most tests, default routines can be use for exit (xi5_exit_null) and irq (xi5_irq_null). Some of the useful functions are listed in Table 6.

 
Table 6:   Some Useful Routines

It is recommended that before any new test is written, the existing functions in xi5tester be explored and that one tries to construct the new test from some of the existing functions where possible.

The order of execution of the routines in the xi5test structure is as follows: getparms is performed for every test selected, with the parameters kept in parms. The xi5tester forms a linked-list of test selected. When (e)xecute selection is chosen, xi5tester goes through the linked-list and executes each test in sequence. For each test init is first done, follows by the execute of the actual test and finally exit is called to clean up the state.

It should be noted that for each of the test selected, it inherits the enabled and count field from the previous test.



next up previous
Next: About this document Up: A Test Suite for Previous: Interactive Mode



Shaw Chuang