[U-Boot] [linux-sunxi] [PATCH 0/2] sunxi: A64: enable first USB port on Pine64 boards

André Przywara andre.przywara at arm.com
Sat May 18 01:28:39 UTC 2019


On 17/05/2019 19:41, André Przywara wrote:
> On 17/05/2019 19:15, Vasily Khoruzhick wrote:
>> On Wed, May 15, 2019 at 5:46 PM Andre Przywara <andre.przywara at arm.com> wrote:
>>>
>>> Since the beginning the upper USB port on Pine64 boards (Pine64+, SoPine
>>> baseboard, Pine64-LTS, Pinebook) was not working under U-Boot.
>>> This is due to the PHY for those pins being shared with the OTG
>>> controller, which we didn't even enable for those boards. Also the PHY
>>> code was always connecting the port pins to the OTG controller.
>>>
>>> These two patches fix this, so the upper USB port on said boards can
>>> be used within U-Boot. This allows to use an USB keyboard alongside
>>> an USB flash drive, for instance to install operating systems using
>>> UEFI.
>>
>> Can you also add Pinebook here? It has the same issue.
> 
> Do you mean to change the -pinebook.dts in patch 2/2? Actually the
> Pinebook already had this change (from the very beginning), so it should
> work with just patch 1/2.
> My Pinebook is a somewhat sorry state, something seems fishy with the
> USB hub (keyboard doesn't work, although I have used it in U-Boot on
> another model). I will have a look again, but can you say whether this
> works for you with just patch 1?

I had a look, I guess it's the VBUS power supply missing. Can you type
the following on the U-Boot prompt to enable GPIO0-LDO?
=> mw.l 0x1f0341c 0x01
=> mw.l 0x1f03410 0x90
=> mw.l 0x1f03400 0x80
=> usb reset

And see if that fixes things for you?
My Pinebook reboots at this point (also does in Linux when the AXP
driver comes along that power rail).
If that works for you, I will send an ATF patch.

Cheers,
Andre.

>>>
>>> Andre Przywara (2):
>>>   sunxi: USB PHY: Support shared PHY 0
>>>   sunxi: Pine64: DTS: enable USB PHY 0 for HCI0
>>>
>>>  arch/arm/dts/sun50i-a64-pine64.dts           | 5 ++++-
>>>  arch/arm/dts/sun50i-a64-sopine-baseboard.dts | 5 ++++-
>>>  drivers/phy/allwinner/phy-sun4i-usb.c        | 8 +++++++-
>>>  3 files changed, 15 insertions(+), 3 deletions(-)
>>>
>>> --
>>> 2.14.5
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe at googlegroups.com.
>>> To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190516004609.25304-1-andre.przywara%40arm.com.
>>> For more options, visit https://groups.google.com/d/optout.
> 



More information about the U-Boot mailing list