From: Mathias Nyman <mathias.nyman@linux.intel.com>
To: Surong Pang <surong.pang@gmail.com>,
mathias.nyman@intel.com, gregkh@linuxfoundation.org
Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH V1 1/1] usb/host: Let usb phy shutdown later
Date: Tue, 19 Apr 2022 17:45:49 +0300 [thread overview]
Message-ID: <610871b2-1707-dfba-868f-4ddecc4d554d@linux.intel.com> (raw)
In-Reply-To: <20220412122524.26966-1-surong.pang@gmail.com>
On 12.4.2022 15.25, Surong Pang wrote:
> From: Surong Pang <surong.pang@unisoc.com>
>
> Let usb phy shutdown later in xhci_plat_remove function.
> Some phy driver doesn't divide 3.0/2.0 very clear.
> If calls usb_phy_shutdown earlier than usb_remove_hcd(hcd),
> It will case 10s cmd timeout issue.
>
> Call usb phy shutdown later has better compatibility.
>
> Signed-off-by: Surong Pang <surong.pang@unisoc.com>
> ---
> drivers/usb/host/xhci-plat.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c
> index 649ffd861b44..dc73a81cbe9b 100644
> --- a/drivers/usb/host/xhci-plat.c
> +++ b/drivers/usb/host/xhci-plat.c
> @@ -390,7 +390,6 @@ static int xhci_plat_remove(struct platform_device *dev)
>
> usb_remove_hcd(shared_hcd);
> xhci->shared_hcd = NULL;
> - usb_phy_shutdown(hcd->usb_phy);
>
> usb_remove_hcd(hcd);
> usb_put_hcd(shared_hcd);
> @@ -398,6 +397,7 @@ static int xhci_plat_remove(struct platform_device *dev)
> clk_disable_unprepare(clk);
> clk_disable_unprepare(reg_clk);
> usb_put_hcd(hcd);
> + usb_phy_shutdown(hcd->usb_phy);
hcd might be freed already here.
maybe call usb_phy_shutdown(hcd->usb_phy) before usb_put_hcd(hcd)
-Mathias
next prev parent reply other threads:[~2022-04-19 14:44 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-12 12:25 [PATCH V1 1/1] usb/host: Let usb phy shutdown later Surong Pang
2022-04-19 14:45 ` Mathias Nyman [this message]
2022-04-22 2:10 ` surong pang
2022-04-22 7:53 ` Mathias Nyman
2022-04-22 10:43 ` surong pang
2022-04-22 11:59 ` Mathias Nyman
2022-04-24 1:57 ` [PATCH V2] " Surong Pang
2022-04-26 11:53 ` Greg KH
[not found] ` <CAEDbmAQmYQdMNY8sANnSuauBcsemrV1MFR3bB83JJ7cHNdWGmA@mail.gmail.com>
2022-04-28 6:31 ` Greg KH
2022-04-29 1:54 ` [PATCH V2] xhci-plat: " surong pang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=610871b2-1707-dfba-868f-4ddecc4d554d@linux.intel.com \
--to=mathias.nyman@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mathias.nyman@intel.com \
--cc=surong.pang@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.