Re: [PATCH 2/2] scsi: ufs: core: Fix the code for entering hibernation

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

 



On Wed, 2024-08-28 at 07:18 -0400, Bart Van Assche wrote:
>  	 
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
>  On 8/28/24 2:17 AM, Peter Wang (王信友) wrote:
> > No, I means you can reference ufs-sprd.c driver. which may have the
> > same issue?
> > 
> > /*
> >  * Disable UIC COMPL INTR to prevent access to
> > UFSHCI after
> >  * checking HCS.UPMCRS
> >  */
> > ufs_sprd_ctrl_uic_compl(hba, false);
> > 
> > Then after enter hibernte, you can prevent access to UFSHCI.
> > After exit hibernate, enable uic complete interrupt again for
> > workaround.
> Hi Peter,
> 
> My opinion about this is as follows:
> * Host drivers should not disable or enable the UIC completion
>    interrupt. Only the UFS controller core driver should do this.
> * The behavior I'm observing is that modifying the
> REG_INTERRUPT_ENABLE
>    register is sufficient to cause the UniPro link to exit the
>    hibernation state. Avoiding this cannot be achieved in a clean way
>    without modifying the UFS controller core driver.
> 
> Thanks,
> 
> Bart.

Hi Bart,

I am confusing,

1. If only UFS controller core driver should do this, 
   What about registers that are not REG_INTERRUPT_ENABLE?
   Since ufshcd_writel has been exported, shouldn't the host 
   driver have the authority to control all Host REGs?
2. Set REG_INTERRUPT_ENABLE only when hibernate exit? 
   If cause the UniPro link to exit, then it should still be correct, 
   just exiting hibernate early?

Thanks.
Peter






[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