public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Sandeep Maheswaram <sanm@codeaurora.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Andy Gross <agross@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>,
	Felipe Balbi <balbi@kernel.org>,
	Stephen Boyd <swboyd@chromium.org>,
	Doug Anderson <dianders@chromium.org>,
	Matthias Kaehlcke <mka@chromium.org>,
	Mathias Nyman <mathias.nyman@intel.com>,
	linux-arm-msm@vger.kernel.org, linux-usb@vger.kernel.org,
	linux-kernel@vger.kernel.org, ppratap@codeaurora.org,
	pkondeti@codeaurora.org
Subject: Re: [PATCH] usb: dwc: host: add xhci_plat_priv quirk XHCI_SKIP_PHY_INIT
Date: Thu, 14 Oct 2021 11:10:58 +0530	[thread overview]
Message-ID: <09477c8a-f242-202c-8ead-eebc4f1cdd7d@codeaurora.org> (raw)
In-Reply-To: <YWU6IZwm2T24ONW2@kroah.com>

Hi,

On 10/12/2021 1:02 PM, Greg Kroah-Hartman wrote:
> On Mon, Oct 11, 2021 at 03:31:57PM +0530, Sandeep Maheswaram wrote:
>> dwc3 manages PHY by own DRD driver, so skip the management by
>> HCD core.
>> During runtime suspend phy was not getting suspend because
>> runtime_usage value is 2.
>>
>> Signed-off-by: Sandeep Maheswaram <sanm@codeaurora.org>
>> ---
>>   drivers/usb/dwc3/host.c | 12 ++++++++++++
>>   1 file changed, 12 insertions(+)
>>
>> diff --git a/drivers/usb/dwc3/host.c b/drivers/usb/dwc3/host.c
>> index f29a264..0921f05 100644
>> --- a/drivers/usb/dwc3/host.c
>> +++ b/drivers/usb/dwc3/host.c
>> @@ -11,6 +11,11 @@
>>   #include <linux/platform_device.h>
>>   
>>   #include "core.h"
>> +#include "../host/xhci-plat.h"
> Why are you tying the dwc3 driver to the xhci driver?
>
Can we add a  property usb-skip-phy-init  in drivers/usb/dwc3/host.c

props[prop_idx++] = PROPERTY_ENTRY_BOOL("usb-skip-phy-init");

and set the quirk like this in xhci-plat.c

if (device_property_read_bool(tmpdev, "usb-skip-phy-init"))
             xhci->quirks |= XHCI_SKIP_PHY_INIT;

as below

if (device_property_read_bool(tmpdev, "usb2-lpm-disable"))
             xhci->quirks |= XHCI_HW_LPM_DISABLE;

  if (device_property_read_bool(tmpdev, "usb3-lpm-capable"))
             xhci->quirks |= XHCI_LPM_SUPPORT;



>> +
>> +static const struct xhci_plat_priv xhci_plat_dwc3_xhci = {
>> +	.quirks = XHCI_SKIP_PHY_INIT,
> If these quirks are now "global", they should go into a
> include/linux/usb/ .h file, right?
>
> thanks,
>
> greg k-h

      reply	other threads:[~2021-10-14  5:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-11 10:01 [PATCH] usb: dwc: host: add xhci_plat_priv quirk XHCI_SKIP_PHY_INIT Sandeep Maheswaram
2021-10-12  7:32 ` Greg Kroah-Hartman
2021-10-14  5:40   ` Sandeep Maheswaram [this message]

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=09477c8a-f242-202c-8ead-eebc4f1cdd7d@codeaurora.org \
    --to=sanm@codeaurora.org \
    --cc=agross@kernel.org \
    --cc=balbi@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=dianders@chromium.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mathias.nyman@intel.com \
    --cc=mka@chromium.org \
    --cc=pkondeti@codeaurora.org \
    --cc=ppratap@codeaurora.org \
    --cc=swboyd@chromium.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox