diff options
| author | Scott Long <scottl@FreeBSD.org> | 2003-06-26 00:03:59 +0000 |
|---|---|---|
| committer | Scott Long <scottl@FreeBSD.org> | 2003-06-26 00:03:59 +0000 |
| commit | dea4622d59e44daa47a9084e53198a730eefaab9 (patch) | |
| tree | a44cbcf05050fb0e7ea38906671beb724d169bf6 /sys/dev/ips/ips.c | |
| parent | 48f12e5860f07f26d0313e5f6c9d56c8d0457101 (diff) | |
Notes
Diffstat (limited to 'sys/dev/ips/ips.c')
| -rw-r--r-- | sys/dev/ips/ips.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/sys/dev/ips/ips.c b/sys/dev/ips/ips.c index 984fdf9fab41..4d6d1fd0c35b 100644 --- a/sys/dev/ips/ips.c +++ b/sys/dev/ips/ips.c @@ -322,6 +322,7 @@ static void ips_timeout(void *arg) /* check card and initialize it */ int ips_adapter_init(ips_softc_t *sc) { + int i; DEVICE_PRINTF(1,sc->dev, "initializing\n"); if (bus_dma_tag_create( /* parent */ sc->adapter_dmatag, /* alignemnt */ 1, @@ -359,13 +360,18 @@ int ips_adapter_init(ips_softc_t *sc) can handle */ sc->max_cmds = 1; ips_cmdqueue_init(sc); + callout_handle_init(&sc->timer); if(sc->ips_adapter_reinit(sc, 0)) goto error; mtx_init(&sc->cmd_mtx, "ips command mutex", NULL, MTX_DEF); - if(ips_get_adapter_info(sc) || ips_get_drive_info(sc)){ - device_printf(sc->dev, "failed to get configuration data from device\n"); + if ((i = ips_get_adapter_info(sc)) != 0) { + device_printf(sc->dev, "failed to get adapter configuration data from device (%d)\n", i); + goto error; + } + if ((i = ips_get_drive_info(sc)) != 0) { + device_printf(sc->dev, "failed to get drive configuration data from device (%d)\n", i); goto error; } ips_update_nvram(sc); /* no error check as failure doesn't matter */ |
