Linux-Rockchip Archive on lore.kernel.org
 help / color / mirror / Atom feed
* rk3399: nanopc-t4 usb otg
@ 2019-03-28 11:34 Jack Mitchell
       [not found] ` <a94d70c2-8495-bf91-41c5-bff013ade381-psbXN780rFT10XsdtD+oqA@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Jack Mitchell @ 2019-03-28 11:34 UTC (permalink / raw)
  To: linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi,

Can anyone confirm working operation of USB OTG over a type c phy on an
RK3399 at commit 8c2ffd9174779014c3fe1f96d9dc3641d9175f00 (tag: v5.1-rc2).

I've got a nanopc-t4 here and when I try to load the g_ether driver I
receive

[    6.359280] udc-core: couldn't find an available UDC - added
[g_ether] to list of pending drivers

I've had a look through the dts and all seems to be in order. USB
devices work fine in the host ports and I've confirmed otg mode.

root@rk3399:/sys/kernel/debug/fe800000.dwc3# cat mode
otg

The cable is being detected at plug/unplug as can be seen from

[ 1252.479273] phy phy-ff770000.syscon:usb2-phy@e450.2: charger =
USB_SDP_CHARGER

My defconfig is the standard arm64 as provided with the addition of
CONFIG_USB_ETH=m.

Any information would be helpful, especially if this is working on other
3399 based boards at the mentioned commit.

Regards,
Jack.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: rk3399: nanopc-t4 usb otg
       [not found] ` <a94d70c2-8495-bf91-41c5-bff013ade381-psbXN780rFT10XsdtD+oqA@public.gmane.org>
@ 2019-03-28 12:21   ` Robin Murphy
       [not found]     ` <2458cca9-4209-7658-b4ba-e2067a3fbce5-5wv7dgnIgG8@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Robin Murphy @ 2019-03-28 12:21 UTC (permalink / raw)
  To: Jack Mitchell, linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Hi Jack,

On 28/03/2019 11:34, Jack Mitchell wrote:
> Hi,
> 
> Can anyone confirm working operation of USB OTG over a type c phy on an
> RK3399 at commit 8c2ffd9174779014c3fe1f96d9dc3641d9175f00 (tag: v5.1-rc2).
> 
> I've got a nanopc-t4 here and when I try to load the g_ether driver I
> receive
> 
> [    6.359280] udc-core: couldn't find an available UDC - added
> [g_ether] to list of pending drivers
> 
> I've had a look through the dts and all seems to be in order. USB
> devices work fine in the host ports and I've confirmed otg mode.
> 
> root@rk3399:/sys/kernel/debug/fe800000.dwc3# cat mode
> otg
> 
> The cable is being detected at plug/unplug as can be seen from
> 
> [ 1252.479273] phy phy-ff770000.syscon:usb2-phy@e450.2: charger =
> USB_SDP_CHARGER
> 
> My defconfig is the standard arm64 as provided with the addition of
> CONFIG_USB_ETH=m.
> 
> Any information would be helpful, especially if this is working on other
> 3399 based boards at the mentioned commit.

I've not tried the type C port since I was playing with the initial dts, 
but IIRC not even host mode was working at that point. My vague 
understanding is that there was (and probably still is) some 
communication missing between the fusb302 driver and the dwc3 driver 
(since NanoPC-T4 is using that external chip rather than the RK3399's 
internal type C controller).

It's certainly something I've been meaning to come back and take another 
look at, so I'll try to have a play over the weekend to see how much I 
can make sense of.

Robin.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: rk3399: nanopc-t4 usb otg
       [not found]     ` <2458cca9-4209-7658-b4ba-e2067a3fbce5-5wv7dgnIgG8@public.gmane.org>
@ 2019-03-28 13:32       ` Jack Mitchell
  0 siblings, 0 replies; 3+ messages in thread
From: Jack Mitchell @ 2019-03-28 13:32 UTC (permalink / raw)
  To: Robin Murphy, linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

On 28/03/2019 12:21, Robin Murphy wrote:
> Hi Jack,
>
> On 28/03/2019 11:34, Jack Mitchell wrote:
>> Hi,
>>
>> Can anyone confirm working operation of USB OTG over a type c phy on an
>> RK3399 at commit 8c2ffd9174779014c3fe1f96d9dc3641d9175f00 (tag:
>> v5.1-rc2).
>>
>> I've got a nanopc-t4 here and when I try to load the g_ether driver I
>> receive
>>
>> [    6.359280] udc-core: couldn't find an available UDC - added
>> [g_ether] to list of pending drivers
>>
>> I've had a look through the dts and all seems to be in order. USB
>> devices work fine in the host ports and I've confirmed otg mode.
>>
>> root@rk3399:/sys/kernel/debug/fe800000.dwc3# cat mode
>> otg
>>
>> The cable is being detected at plug/unplug as can be seen from
>>
>> [ 1252.479273] phy phy-ff770000.syscon:usb2-phy@e450.2: charger =
>> USB_SDP_CHARGER
>>
>> My defconfig is the standard arm64 as provided with the addition of
>> CONFIG_USB_ETH=m.
>>
>> Any information would be helpful, especially if this is working on other
>> 3399 based boards at the mentioned commit.
>
> I've not tried the type C port since I was playing with the initial
> dts, but IIRC not even host mode was working at that point. My vague
> understanding is that there was (and probably still is) some
> communication missing between the fusb302 driver and the dwc3 driver
> (since NanoPC-T4 is using that external chip rather than the RK3399's
> internal type C controller).
>
> It's certainly something I've been meaning to come back and take
> another look at, so I'll try to have a play over the weekend to see
> how much I can make sense of.
>
> Robin.

Thanks Robin, and I appreciate you adding the initial dts, I've got a
patch for mainline uboot which I'll try submit soon which gives us a
full mainline stack.

I've seen other discussions around the fusb302 with other boards so I'll
try poking around and see if I can come up with anything.

Thanks for the tip!

Cheers,

Jack.


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-03-28 13:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-28 11:34 rk3399: nanopc-t4 usb otg Jack Mitchell
     [not found] ` <a94d70c2-8495-bf91-41c5-bff013ade381-psbXN780rFT10XsdtD+oqA@public.gmane.org>
2019-03-28 12:21   ` Robin Murphy
     [not found]     ` <2458cca9-4209-7658-b4ba-e2067a3fbce5-5wv7dgnIgG8@public.gmane.org>
2019-03-28 13:32       ` Jack Mitchell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox