Re: [PATCH v1] ufs: core: wlun suspend SSU fail recovery

Peter Wang (王信友)
2022-12-01T09:32:17Z

On Wed, 2022-11-30 at 09:49 -0800, Bart Van Assche wrote:
> On 11/30/22 02:17, Adrian Hunter wrote:
> > On 1/11/22 16:24, peter.wang@mediatek.com wrote:
> > > From: Peter Wang <peter.wang@mediatek.com>
> > >
> > > When SSU fail in wlun suspend flow, trigger error handlder and
> >
> > handlder -> handler
> >
> > Why / how does SSU fail?
>
> I'm not sure but the issue that Peter is trying to fix with this
> patch
> may already have been fixed by my patch series "Fix a deadlock in
> the
> UFS driver".
>
> Thanks,
>
> Bart.
>

Hi Bart,

Yes, it may also can fix by
"[v4,07/10] scsi: ufs: Try harder to change the power mode"

But I am not sure if any outher corner case SSU will got antother err
which retry canoot fix? (ex, device always return same error sense code
which host is not expect to receive again, again and again let retry
sill fail)

By the way, in wl suspend flow, not only SSU, but also enter
hibern8(0x17) could got fail. I think it is better fix in both fail
case.
Hera is our 0x17 timeout fail log and runtime suspend retrun timeout.

473-c(1), 21140.355276017,31742,18, rs, ret=-110, time_us= 2892755,
pwr_mode=2, link_status=3
472-u(1), 21139.829423708,31742, 7,0x17,arg1=0x0,arg2=0x0,arg3=0x0,
0
471-r(1), 21139.829361861, 0,
1,0x1b,t=46,db:0x 0,is:0x 80000,crypt:0,0,lba= 0,len=
-1, 1738384
470-r(1), 21139.827623708,31742,
0,0x1b,t=46,db:0x 0,is:0x 80000,crypt:0,0,lba= 0,len=
-1, 0

Thanks.
Peter