lkml.org 
[lkml]   [2021]   [Nov]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [RFC PATCH] soc: mediatek: Add support always on flag
From
Date
On Thu, 2021-11-11 at 14:56 +0100, AngeloGioacchino Del Regno wrote:
> Il 02/11/21 08:20, Chunfeng Yun ha scritto:
> > There is a t-phy shared by PCIe and USB3 on mt8195, if the t-phy is
> > used by PCIe, when power off its mtcmos, need software reset it
> > (workaround way, usually hardware do it, but has an issue on
> > mt8195),
> > but it has side effect to USB2 phy(works with USB3 phy to support
> > USB3.2 Gen1), so add support GENPD_FLAG_ALWAYS_ON flag, and make
> > its
> > power always on;
> > Another reason is that USB3.2 Gen1/2 need keep power always on when
> > support runtime-pm due to hardware limitation until now;
> >
> > Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
> > ---
> > drivers/soc/mediatek/mt8195-pm-domains.h | 2 +-
> > drivers/soc/mediatek/mtk-pm-domains.c | 2 ++
> > drivers/soc/mediatek/mtk-pm-domains.h | 1 +
> > 3 files changed, 4 insertions(+), 1 deletion(-)
> >
>
> Hello Chunfeng,
> what are are the side effects on the USB2 PHY? Can you please expand?
Sorry for later reply, I missed this message.

the side effect on u2 phy is that it will cause u2 phy power off and
cause other issues, e.g. if there is a device plugged in u2 port, it
will disconnect, more over it will not work until reboot platform.

>
> Also, wouldn't it be possible to also reset the USB2 PHY when
> resetting the t-phy
> in order to get it back up and running?
No, the usb driver don't reset or reinit phy after probe;

>
> Moreover, as for the USB3.2 hardware limitation... I would say that
> this is more
> like something that has to be accounted for in the USB driver,
> instead of the PM
> domains driver... unless there's some reason that stops you from
> doing that?
Usb driver itself can't handle this case. but power domain's driver can
handle it easily.

>
> Thanks,
> - Angelo
\
 
 \ /
  Last update: 2021-11-24 07:39    [W:0.220 / U:0.364 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site