All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marek Vasut <marex@denx.de>
To: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>,
	"linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>
Cc: Amelie Delaunay <amelie.delaunay@st.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Subject: Re: [PATCH] [RFC] usb: dwc2: Run the core connect in dwc2_hcd_init()
Date: Wed, 22 Apr 2020 16:21:41 +0200	[thread overview]
Message-ID: <c59c58e6-648c-bcb3-cbd4-9e78f9021bb7@denx.de> (raw)
In-Reply-To: <8de7047f-4d49-349b-983a-31c4ab66562f@synopsys.com>

On 4/22/20 3:45 PM, Minas Harutyunyan wrote:
> Hi,

Hi,

> On 4/20/2020 4:09 PM, Marek Vasut wrote:
>> On 4/17/20 11:00 AM, Minas Harutyunyan wrote:
>>> Hi,
>>
>> Hi,
>>
>>> On 4/16/2020 6:31 PM, Marek Vasut wrote:
>>>> On 4/16/20 3:37 PM, Minas Harutyunyan wrote:
>>>
> Looks like I found cause of issue. According to your logs GINTMSK set 
> host masks, at least USB Reset not unmasked which required for device mode.
> Why it happen. During dwc2 driver probe first initialized device part 
> then host part. Because of your g_zero is builtin in Kernel it 
> immediately bound to dwc2, as result called main device initialization 
> dwc2_hsotg_core_init_disconnected() which at least set GINTMSK for 
> device mode. After gadget side initialization done, dwc2 go to host 
> initialization hcd_init() and reset GINTMSK to host masks. In this case 
> connecting cable to host will ignore USBReset and stacked. Your initial 
> patch including call to function dwc2_hsotg_core_init_disconnected(), 
> which allow to restore device mode masks and on cable connect start 
> working as device.
> First to check my assumption, please build g_zero as module and modprobe 
> it after dwc2 modprobe will be done. If the tests will pass then will 
> think how resolve issue with builtin functions.

Using g_zero as a module seems to work too, so please proceed.

  reply	other threads:[~2020-04-22 14:21 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-13 14:31 [PATCH] [RFC] usb: dwc2: Run the core connect in dwc2_hcd_init() Marek Vasut
2020-04-13 14:45 ` Minas Harutyunyan
2020-04-13 14:54   ` Marek Vasut
2020-04-13 15:27     ` Minas Harutyunyan
2020-04-13 17:00       ` Marek Vasut
2020-04-14  7:14         ` Minas Harutyunyan
2020-04-14 12:18           ` Marek Vasut
2020-04-15  8:37             ` Minas Harutyunyan
2020-04-15 14:55               ` Marek Vasut
2020-04-15 15:10                 ` Minas Harutyunyan
2020-04-16  9:46                   ` Marek Vasut
2020-04-16 13:37                     ` Minas Harutyunyan
2020-04-16 14:31                       ` Marek Vasut
2020-04-17  9:00                         ` Minas Harutyunyan
2020-04-20 12:09                           ` Marek Vasut
2020-04-22 13:45                             ` Minas Harutyunyan
2020-04-22 14:21                               ` Marek Vasut [this message]
2020-05-14  0:10                                 ` Marek Vasut
2020-05-15  7:41                                   ` Minas Harutyunyan
2020-05-27  6:17                                     ` Minas Harutyunyan
2020-05-28 22:35                                       ` Marek Vasut

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=c59c58e6-648c-bcb3-cbd4-9e78f9021bb7@denx.de \
    --to=marex@denx.de \
    --cc=Minas.Harutyunyan@synopsys.com \
    --cc=amelie.delaunay@st.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=manivannan.sadhasivam@linaro.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 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.