1
0
Files
irix-657m-src/stand/arcs/ide/EVEREST/shell.IP25
2022-09-29 17:59:04 +03:00

402 lines
6.7 KiB
Plaintext

# This is an ide startup file.
#ident EVEREST/shell
# $Revision: 1.1 $
report=2
hinv -v
scripts {
echo ""
echo "IDE included scripts are:"
echo ""
echo " ? - list all IDE commands"
echo " memfast - invokes mem3, mem5, mem8, mem9, mem10, mem16"
echo " memall - invokes mem1 to mem10, mem15, mem16 and mem18"
echo " io_all - invokes all tests for IO4"
echo " scsi_all - invokes all SCSI tests for IO4"
echo " dang_all - invokes all DANG/GGAM tests for IO4"
echo " ev_quick - invokes standalone diag suite quickly"
echo " everest_all - invokes entire standalone diag suite"
echo " scripts - displays this list"
echo ""
echo " ** 'exit' or 'quit' returns to PROM monitor**"
echo " ** Always reset system ('reset' at PROM prompt) before booting IDE **"
echo ""
}
list {
if ($$ == 1) {
printf "list "
symbols -l
printf "\n"
return 0
} else {
$res_ult = symbols -t $1
return $res_ult
}
}
match {
if ($$ == 1) {
printf "usage: match KEYSTRING\n"
return -1
} else {
$res_ult = symbols -k $1
return $res_ult
}
}
isaset {
$r_es = set_exists -s $1
return $r_es
}
isamember {
$r_es = cpu_in -v $1 -s $2
return $r_es
}
clear_set {
if (isaset "mty_set" == $FALSE) {
create_set -s "mty_set" -e
}
if (isaset $1 == $FALSE) {
printf ("set not found\n");
return $FALSE
}
$1 = $mty_set
return $TRUE
}
cpu_count {
$cnt = 0
for ($loop=0; $loop<64; $loop++) {
if (isamember $loop $1) {
$cnt+=1
}
}
return $cnt
}
hx {
printf "0x%x\n" $1
}
#
# define simple usec, msec, and second delays
# printf " - delays with intervals of usec, msec, and second granularity:\n"
# printf " --> us_delay, ms_delay, and sleep.\n usages: "
# printf " 'us_delay USECS' 'ms_delay MSECS' 'sleep SECS'\n"
us_delay {
ide_delay -u $1
}
# eg: 'us_delay 100'
ms_delay {
ide_delay -m $1
}
# eg: 'ms_delay 15'
sleep {
ide_delay -s $1
}
# eg: 'sleep 5'
printf " - define symcmd, charcmd, set_charcmd, newset, showset\n"
# demonstrate parameter-passing for user-defined commands which
# call functions using the 'sym_t *' argv format
symcmd {
test_symcmd $1
}
# and for udef commands calling functions using 'char *' argv format
charcmd {
test_charcmd $1 $2
}
# here's an example using the set-execution stuff
set_charcmd {
test_charcmd -- -s $1 -i -- $2 $3
}
newset {
$R_ES = create_set -s $1
return $R_ES
}
showset {
$R_ES = display_set -s $1
return $R_ES
}
# get_vpinfo SETNAME
# echo "define get_vpinfo"
# cpuinfo {
# change and restore report to mute the helpful verbosity
# $tmpr = $report
# $report = 1
# printf " init '%s' with the set of active virtual processors\n" $1
# $res_ = create_set -s $1
# if ($res_ != 0) {
# printf "\nget_vpinfo: create_set failed (%d)\n" $res
# } else {
# printf " %s: " $1
# display_set -s $1
# printf "\n"
# }
# $report = $tmpr
# return $res
# }
printf " - define subdue, restore,"
subdue {
$2 = $report
$report = $1
$srvalid_ = 0xd0dd
}
restore {
if ($srvalid_ == 0xd0dd) {
$report = $2
}
$srvalid_ = 0xdead
}
# defines for the memory tests to make them "automatically" icached
mem2 {
runcached on
clear_intrs
mem2_
runcached off
}
mem3 {
runcached on
clear_intrs
mem3_
runcached off
}
mem4 {
runcached on
clear_intrs
mem4_
runcached off
}
mem5 {
runcached on
clear_intrs
mem5_
runcached off
}
mem6 {
runcached on
clear_intrs
mem6_
runcached off
}
mem7 {
runcached on
clear_intrs
mem7_
runcached off
}
mem8 {
runcached on
clear_intrs
mem8_
runcached off
}
mem9 {
runcached on
clear_intrs
mem9_
runcached off
}
mem10 {
runcached on
clear_intrs
mem10_
runcached off
}
mem15 {
runcached on
clear_intrs
mem15_
runcached off
}
mem16 {
runcached on
clear_intrs
mem16_
runcached off
}
mem18 {
runcached on
clear_intrs
mem18_
runcached off
}
printf " - define memall"
memall {
#Read memory configuration registers
mem1
#Memory sockets connection test
mem2
#Memory address walking test
mem3
#Memory data write/read tes
mem4
#Memory address in address test
mem5
#Memory data walking test
mem6
#Memory data MarchX pattern test
mem7
#Memory data MarchY pattern test
mem8
#Memory with ECC test
mem9
#Memory with cache write-through test
mem10
#Double word march y pattern test
mem15
#Knaizuk Hartmann Test
mem16
#Double word Knaizuk Hartmann Test
mem18
printf "Finished memall\n"
}
printf ", memfast\n"
memfast {
#Memory address walking test
mem3
#Memory address in address test
mem5
#Memory data MarchY pattern test
mem8
#Memory with ECC test
mem9
#Memory with cache write-through test
mem10
#Knaizuk Hartmann Test
mem16
printf "Finished memfast\n"
}
printf " - define scsi_all"
scsi_all {
# Register Read/Write test for s1 chip
s1_regtest
# wd95a scsi controller register test
regs_95a
# scsi send diag test
# scsi_self
# scsi interrupt from wd95a test
scsi_intr
# scsi dma transfer test
# scsi_dmaxfer
# scsi dma interrupt test
# scsi_dmaintr
printf "Finished scsi_all\n"
}
printf " - define dang_all"
dang_all {
# dang register read/write test
dang_regtest
#gio bus interface test, read/write on gr2 shared ram
dang_gr2ram
# tests wg fifo rams, host wg addressing modes, fifo and priv viol interrupts
dang_wg
# tests host/graphics and g/h dma transfers, dma complete interrupt
dang_mdma
printf "Finished dang_all\n"
}
printf ", io_all"
io_all {
# Checks IO4 config against NVRAM
check_iocfg
# Read/Write test of IO4 registers
io4_regtest
# IO4 PIO bus error test
io4_pioerr
# Read/Write test of IO4 map ram
mapram_test
# all scsi tests
scsi_all
# Register Read/Write test for epc chip
epc_regtest
# NVRAM Read/Write test
epc_nvram
# RTC Read/Write test
epc_rtcreg
# RTC clock increment test
epc_rtcinc
# RTC interrupt generation test
epc_rtcint
# Duart loopback test
duart_loopback
# Parallel Port Write Test
epc_plptest
#Fchip register test
fregs
#VMECC register test
vmeregs
#VMECC self interrupt test
vmeintr
#VMECC loopback test
#vmelpbk
#VMECC buserror test
vmeberr
#VMECC dma test using CDSIO - skips if no CDSIO board installed
vmedma
#CDSIO data test - skips if no CDSIO board installed or new rev proms
cddata
#CDSIO interrupt test - skips if no CDSIO board installed or new rev proms
cdintr
#all dang tests
dang_all
printf "Finished io_all\n"
}
printf ", ev_quick"
ev_quick {
echo "Starting quick EVEREST standalone diag suite"
echo ""
memfast
io_all
echo ""
echo "End of quick EVEREST standalone diag suite"
}
printf ", and everest_all\n\n"
everest_all {
echo "Starting EVEREST standalone diag suite"
echo ""
memall
io_all
echo ""
echo "End of EVEREST standalone diag suite"
}
printf " -- END OF SCRIPT DEFINITIONS --\n\n"
scripts
$TRUE = 1
$FALSE = 0