On Friday, February 14, 2014 4:01 PM, XinHong Zhu wrote: 
> If a phy device is removed ,the device can get error of I/O and HBA maybe
> receieve IO_OPEN_CNX_ERROR_IT_NEXUS_LOSS of event which causes
pm8001_work_fn
> to reset the phy device ,but in pm8001_task_exec don't assign a value for
> field device of ccb  and in other case a ccb used have device field set ,
when
> ccb is freeed the field device of the ccb don't be set NULL.So there is
> possibility of getting another devcie reset in fun of mpi_ssp_completion
.Also
> there are another way to solve problem by adding following code in
> mpi_SSP_completion:
>   pm8001_dev = t->dev->lldd_dev;
> Signed-off-by: zhuxh <zxh3...@163.com>
> ---
>  drivers/scsi/pm8001/pm8001_sas.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/scsi/pm8001/pm8001_sas.c
> b/drivers/scsi/pm8001/pm8001_sas.c
> index f50ac44..f0ea5db 100644
> --- a/drivers/scsi/pm8001/pm8001_sas.c
> +++ b/drivers/scsi/pm8001/pm8001_sas.c
> @@ -434,6 +434,7 @@ static int pm8001_task_exec(struct sas_task *task,
const
> int num,
>               ccb->n_elem = n_elem;
>               ccb->ccb_tag = tag;
>               ccb->task = t;
> +             ccb->device = pm8001_dev;
>               switch (t->task_proto) {
>               case SAS_PROTOCOL_SMP:
>                       rc = pm8001_task_prep_smp(pm8001_ha, ccb);

Acked-by: Lindar Liu <lindar_...@usish.com>

This is the best way to fix such issue. Thanks.

> --
> 1.7.9


--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to