Re: Broken USB 3.0 port on Pine Rock64 SBC

From: roboman <roboman7811_at_gmail.com>
Date: Fri, 08 Oct 2021 10:31:38 UTC
Thank-you very much.  That was it.  loader.conf needed
fdt_overlays="rk3328-dwc3".  Once added, everything started working as
expected.  Looks like we should add that detail as a post-install
instruction to https://wiki.freebsd.org/arm/RockChip or include it in
the prebuilt .img for Rock64.
thanks again
Jeff

On Fri, 2021-10-08 at 08:03 +0300, Andriy Gapon wrote:
> On 08/10/2021 05:13, roboman wrote:
> > Goal: Turn a Rock64 SBC into a NFS server.
> > * {root} installed on microSD
> > * NFS share an external USB 3.0 drive.
> > 
> > Works on Linux - Armbian & DietPi
> > 
> > On FreeBSD, I tried:
> > 13-RELEASE
> > 14-CURRENT
> > 
> > In both cases (release/current), the single USB 3.0 port on the
> > Rock64
> > doesn't appear to recognize any drive. The single 3.0 USB port
> > appears
> > disabled. If I plug the external hard drive into either one of the
> > two
> > USB 2 ports - the drive is recognized and shows in dmesg. If I plug
> > into the single USB 3 port, no messages displayed in dmesg. Kernel
> > doesn't recognize anything from UHCI / XHCI on the USB 3.0 port.
> > 
> > Hoping this is potentially a quick fix such as a tuneable in
> > /boot/loader.conf.
> 
> I think that you need rk3328-dwc3 overlay.
> Try putting fdt_overlays="rk3328-dwc3" in your loader.conf.
> 
> > kldstat
> > 
> > Id Refs Address Size Name
> > 1 11 0xffff000000000000 1209308 kernel
> > 2 1 0xffff00000120a000 25808 umodem.ko
> > 3 2 0xffff000001230000 28698 ucom.ko
> > 4 1 0xffff0000cb000000 22000 dwwdt.ko
> > 5 1 0xffff0000cb022000 22000 mac_ntpd.ko
> > 
> > usbconfig
> > 
> > ugen3.1: <Generic OHCI root HUB> at usbus3, cfg=0 md=HOST spd=FULL
> > (12Mbps) pwr=SAVE (0mA)
> > ugen2.1: <Generic EHCI root HUB> at usbus2, cfg=0 md=HOST spd=HIGH
> > (480Mbps) pwr=SAVE (0mA)
> > ugen1.1: <DWCOTG OTG Root HUB> at usbus1, cfg=0 md=HOST spd=HIGH
> > (480Mbps) pwr=SAVE (0mA)
> > 
> > 
> > Drive works fine in either of the two USB 2.0 slots. When plugged
> > into
> > the USB 3 slot, nothing happens. dmesg shows no activity as if I
> > never
> > plugged it in.
> > 
> > dmesg | tail -10
> > 
> > uhub0: 1 port with 1 removable, self powered
> > uhub2: 1 port with 1 removable, self powered
> > uhub1: 1 port with 1 removable, self powered
> > dwwdt0: <Synopsys Designware watchdog timer> mem 0xff1a0000-
> > 0xff1a00ff
> > irq 20 on ofwbus0
> > dwwdt0: cannot find clock
> > device_attach: dwwdt0 attach returned 6
> > lo0: link state changed to UP
> > dwc0: link state changed to DOWN
> > dwc0: link state changed to UP
> > Security policy loaded: MAC/ntpd (mac_ntpd)
> > 
> > ^^^ plug it in, run dmesg again..... no change.
> > 
> > Then I plug it into either one of the two USB 2.0 ports, and it
> > works... dmesg shows:
> > 
> > ugen1.2: <Seagate Expansion Desk> at usbus1
> > umass0 on uhub2
> > umass0: <Seagate Expansion Desk, class 0/0, rev 2.10/9.11, addr 2>
> > on
> > usbus1
> > umass0: SCSI over Bulk-Only; quirks = 0x8100
> > umass0:0:0: Attached to scbus0
> > da0 at umass-sim0 bus 0 scbus0 target 0 lun 0
> > da0: <Seagate Expansion Desk 0911> Fixed Direct Access SPC-4 SCSI
> > device
> > da0: Serial Number NA8FVENP
> > da0: 40.000MB/s transfers
> > da0: 2861588MB (5860533167 512 byte sectors)
> > da0: quirks=0x2<NO_6_BYTE>
> > 
> > Hardware is Rock64 single board computer. Device has one USB 3.0
> > port
> > and two USB 2.0. :seems: like the single USB 3.0 port is registered
> > as
> > USB 1.0.
> > 
> > 
> > 
> 
>