Re: 回复: [PATCH 1/1] usb: host: xhci-plat: keep runtime active when remove host

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

 



On 20-05-13 14:45:42, Jun Li wrote:
>
> ...
> > Would it make sense to change xhci_plat_remove() to
> 
> 
> 
> > xhci_plat_remove()
> 
> >   pm_runtime_disable()
> 
> >   <remove and put both hcd's>
> 
> >   pm_runtime_set_suspended()
> 
> 
> 
> > or possibly wrapping the remove in a runtime get/put:
> 
> > xhci_plat_remove()
> 
> >  pm_runtime_get_noresume()
> 
> >   pm_runtime_disable()
> 
>  >  <remove and put both hcd's>
> 
>  >  pm_runtime_set_suspended()
> 
>  >  pm_runtime_put_noidle()
> 
> I think it's better to keep runtime active during driver removal,
> how about this:
> 
> pm_runtime_get_sync()
> <remove and put both hcd's>
> pm_runtime_disable()
> pm_runtime_put_noidle()
> pm_runtime_set_suspended()
> 

I think it is more reasonable since for some DRD controllers if
DRD core is suspended, access the xHCI register (eg, we remove
xhci-plat-hcd module at the time) may hang the system. Alan &
Mathias, what's your opinion?

-- 

Thanks,
Peter Chen




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux