Fix "set but not used" warnings in the mpr driver. This fixes a minor
bug in error handling.
This commit is contained in:
parent
bcce9c5bed
commit
61f17c5fd6
@ -1229,14 +1229,12 @@ static void
|
||||
mprsas_logical_unit_reset_complete(struct mpr_softc *sc, struct mpr_command *tm)
|
||||
{
|
||||
MPI2_SCSI_TASK_MANAGE_REPLY *reply;
|
||||
MPI2_SCSI_TASK_MANAGE_REQUEST *req;
|
||||
unsigned int cm_count = 0;
|
||||
struct mpr_command *cm;
|
||||
struct mprsas_target *targ;
|
||||
|
||||
callout_stop(&tm->cm_callout);
|
||||
|
||||
req = (MPI2_SCSI_TASK_MANAGE_REQUEST *)tm->cm_req;
|
||||
reply = (MPI2_SCSI_TASK_MANAGE_REPLY *)tm->cm_reply;
|
||||
targ = tm->cm_targ;
|
||||
|
||||
@ -1839,10 +1837,11 @@ mprsas_build_nvme_unmap(struct mpr_softc *sc, struct mpr_command *cm,
|
||||
mpr_build_nvme_prp(sc, cm, req,
|
||||
(void *)(uintptr_t)nvme_dsm_ranges_dma_handle, 0, data_length);
|
||||
mpr_map_command(sc, cm);
|
||||
res = 0;
|
||||
|
||||
out:
|
||||
free(plist, M_MPR);
|
||||
return 0;
|
||||
return (res);
|
||||
}
|
||||
|
||||
static void
|
||||
@ -2919,11 +2918,9 @@ mprsas_send_smpcmd(struct mprsas_softc *sassc, union ccb *ccb, uint64_t sasaddr)
|
||||
uint8_t *request, *response;
|
||||
MPI2_SMP_PASSTHROUGH_REQUEST *req;
|
||||
struct mpr_softc *sc;
|
||||
struct sglist *sg;
|
||||
int error;
|
||||
|
||||
sc = sassc->sc;
|
||||
sg = NULL;
|
||||
error = 0;
|
||||
|
||||
switch (ccb->ccb_h.flags & CAM_DATA_MASK) {
|
||||
|
@ -271,9 +271,6 @@ mprsas_fw_work(struct mpr_softc *sc, struct mpr_fw_event_work *fw_event)
|
||||
}
|
||||
case MPI2_EVENT_SAS_ENCL_DEVICE_STATUS_CHANGE:
|
||||
{
|
||||
Mpi2EventDataSasEnclDevStatusChange_t *data;
|
||||
data = (Mpi2EventDataSasEnclDevStatusChange_t *)
|
||||
fw_event->event_data;
|
||||
mpr_mapping_enclosure_dev_status_change_event(sc,
|
||||
fw_event->event_data);
|
||||
break;
|
||||
|
@ -541,12 +541,10 @@ mpr_print_sgl(struct mpr_softc *sc, struct mpr_command *cm, int offset)
|
||||
MPI2_IEEE_SGE_SIMPLE64 *ieee_sge;
|
||||
MPI25_IEEE_SGE_CHAIN64 *ieee_sgc;
|
||||
MPI2_SGE_SIMPLE64 *sge;
|
||||
MPI2_REQUEST_HEADER *req;
|
||||
struct mpr_chain *chain = NULL;
|
||||
char *frame;
|
||||
u_int i = 0, flags, length;
|
||||
|
||||
req = (MPI2_REQUEST_HEADER *)cm->cm_req;
|
||||
frame = (char *)cm->cm_req;
|
||||
ieee_sge = (MPI2_IEEE_SGE_SIMPLE64 *)&frame[offset * 4];
|
||||
sge = (MPI2_SGE_SIMPLE64 *)&frame[offset * 4];
|
||||
|
Loading…
x
Reference in New Issue
Block a user