RE: [PATCH 4/7] scsi: ufs: core: Fix ufshcd_exception_event_handler()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
> On 10/18/24 10:25 AM, Avri Altman wrote:
> > No. But the Fixes tag seems strange, isn't it?
> 
> How about replacing the entire patch with the patch below?
Right.
Looks like it was introduced in the first place when the query timeout was 100ms:

"..When trying to check the exception event status (for
    finding the cause for the exception event), the device may be busy with
    additional SCSI commands handling and may not respond within the 100ms
    timeout..."

Looks good to me.  I can also test it on Sunday.

Thanks,
Avri
> 
> Thanks,
> 
> Bart.
> 
> 
> scsi: ufs: core: Simplify ufshcd_exception_event_handler()
> 
> The ufshcd_scsi_block_requests() and ufshcd_scsi_unblock_requests() calls
> were introduced in ufshcd_exception_event_handler() to prevent that
> querying the exception event information would time out. Commit
> 10fe5888a40e ("scsi: ufs: increase the scsi query response timeout")
> increased the timeout for querying exception information from 30 ms to
> 1.5 s and thereby eliminated the risk that a timeout would happen.
> Hence, the calls to block and unblock SCSI requests are superfluous.
> Remove these calls.
> 
> diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c index
> 76884df580c3..2fde1b0a6086 100644
> --- a/drivers/ufs/core/ufshcd.c
> +++ b/drivers/ufs/core/ufshcd.c
> @@ -6195,12 +6195,11 @@ static void
> ufshcd_exception_event_handler(struct work_struct *work)
>         u32 status = 0;
>         hba = container_of(work, struct ufs_hba, eeh_work);
> 
> -       ufshcd_scsi_block_requests(hba);
>         err = ufshcd_get_ee_status(hba, &status);
>         if (err) {
>                 dev_err(hba->dev, "%s: failed to get exception status %d\n",
>                                 __func__, err);
> -               goto out;
> +               return;
>         }
> 
>         trace_ufshcd_exception_event(dev_name(hba->dev), status); @@ -
> 6212,8 +6211,6 @@ static void ufshcd_exception_event_handler(struct
> work_struct *work)
>                 ufshcd_temp_exception_event_handler(hba, status);
> 
>         ufs_debugfs_exception_event(hba, status);
> -out:
> -       ufshcd_scsi_unblock_requests(hba);
>   }
> 
>   /* Complete requests that have door-bell cleared */





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux