$  Copyright(c) 2000 Sun Microsystems, Inc.
$  All rights reserved.

$ #ident  "@(#)qlctest.msg  1.13  02/06/11  SMI"


$ --------------------------------------------------
$ DEBUG:	0
$ --------------------------------------------------

$ --------------------------------------------------
$ VERBOSE:	1-1999
$ --------------------------------------------------

$ QLC_BOARD_REVISION	
1 "QLC Adapter Chip Revision = %d, Risc Revision = %d, \n \
Frame Buffer Revision = %d, Riscrom Revision = %d,\n \
Driver Revision = %s "

$ QLC_FW_REVISION
2 "Firmware revision is %s"

$ QLC_FOUND
3 "QLC device found at %s:devctl."

$ MAILBOX_START
4 "Starting Mailbox Loopback Test"

$ MAILBOX_LOOP_NUM
5 "Running mailbox loopback set number %d"

$ V_OPTIONS_LIST
6 "qlctest:  called with options: %s"

$ ASSIGN_DEVICE
7 "Testing qlc%d device at %s."

$ MAILBOX_END
8 "Done running mailbox loopback test"

$ RUNNING_SELFTEST
9 "Running diag selftest"


$ RUNNING_INTERNAL_LPBK
10 "Running internal 1 bit loopback test"

$ RUNNING_EXTERNAL_LPBK
11 "Running external loopback test"

$ USAGE
12 "qlctest [-o option=value]\n\n\
\tdev=<device name>         (no default)\n\
\tselftest=<Enable|Disable> (default=Enable)\n\
\tmbox=<Enable|Disable>     (default=Disable)(Mailbox loopback test)\n\
\tchecksum=<Enable|Disable> (default=Enable) (Firmware checsum)\n\
\tilb_10=<Enable|Disable>   (default=Enable) (Internal 10 bit loopback)\n\
\tilb=<Enable|Disable>      (default=Enable) (Internal 1 bit loopback\n\
\telb=<Enable|Disable>      (default=Disable)(External loopback)\n\
\ticnt=<1|10|1000|5000>     (default=10)     (Iteration count)\n\
\txcnt=<0x2000|0x4000|0x8000|0x10000>\n\
\t     (default=10000) (Transfer Count)\n\
\tlbfpattern=<0x7e7e7e7e|0xaa55aa55|0xff00ff00|0xdb6db6db>\n\
\t     (default=0x7e7e7e7e)\n\
\n\n NOTE: Do not run other tests while running qlctest\n\
       Must use the -x option from the command line\n"

 



$ RUNNING_CHECKSUM
13 "Running CHECKSUM check"

$ RUNNING_INTERNAL_LPBK_10
14 "Running internal 10 bit loopback test"

$ LOOPBACK
15 "Running loopback test"


$ QLC_FCODE_REVISION
16 "FCODE revision is %s"


$QLC_PG_REVISION
17 "Program Version is %s"


$ --------------------------------------------------
$ INFO:		2000 - 3999
$ --------------------------------------------------


$ --------------------------------------------------
$ WARNING:	4000 - 5999
$ --------------------------------------------------

$ --------------------------------------------------
$ ERROR/FATAL:	6000 - 7999
$ --------------------------------------------------

$ LOOPBACK_MISCOMPARE
6000 "Loopback data miscompare. \
Data received from qlc: 0x%x,\
Data passed into qlc:   0x%x. \
Array index: %d"

$ BAD_ARGS
6001 "Error parsing command line options.  Check command line and re-enter."

$ SYSTEM_CHANGED
6002 "Can not associate physical device with %s." \
Probable_Cause(s): <Hardware changed since VTS probe> \
<Wrong cmnd line arguments> <system software> \
Recommended_Actions: <Stop all testing and re-probe> \
<Check and re-enter command line> \
<if the problem persists, contact authorized Sun service provider>



$ BOARD_REV_FAILED
6003 "IOCTL call to board rev failed, sys errno = %d, fcio_errno = 0x%x"


$ FW_REV_FAILED
6004 "IOCTL call for firmware rev failed, sys errno = %d, fcio_errno = 0x%x"


$ ER_BAD_OPTIONS
6005 "Bad option passed to test: %s"

$ DEV_OUT_OF_RANGE
6006 "No device detected for qlc%d."

$ NO_ASSOCIATION
6007 "Cannot associate a QLC device with %s."

$ NO_DEVICES_FOUND
6008 "No QLC devices detected on this system."

$ LOOPBACK_FAILED
6009 "Loopback test failed. System errno = %d = %s, FCIO errno = %d "

$ TEN_LOOPBACK_FAILED
6010 "TEN bit loopback test failed.\n System errno = %d = %s, FCIO errno = %d, loop number = %d"

$ ONE_LOOPBACK_FAILED
6011 "ONE bit loopback test failed.\n System errno = %d = %s, FCIO errno = %d loop number = %d"

$ EXTERNAL_LOOPBACK_FAILED
6012 "EXTERNAL loopback test failed.\n System errno = %d = %s, FCIO errno = %d loop number = %d"

$ FCODE_REV_FAILED
6013 "IOCTL call for fcode revision failed, sys errno = %d, fcio_errno = 0x%x"


$ ONE_LOOPBACK_MISCOMPARE
6014 "One Bit loopback data miscompare. \
Data received from qlc: 0x%x,\
Data passed into qlc:   0x%x. \
Array index: %d"

$ TEN_LOOPBACK_MISCOMPARE
6015 "Ten Bit loopback data miscompare. \
Data received from qlc: 0x%x,\
Data passed into qlc:   0x%x. \
Array index: %d"

$ EXTERN_LOOPBACK_MISCOMPARE
6016 "External loopback data miscompare. \
Data received from qlc: 0x%x,\
Data passed into qlc:   0x%x. \
Array index: %d"


$ --------------------------------------------------
$ FATAL:	8000 - 9998
$ --------------------------------------------------
 
$ INVALID_FD
8000 "Invalid file descripter %d passed in." \
Probable_Cause(s): <system software> \
Recommended_Actions: \
<if the problem persists, contact authorized Sun service provider>

$ MBOX_IOCTL_FAIL
8001 "IOCTL call failed: %s. FCIO errno = %d, index number = %d, ioctl_return = %d " \
Probable_Cause(s): <wrong/missing QLC driver> <system software> \
Recommended_Actions: <Reload correct revision driver> \
<if the problem persists, contact authorized Sun service provider>


$ FW_CHECKSUM_FAILED
8002 "IOCTL call for Firmware Checksum failed, sys errno = %d, FCIO errno = 0x%x"


$ BAD_DEVICE_NAME
8003 "Bad device name passed to test: %s" \
Probable_Cause(s): <Wrong entry on command line> \
Recommended_Actions: <Check and retype command line>

$ QLC_OPEN_FAILED
8004 "Open of QLC device %s failed; %s" \
Probable_Cause(s): <system software> \
Recommended_Actions: <Contact your system admin for assistance> \
<if the problem persists, contact authorized Sun service provider>

$ NO_INSTANCE_FILE
8005 "Open of /etc/path_to_inst file Failed; %s." \
Probable_Cause(s): <system software> \
Recommended_Actions: <Contact your system admin for assistance> \
<if the problem persists, contact authorized Sun service provider>

$ SELFTEST_IOCTL_FAIL
8006 "IOCTL call failed: %s. Errno = %d, FCIO errno = 0x%x" \
Probable_Cause(s): <wrong/missing QLC driver> <system software> \
Recommended_Actions: <Reload correct revision driver> \
<if the problem persists, contact authorized Sun service provider>


$ SELFTEST_DIAG_FAIL
8007 "QLC Selftest returned with an ERROR: FCIO errno = 0x%x, system errno = %d "

$ DI_INIT_FAIL
8008 "The call to di_init failed."

$ BAD_LBF_ICNT
8009 "To large of an iteration count passed in: %s. Maximum value is 9999" \
Probable_Cause(s): <Wrong entry on command line> \
Recommended_Actions: <Check and retype command line>
 
$ NUM_DEVICES_OPEN_FAILED
8010 "Couldn't open device when trying to find the number of devices attached\n%s. FCIO errno = 0x%x, gl_status = 0x%x" \
Probable_Cause(s): <wrong/missing QLC driver> <system software> \
Recommended_Actions: <Reload correct revision driver> \
<if the problem persists, contact authorized Sun service provider>



$ Probe

10001	"qlcprobe: WARNING: di_init() failed "
$ ER_OPENFAILED 
10002	"ERROR: Failed to open device."
10003	"ERROR: Controller not testable due to devices present on loop or incorrect driver installed"
10004   "ERROR: Devices detected on loop.  Remove devices and reselect"
10005   "ERROR: Unknown error encountered.  Check for installation of correct driver"
10006   "ERROR: Loopback Frame Test cannot be run. Reason:Loop not online"
10007   "ERROR: Invalid dev passed in: %d"

