diff options
| author | Matt Jacob <mjacob@FreeBSD.org> | 1998-09-17 23:20:29 +0000 |
|---|---|---|
| committer | Matt Jacob <mjacob@FreeBSD.org> | 1998-09-17 23:20:29 +0000 |
| commit | a70ac9fd83e9711393fb68ccdb56d2e8860a1b2f (patch) | |
| tree | 566a4c3c644729edf2c949ce9f07faa2a4684e12 /sys/dev/isp/isp.c | |
| parent | 7ac6b5a3144767aec635b5cb9d8436538ca1916a (diff) | |
Notes
Diffstat (limited to 'sys/dev/isp/isp.c')
| -rw-r--r-- | sys/dev/isp/isp.c | 26 |
1 files changed, 24 insertions, 2 deletions
diff --git a/sys/dev/isp/isp.c b/sys/dev/isp/isp.c index bedd3c21c4027..b93775007e833 100644 --- a/sys/dev/isp/isp.c +++ b/sys/dev/isp/isp.c @@ -101,6 +101,7 @@ static void isp_fw_state __P((struct ispsoftc *)); static void isp_dumpregs __P((struct ispsoftc *, const char *)); static void isp_dumpxflist __P((struct ispsoftc *)); static void isp_prtstst __P((ispstatusreq_t *)); +static char *isp2100_fw_statename __P((u_int8_t)); static void isp_mboxcmd __P((struct ispsoftc *, mbreg_t *)); static void isp_update __P((struct ispsoftc *)); @@ -802,8 +803,9 @@ isp_fibre_init(isp) for (count = 0; count < 12000; count++) { isp_fw_state(isp); if (lwfs != fcp->isp_fwstate) { - PRINTF("%s: Firmware State %s -> %s\n", isp->isp_name, - fw_statename(lwfs), fw_statename(fcp->isp_fwstate)); + PRINTF("%s: Firmware State %s -> %s\n", + isp->isp_name, isp2100_fw_statename(lwfs), + isp2100_fw_statename(fcp->isp_fwstate)); lwfs = fcp->isp_fwstate; } if (fcp->isp_fwstate == FW_READY) { @@ -2700,6 +2702,9 @@ isp_watch(arg) RESTART_WATCHDOG(isp_watch, isp); } +/* + * Miscellaneous debug statements. + */ static void isp_prtstst(sp) ispstatusreq_t *sp; @@ -2740,6 +2745,23 @@ isp_prtstst(sp) PRINTF("\n"); } +static char * +isp2100_fw_statename(state) + u_int8_t state; +{ + switch(state) { + case FW_CONFIG_WAIT: return "Config Wait"; + case FW_WAIT_AL_PA: return "Waiting for AL/PA"; + case FW_WAIT_LOGIN: return "Wait Login"; + case FW_READY: return "Ready"; + case FW_LOSS_OF_SYNC: return "Loss Of Sync"; + case FW_ERROR: return "Error"; + case FW_REINIT: return "Re-Init"; + case FW_NON_PART: return "Nonparticipating"; + default: return "eh?"; + } +} + /* * NVRAM Routines */ |
