diff options
| author | Steven Hartland <smh@FreeBSD.org> | 2014-07-30 18:21:06 +0000 |
|---|---|---|
| committer | Steven Hartland <smh@FreeBSD.org> | 2014-07-30 18:21:06 +0000 |
| commit | e248a3d1f69cb7629b6df804e8c6cea004aaa9eb (patch) | |
| tree | b06cf453ea9ba4be438aebdb7feb5a4466df51fb /sys/dev/mps | |
| parent | 7571e7f64a525a5d6216c48e52043a961534ac8b (diff) | |
Notes
Diffstat (limited to 'sys/dev/mps')
| -rw-r--r-- | sys/dev/mps/mps.c | 2 | ||||
| -rw-r--r-- | sys/dev/mps/mps_mapping.c | 11 | ||||
| -rw-r--r-- | sys/dev/mps/mps_sas.c | 41 | ||||
| -rw-r--r-- | sys/dev/mps/mpsvar.h | 2 |
4 files changed, 8 insertions, 48 deletions
diff --git a/sys/dev/mps/mps.c b/sys/dev/mps/mps.c index 149e5760a810..403a4d2f8493 100644 --- a/sys/dev/mps/mps.c +++ b/sys/dev/mps/mps.c @@ -610,7 +610,7 @@ mps_iocfacts_free(struct mps_softc *sc) mps_dprint(sc, MPS_TRACE, "%s\n", __func__); - if (sc->post_busaddr != 0) + if (sc->free_busaddr != 0) bus_dmamap_unload(sc->queues_dmat, sc->queues_map); if (sc->free_queue != NULL) bus_dmamem_free(sc->queues_dmat, sc->free_queue, diff --git a/sys/dev/mps/mps_mapping.c b/sys/dev/mps/mps_mapping.c index 97e24be799eb..80022ea4a209 100644 --- a/sys/dev/mps/mps_mapping.c +++ b/sys/dev/mps/mps_mapping.c @@ -336,12 +336,13 @@ _mapping_get_high_missing_mt_idx(struct mps_softc *sc) end_idx = sc->max_devices; if (ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_RESERVED_TARGETID_0) start_idx = 1; - if (sc->ir_firmware) + if (sc->ir_firmware) { _mapping_get_ir_maprange(sc, &start_idx_ir, &end_idx_ir); - if (start_idx == start_idx_ir) - start_idx = end_idx_ir + 1; - else - end_idx = start_idx_ir; + if (start_idx == start_idx_ir) + start_idx = end_idx_ir + 1; + else + end_idx = start_idx_ir; + } mt_entry = &sc->mapping_table[start_idx]; for (map_idx = start_idx; map_idx < end_idx; map_idx++, mt_entry++) { if (mt_entry->missing_count > high_missing_count) { diff --git a/sys/dev/mps/mps_sas.c b/sys/dev/mps/mps_sas.c index d2ca8888c56f..e729d1c552c3 100644 --- a/sys/dev/mps/mps_sas.c +++ b/sys/dev/mps/mps_sas.c @@ -115,7 +115,6 @@ static uint8_t op_code_prot[256] = { MALLOC_DEFINE(M_MPSSAS, "MPSSAS", "MPS SAS memory"); -static void mpssas_discovery_timeout(void *data); static void mpssas_remove_device(struct mps_softc *, struct mps_command *); static void mpssas_remove_complete(struct mps_softc *, struct mps_command *); static void mpssas_action(struct cam_sim *sim, union ccb *ccb); @@ -910,46 +909,6 @@ mpssas_discovery_end(struct mpssas_softc *sassc) } static void -mpssas_discovery_timeout(void *data) -{ - struct mpssas_softc *sassc = data; - struct mps_softc *sc; - - sc = sassc->sc; - MPS_FUNCTRACE(sc); - - mps_lock(sc); - mps_dprint(sc, MPS_INFO, - "Timeout waiting for discovery, interrupts may not be working!\n"); - sassc->flags &= ~MPSSAS_DISCOVERY_TIMEOUT_PENDING; - - /* Poll the hardware for events in case interrupts aren't working */ - mps_intr_locked(sc); - - mps_dprint(sassc->sc, MPS_INFO, - "Finished polling after discovery timeout at %d\n", ticks); - - if ((sassc->flags & MPSSAS_IN_DISCOVERY) == 0) { - mpssas_discovery_end(sassc); - } else { - if (sassc->discovery_timeouts < MPSSAS_MAX_DISCOVERY_TIMEOUTS) { - sassc->flags |= MPSSAS_DISCOVERY_TIMEOUT_PENDING; - callout_reset(&sassc->discovery_callout, - MPSSAS_DISCOVERY_TIMEOUT * hz, - mpssas_discovery_timeout, sassc); - sassc->discovery_timeouts++; - } else { - mps_dprint(sassc->sc, MPS_FAULT, - "Discovery timed out, continuing.\n"); - sassc->flags &= ~MPSSAS_IN_DISCOVERY; - mpssas_discovery_end(sassc); - } - } - - mps_unlock(sc); -} - -static void mpssas_action(struct cam_sim *sim, union ccb *ccb) { struct mpssas_softc *sassc; diff --git a/sys/dev/mps/mpsvar.h b/sys/dev/mps/mpsvar.h index dead1dbd840d..bae023e67668 100644 --- a/sys/dev/mps/mpsvar.h +++ b/sys/dev/mps/mpsvar.h @@ -32,7 +32,7 @@ #ifndef _MPSVAR_H #define _MPSVAR_H -#define MPS_DRIVER_VERSION "18.00.00.00-fbsd" +#define MPS_DRIVER_VERSION "19.00.00.00-fbsd" #define MPS_DB_MAX_WAIT 2500 |
