466 lines
8.5 KiB
Plaintext
466 lines
8.5 KiB
Plaintext
# This is an ide startup file.
|
|
#
|
|
report=4 # set verbose, but not debug
|
|
$stoponerr=1
|
|
$runin=0
|
|
$func=0
|
|
$do_cpu=0
|
|
$failed=0
|
|
$report_pass=0 # Report pass condition in runin
|
|
$status=0
|
|
$test_name=""
|
|
|
|
is_R10k {
|
|
$processor = find_cpu
|
|
if ( $processor == 2 )
|
|
return (1);
|
|
else
|
|
return (0);
|
|
}
|
|
is_R5k {
|
|
$processor = find_cpu
|
|
if ( $processor == 1 )
|
|
return (1);
|
|
else
|
|
return (0);
|
|
}
|
|
is_R12k {
|
|
$processor = find_cpu
|
|
if ( $processor == 3 )
|
|
return (1);
|
|
else
|
|
return (0);
|
|
}
|
|
menu {
|
|
|
|
echo ""
|
|
echo "Ide included scripts are:"
|
|
echo " cpu Do all cpu module related tests."
|
|
echo " ip32 Do all ip32 related tests."
|
|
echo " memory Do all memory tests."
|
|
echo " s_cache Do only secondary cache tests."
|
|
echo " graphics Do only graphics tests."
|
|
echo ""
|
|
|
|
}
|
|
|
|
# Check test status then do bootp to send message if in runin
|
|
|
|
Do_Bootp {
|
|
boot -n -f $1
|
|
}
|
|
|
|
Chk_For_Error {
|
|
if ($status) {
|
|
$failed = 1;
|
|
echo $test_name "FAILED"
|
|
if ($runin) {
|
|
$tmp = "bootp()" + $test_name + ".fail"
|
|
Do_Bootp $tmp
|
|
}
|
|
if ($stoponerr) {
|
|
wait
|
|
}
|
|
}
|
|
else {
|
|
if ($runin && $report_pass) {
|
|
$tmp = "bootp()" + $test_name + ".pass"
|
|
Do_Bootp $tmp
|
|
}
|
|
}
|
|
}
|
|
|
|
# Test memory
|
|
memory {
|
|
$report_pass = 0
|
|
$failed = 0
|
|
echo "** Start memtest3 Test **"
|
|
$test_name = "memtest3"
|
|
$status = memtest3;
|
|
Chk_For_Error
|
|
|
|
echo "** Start memtest3_1 Test **"
|
|
$test_name = "memtest3_1"
|
|
$status = memtest3 1;
|
|
Chk_For_Error
|
|
|
|
echo "** Start memtest Test **"
|
|
$test_name = "memtest"
|
|
$status = memtest;
|
|
Chk_For_Error
|
|
|
|
# $report_pass = 0
|
|
# echo "** Start memtest2 0 Test **"
|
|
# $test_name = "memtest2_0"
|
|
# $status = memtest2 0;
|
|
# Chk_For_Error
|
|
|
|
echo "** Start memtest2 1 Test **"
|
|
date
|
|
$test_name = "memtest2_1"
|
|
$status = memtest2 1;
|
|
Chk_For_Error
|
|
|
|
# echo "** Start memtest2 2 Test **"
|
|
# date
|
|
# $test_name = "memtest2_2"
|
|
# $status = memtest2 2;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 3 Test **"
|
|
# date
|
|
# $test_name = "memtest2_3"
|
|
# $status = memtest2 3;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 5 Test **"
|
|
# date
|
|
# $test_name = "memtest2_5"
|
|
# $status = memtest2 5;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 8 Test **"
|
|
# date
|
|
# $test_name = "memtest2_8"
|
|
# $status = memtest2 8;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 9 Test **"
|
|
# date
|
|
# $test_name = "memtest2_9"
|
|
# $status = memtest2 9;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 10 Test **"
|
|
# date
|
|
# $test_name = "memtest2_10"
|
|
# $status = memtest2 10;
|
|
# Chk_For_Error
|
|
|
|
# echo "** Start memtest2 12 Test **"
|
|
# date
|
|
# $test_name = "memtest2_12"
|
|
# $status = memtest2 12;
|
|
# Chk_For_Error
|
|
|
|
# $report_pass = 0
|
|
# echo "** Start memtest2 13 Test **"
|
|
# date
|
|
# $test_name = "memtest2_13"
|
|
# $status = memtest2 13;
|
|
# Chk_For_Error
|
|
|
|
date
|
|
|
|
if ($failed) {
|
|
echo "\n#### Memory Test FAILED ####"
|
|
}
|
|
else {
|
|
echo "\n#### Memory Test PASSED ####"
|
|
}
|
|
}
|
|
|
|
#
|
|
# Do cpu related tests
|
|
#
|
|
cpu {
|
|
|
|
$report_pass = 0
|
|
$failed = 0
|
|
date
|
|
# TLB test. Verify different tlb functions.
|
|
echo "** Start tlb Test ** "
|
|
$test_name = "tlb"
|
|
$status = tlb
|
|
Chk_For_Error
|
|
|
|
# UTLB miss exception test. Verify the exception generating capability of the
|
|
# mips chip during a utlb miss.
|
|
#if ((utlb) && $stoponerr)
|
|
|
|
# $report_pass = 1
|
|
echo "** Start fpu Test **"
|
|
date
|
|
$test_name = "fpu"
|
|
$status = fpu;
|
|
Chk_For_Error
|
|
$report_pass = 0
|
|
|
|
echo "** Start dcache1 Test **"
|
|
$test_name = "dcache1"
|
|
$status = dcache1;
|
|
Chk_For_Error
|
|
|
|
echo "** Start icache1 Test **"
|
|
$test_name = "icache1"
|
|
$status = icache1;
|
|
Chk_For_Error
|
|
|
|
echo "** Start icache2 Test **"
|
|
$test_name = "icache2"
|
|
$status = icache2;
|
|
Chk_For_Error
|
|
|
|
# $report_pass = 1
|
|
if ( is_R5k || $runin ) {
|
|
date
|
|
echo "** Start scache2 Test **"
|
|
$test_name = "scache2"
|
|
$status = scache2;
|
|
Chk_For_Error
|
|
}
|
|
|
|
echo "** Start scache3 Test **"
|
|
date
|
|
$test_name = "scache3"
|
|
$status = scache3;
|
|
Chk_For_Error
|
|
|
|
# if ( $runin ) {
|
|
echo "** Start scache4 Test **"
|
|
date
|
|
$test_name = "scache4"
|
|
$status = scache4;
|
|
Chk_For_Error
|
|
# }
|
|
|
|
echo "** Start scache6 Test **"
|
|
date
|
|
$test_name = "scache6"
|
|
$status = scache6;
|
|
Chk_For_Error
|
|
|
|
if ($failed) {
|
|
echo "#### IP32 - CPU Test FAILED ####"
|
|
}
|
|
else {
|
|
echo "#### IP32 - CPU Test PASSED ####"
|
|
}
|
|
} # End of cpu script
|
|
|
|
ip32 {
|
|
|
|
$failed = 0
|
|
$report_pass = 0
|
|
|
|
echo "** Start cntrs Test **"
|
|
$test_name = "cntrs"
|
|
$status = cntrs
|
|
Chk_For_Error
|
|
|
|
echo "** Start RTC Register Test **"
|
|
$test_name = "rtcreg"
|
|
$status = rtcreg
|
|
Chk_For_Error
|
|
|
|
echo "** Start RTC Test **"
|
|
$test_name = "clock"
|
|
$status = clock
|
|
Chk_For_Error
|
|
|
|
echo "** Start NIC Test **"
|
|
$test_name = "NIC"
|
|
$status = check_nic
|
|
Chk_For_Error
|
|
|
|
# echo "** Start i2c_reg Test **"
|
|
# $test_name = "i2c_reg"
|
|
# $status = i2c_reg;
|
|
# Chk_For_Error
|
|
|
|
echo "** Start PCI Test **"
|
|
$test_name = "pci"
|
|
$status = pci;
|
|
Chk_For_Error
|
|
|
|
echo "** Start maceec - Mace Ethernet Test **"
|
|
$test_name = "maceec"
|
|
$status = maceec;
|
|
Chk_For_Error
|
|
|
|
echo "** Start plpreg Test **"
|
|
$test_name = "plpreg"
|
|
$status = plpreg;
|
|
Chk_For_Error
|
|
|
|
echo "** Start plploop Test **"
|
|
$test_name = "plploop"
|
|
$status = plploop;
|
|
Chk_For_Error
|
|
#
|
|
# If we are in functional test then do plp ext loopback test
|
|
#
|
|
if ($func) {
|
|
echo "** Start plp_ext_loop Test **"
|
|
$test_name = "plp_ext_loop"
|
|
$status = plp_ext_loop;
|
|
Chk_For_Error
|
|
|
|
}
|
|
if ($runin) {
|
|
echo "** SKIPPING SERIAL LOOP TEST FOR RUNIN **"
|
|
}
|
|
else {
|
|
echo "** Start serialloop Test **"
|
|
$test_name = "serialloop"
|
|
$status = serialloop;
|
|
Chk_For_Error
|
|
}
|
|
|
|
echo "** Start scsi Test **"
|
|
$test_name = "scsi"
|
|
$status = scsi;
|
|
Chk_For_Error
|
|
|
|
# $report_pass = 0
|
|
# echo "** Start memtest - 1MB - Test **"
|
|
# $test_name = "memtest1MB"
|
|
# $status = memtest 0xa1000000:0xa1100000
|
|
# Chk_For_Error
|
|
|
|
date
|
|
|
|
if ($failed) {
|
|
echo "#### IP32 Test FAILED ####"
|
|
}
|
|
else {
|
|
echo "#### IP32 Test PASSED ####"
|
|
}
|
|
}
|
|
|
|
s_cache {
|
|
$scachefail = 0
|
|
echo "** Start scache2 Test **"
|
|
date
|
|
$status = scache2;
|
|
if ($status) {
|
|
$scachefail = 1;
|
|
wait;
|
|
}
|
|
echo "** Start scache3 Test **"
|
|
$status = scache3;
|
|
if ($status) {
|
|
$scachefail = 1;
|
|
wait;
|
|
}
|
|
echo "** Start scache4 Test **"
|
|
$status = scache4;
|
|
if ($status) {
|
|
$scachefail = 1;
|
|
wait;
|
|
}
|
|
|
|
echo "** Start scache6 Test **"
|
|
$status = scache6;
|
|
if ($status) {
|
|
$scachefail = 1;
|
|
wait;
|
|
}
|
|
|
|
if ($scachefail)
|
|
echo "\n#### s_cache Tests FAILED"
|
|
else
|
|
echo "\n#### s_cache Tests PASSED"
|
|
|
|
}
|
|
|
|
#
|
|
# Setup the environment to boot unix then DOIT
|
|
#
|
|
boot_unix {
|
|
echo "Booting UNIX. . ."
|
|
if ( $runin )
|
|
boot -n -f bootp()start_unix
|
|
setenv SystemPartition pci(0)scsi(0)disk(1)rdisk(0)partition(8)
|
|
setenv OSLoader sash
|
|
setenv AutoLoad Yes
|
|
mfg_reboot
|
|
}
|
|
|
|
graphics {
|
|
|
|
$failed = 0
|
|
|
|
$report_pass = 0
|
|
echo "** Start GFX Reg Test **"
|
|
$test_name = "gfx_reg"
|
|
runcached on
|
|
$status = gfx_reg_test;
|
|
Chk_For_Error
|
|
|
|
$report_pass = 0
|
|
echo "** Start GFX qnd Test **"
|
|
$test_name = "qnd_gfx"
|
|
runcached on
|
|
$status = qnd_gfx_test;
|
|
Chk_For_Error
|
|
|
|
runcached off
|
|
if ( $failed )
|
|
echo "#### Graphics Test FAILED ####"
|
|
else
|
|
echo "#### Graphics Test PASSED ####"
|
|
}
|
|
start_ide {
|
|
if ( $PROGRAM_NAME == "cpu32.ide" || $PROGRAM_NAME == "bootp()/usr/local/boot/cpu32.ide" || $PROGRAM_NAME == "bootp()cpu32.ide" ) {
|
|
$do_cpu=1
|
|
echo "#### Start Cpu32 Script ####"
|
|
hinv -v
|
|
msglog_start
|
|
cpu
|
|
msglog_stop
|
|
boot_unix
|
|
}
|
|
if ( $PROGRAM_NAME == "ip32.ide" || $PROGRAM_NAME == "bootp()/usr/local/boot/ip32.ide" || $PROGRAM_NAME == "bootp()ip32.ide" ) {
|
|
echo "#### Start IP32 Script ####"
|
|
hinv -v
|
|
msglog_start
|
|
cpu
|
|
ip32
|
|
msglog_stop
|
|
}
|
|
if ( $PROGRAM_NAME == "func32.ide" || $PROGRAM_NAME == "bootp()/usr/local/boot/func32.ide" || $PROGRAM_NAME == "bootp()func32.ide" ) {
|
|
$func = 1
|
|
echo "#### Start Func32 Script ####"
|
|
hinv -v
|
|
msglog_start
|
|
# cpu
|
|
ip32
|
|
msglog_stop
|
|
graphics
|
|
boot_unix
|
|
}
|
|
if ( $PROGRAM_NAME == "runin32.ide" || $PROGRAM_NAME == "bootp()/usr/local/boot/runin32.ide" || $PROGRAM_NAME == "bootp()runin32.ide" ) {
|
|
echo "#### Start Runin32 Script ####"
|
|
$runin = 1
|
|
hinv -v
|
|
msglog_start
|
|
cpu
|
|
ip32
|
|
msglog_stop
|
|
graphics
|
|
msglog_start
|
|
memory
|
|
msglog_stop
|
|
boot_unix
|
|
}
|
|
menu;
|
|
}
|
|
|
|
if ( is_R5k )
|
|
echo "Running on an R5k Processor"
|
|
else {
|
|
if ( is_R10k )
|
|
echo "Running on an R10k Processor"
|
|
else {
|
|
if ( is_R12k )
|
|
echo "Running on an R12k Processor"
|
|
else
|
|
echo "Running on an Unknown Processor"
|
|
}
|
|
}
|
|
|
|
|
|
start_ide;
|
|
|