GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LCBT / V1-6-2 > lcbt / rad750


Interface   Data Structures   File List   Data Fields   Globals  

LCBT_testAll.c File Reference

overall public Regression Tests for LCB More...

#include <stdio.h>
#include <PBS/PBS.h>
#include <PBS/MBA.h>
#include <PBS/CACHE.h>
#include <LCBT/LCBT.h>
#include <LCBT_printf.h>
#include <trace.h>

Functions

void LCBT_regs ()
 print vals of all registers in LCB
int LCBT_testAll (int num, int nLoops, int latpAddr, int loopbackCable)
 overall test, does complete regression test of LCB
int LCBT_testAllEpu (int num, int nLoops, int latpAddr, int loopbackCable)
 overall test for EPU, does complete regression test of LCB minus cmdResp test
int LCBT_clearErrorTotals ()
 clear the global error counts
int LCBT_printErrorTotals (char *title)
 print the global error counts
int LCBT_updateErrorTotals (int numAccess, int rErr, int wErr, int cErr)
 update the global error counts
int LCBT_saveErrorForDeltas ()
 stash global error counts to use with LCBT_printErrorDeltas()
int LCBT_printErrorDeltas (char *title)
 print the delta error counts since LCBT_saveErrorForDeltas()
int LCBT_getErrorTotals (int *numAccess, int *rErr, int *wErr, int *cErr)
 get the global error counts


Detailed Description

overall public Regression Tests for LCB

Author:
Ed Bacho -- ebacho@slac.stanford.edu

Function Documentation

int LCBT_clearErrorTotals (  ) 

clear the global error counts

Returns:
total error count before clearing

int LCBT_getErrorTotals ( int *  numAccess,
int *  rErr,
int *  wErr,
int *  cErr 
)

get the global error counts

Parameters:
numAccess if not NULL, return number of R/W/Compare ops
rErr if not NULL, return number of read errors
wErr if not NULL, return number of write errors
cErr if not NULL, return number of compare errors
Returns:
total error count

int LCBT_printErrorDeltas ( char *  title  ) 

print the delta error counts since LCBT_saveErrorForDeltas()

Parameters:
title title to print before totals
Returns:
total error count

References PRINTF.

Referenced by LCBT_cmdExternalTest(), LCBT_cmdLocalTest(), LCBT_cmdLocalTest2(), and LCBT_cmdLocalTest3().

int LCBT_printErrorTotals ( char *  title  ) 

print the global error counts

Parameters:
title title to print before totals
Returns:
total error count

References PRINTF.

void LCBT_regs (  ) 

int LCBT_saveErrorForDeltas (  ) 

stash global error counts to use with LCBT_printErrorDeltas()

Returns:
total error count

Referenced by LCBT_cmdExternalTest(), LCBT_cmdLocalTest(), LCBT_cmdLocalTest2(), LCBT_cmdLocalTest3(), and LCBT_localRegTest().

int LCBT_testAll ( int  num,
int  nLoops,
int  latpAddr,
int  loopbackCable 
)

overall test, does complete regression test of LCB

Parameters:
num number of accesses to board per test
nLoops number of times thru all tests test
latpAddr 0=route event tests back to self, else route event test to echo server at this addr
loopbackCable 1=loopback cable present and will run event test, 0=no cable so run event tests only if GASU availible
Returns:
0=success, else indicates errors detected This routine does all the regression tests for an LCB board. The routines uses the configuration set thru LCBT_determineHw() or LCBT_setCfg() to determine which tests are appropriate to run. It keeps a sum of total accesses and errors over all the tests.
The events test run can be looped back thru a loopback cable, a GASU, or another CPU (running echo server) connected to the GASU.

References LCBT_GASU_AVAIL, LCBT_hwAvail(), LCBT_MASK_VALID, and PRINTF.

int LCBT_testAllEpu ( int  num,
int  nLoops,
int  latpAddr,
int  loopbackCable 
)

overall test for EPU, does complete regression test of LCB minus cmdResp test

Parameters:
num number of accesses to board per test
nLoops number of times thru all tests test
latpAddr 0=route event tests back to self, else route event test to echo server at this addr
loopbackCable 1=loopback cable present and will run event test, 0=no cable so run event tests only if GASU availible
Returns:
0=success, else indicates errors detected Same as LCBT_testAll() except will not do cmdResponse tests since can only be done from a commander.

References LCBT_GASU_AVAIL, LCBT_hwAvail(), LCBT_MASK_VALID, and PRINTF.

int LCBT_updateErrorTotals ( int  numAccess,
int  rErr,
int  wErr,
int  cErr 
)

update the global error counts

Parameters:
numAccess Number of R/W/Compare ops
rErr number of read errors
wErr number of write errors
cErr number of compare errors
Returns:
total error count g

Referenced by LCBT_localRegTest().


Generated on Fri Mar 25 12:53:43 2011 by  doxygen 1.5.8