USB3.0 not working on Pine Rock64

This is for ARMv8 based devices

USB3.0 not working on Pine Rock64

Postby rontant » Sat Jun 09, 2018 1:54 am

First of all, let me thank Arch Linux Arm developers and contributors who have made Pine Rock64 SBC officially supported. The installation steps outlined here https://archlinuxarm.org/platforms/armv ... hip/rock64 are very concise and clear. I was able to boot up my Rock64 with Arch Linux ARM in less than 20 minutes. Great job team!

Unfortunately, I found that USB3.0 is not (yet) working. When I plugged either a powered USB3 hub or a powered USB 3 drive into the Rock64 USB3 port, the devices are not detectable at all by Arch Linux Arm. They can only be detected when I moved them to the USB2 port. USB3 devices are running fine on UBUNTU, DEBIAN, and ARMBIAN (Not sure about Dietpi).

Having said that, I think it is only right to let users know in the Arch Linux ARM Rock64 Wiki page that USB 3 is not yet working so that time will not be wasted. As of now, the Wiki page only mentioned about Rock 64 UART and changing the MAC Address.

So, again thank you for supporting Pine Rock64.
Rock 64, Odroid XU4, Raspberry Pi 3, Pogo 4, Pogo Pink E02, Goflex
rontant
 
Posts: 25
Joined: Sat May 27, 2017 1:10 am
Location: Singapore

Re: USB3.0 not working on Pine Rock64

Postby rhradec » Thu Jul 12, 2018 6:28 am

I'm having the same issue, but I've found a solution here:
https://forum.pine64.org/showthread.php ... light=usb3

basically, the user "decontainerized" in the Pine64 forum had the brilliant idea of replacing arch's /boot/dtbs/rockchip/rk3328-rock64.dtb file with the one found in the latest ayufan-rock64 debian kernel. (in the forum he mentions "rk3328-arm64.dtb", but it's rk3328-rock64.dtb)

Essentially I donwload the latest linux-image-4.18.0-rc3-1042-ayufan-gc1c3de67a7c1_4.18.0-rc3-1042-ayufan_arm64.deb from the github release page (https://github.com/ayufan-rock64/linux- ... l/releases), uncompressed the .deb using "ar x <.deb>", then extracted the data.tar.xz, and a quick "find ./extracted_data_tar_xz/ -name rk3328-arm64.dtb" found it in ./extracted_data_tar_xz/usr/lib/linux-image-4.18.0-rc3-1042-ayufan-gc1c3de67a7c1/rockchip/rk3328-rock64.dtb.

after that, I just copied the extracted rk3328-rock64.dtb over arch's /boot/dtbs/rockchip/rk3328-rock64.dtb, and after a reboot, my USB 3.0 drives are working 100%! (at proper USB 3.0 speed!!)

So, I'm sure there's something in the kernel config that needs to be set in Arch's kernel the same way as in Debian (and I think it's a matter of comparing Arch's kernel config with the one in https://github.com/ayufan-rock64/linux-mainline-kernel/).

anyhow, this workaround worked wonders for me!! Hope it will help others out there!!

cheers...
-H
rhradec
 
Posts: 1
Joined: Thu Jul 12, 2018 6:05 am

Re: USB3.0 not working on Pine Rock64

Postby summers » Thu Jul 12, 2018 7:56 am

Did rise half an eyebrow at this.

The device tree is really just the description of the hardware in a machine. Now that should be monolithic, e.g. its defined in hardware. Now given that device tree when written really shouldn't change for that hardware, I kind of feel that the latest device tree should just be set up in the linux kernel, and thats the end of it no fiddling.

Now there are occasional deice tree hasssles, e.g. the odroid c2 had eMMC timing issues, eMMC speed limits were set up in the device tree. Some odroids would work at full speed, but some wouldn't. So what did people do whne they couldn't run at full speed. What most of us did was have uboot rewrite the device tree setting after loading it. That kind of feeled the natural solution. [Although eventually they just updatated the linux kernel device tree, such that all odroid c2 owners had slower eMMC, and that worked for everyone].

So what I'd ask, is what is different between the device trees. If the one that usb3 works on, just has usb3 defined in the device tree, I'd be tempted to push for that change to be made in the linux kernel.
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm

Re: USB3.0 not working on Pine Rock64

Postby ShapeShifter499 » Wed Jul 18, 2018 9:53 pm

ayufan confirmed here that all is needed is a DTS change to enable USB 3.0 https://github.com/rockchip-linux/kernel/issues/83

Would someone be willing to enable it?
ShapeShifter499
 
Posts: 34
Joined: Mon Nov 25, 2013 12:24 pm

Re: USB3.0 not working on Pine Rock64

Postby summers » Thu Jul 19, 2018 9:58 am

As said before, someone needs to work out what needs to be added to the device tree. Use "dtc" to turn the "dtb" into "dts" then see what needs to be added to the main line device tree.

Then set up a patch and email to the maintainer:

https://github.com/torvalds/linux/blob/master/MAINTAINERS
$this->bbcode_second_pass_code('', 'ARM/Rockchip SoC support
M: Heiko Stuebner <heiko@sntech.de>
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
L: linux-rockchip@lists.infradead.org
T: git git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git
S: Maintained
F: arch/arm/boot/dts/rk3*')

Now only people that can do this are people with the hardware that have access to the dtb. The easiest way to get it into arch, is get the change made in mainline, and it will propagate down to arch eventually.
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm

Re: USB3.0 not working on Pine Rock64

Postby kmihelich » Thu Jul 19, 2018 6:24 pm

I've added Heiko's patches for this from last December, which seem to have fallen off the radar. They've been added to the RC kernel.
Arch Linux ARM exists and continues to grow through community support, please donate today!
kmihelich
Developer
 
Posts: 1133
Joined: Tue Jul 20, 2010 6:55 am
Location: aka leming #archlinuxarm

Re: USB3.0 not working on Pine Rock64

Postby summers » Fri Jul 20, 2018 9:10 am

Yes strange, it isn't in his tree that linus will pull : https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/tree/arch/arm64/boot/dts/rockchip

Does suggest that people that have tested the patch, should reply to Heiko withe a "Tested By:" flag. Hopefully that will prompt him to pull them into his kernel, and from there it will go mainline.
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm

Re: USB3.0 not working on Pine Rock64

Postby ShapeShifter499 » Sat Jul 21, 2018 5:58 am

$this->bbcode_second_pass_quote('kmihelich', 'I')'ve added Heiko's patches for this from last December, which seem to have fallen off the radar. They've been added to the RC kernel.


This will be in the 'linux-aarch64-rc' package for Arch Linux ARM in a few?
ShapeShifter499
 
Posts: 34
Joined: Mon Nov 25, 2013 12:24 pm

Re: USB3.0 not working on Pine Rock64

Postby summers » Sat Jul 21, 2018 9:54 am

Yes you can see its patches 3 and 4 here https://archlinuxarm.org/packages/aarch64/linux-aarch64-rc/files. Kevin rerolled the package at Thu Jul 19 00:30:48 2018 UTC, so it should be good once it reaches the mirrors. So when you upgrade check you are on release rc5-2.
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm

Re: USB3.0 not working on Pine Rock64

Postby ShapeShifter499 » Mon Jul 30, 2018 3:09 am

$this->bbcode_second_pass_quote('kmihelich', 'I')'ve added Heiko's patches for this from last December, which seem to have fallen off the radar. They've been added to the RC kernel.


$this->bbcode_second_pass_quote('summers', 'Y')es you can see its patches 3 and 4 here https://archlinuxarm.org/packages/aarch64/linux-aarch64-rc/files. Kevin rerolled the package at Thu Jul 19 00:30:48 2018 UTC, so it should be good once it reaches the mirrors. So when you upgrade check you are on release rc5-2.


I just updated and a few hours later I see this in my dmesg log. It looks like the USB 3.0 controller had issues but I'm not 100% sure.

$this->bbcode_second_pass_code('', '[Jul29 18:07] usb 5-1.3: reset SuperSpeed Gen 1 USB device number 4 using xhci-hcd
[Jul29 18:17] usb 5-1.2: reset SuperSpeed Gen 1 USB device number 3 using xhci-hcd
[Jul29 18:32] usb 5-1.2: reset SuperSpeed Gen 1 USB device number 3 using xhci-hcd
[ +0.030627] sd 0:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[ +0.000737] sd 0:0:0:0: [sdb] tag#0 CDB: Read(16) 88 00 00 00 00 00 c8 80 5e 10 00 00 00 f8 00 00
[ +0.000775] print_req_error: I/O error, dev sdb, sector 3363855888
[Jul29 18:37] usb 5-1.2: reset SuperSpeed Gen 1 USB device number 3 using xhci-hcd
[ +0.030621] sd 0:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[ +0.000737] sd 0:0:0:0: [sdb] tag#0 CDB: Read(16) 88 00 00 00 00 00 fd 80 1e 18 00 00 00 e8 00 00
[ +0.000775] print_req_error: I/O error, dev sdb, sector 4253031960
[Jul29 18:45] usb 5-1.2: reset SuperSpeed Gen 1 USB device number 3 using xhci-hcd
[Jul29 18:51] usb 5-1.3: reset SuperSpeed Gen 1 USB device number 4 using xhci-hcd
[Jul29 19:50] usb 5-1.2: reset SuperSpeed Gen 1 USB device number 3 using xhci-hcd
[Jul29 19:51] xhci-hcd xhci-hcd.0.auto: xHCI host not responding to stop endpoint command.
[ +0.000722] xhci-hcd xhci-hcd.0.auto: xHCI host controller not responding, assume dead
[ +0.000768] hub 5-1:1.0: hub_ext_port_status failed (err = -22)
[ +0.000033] usb 5-1.4: cmd cmplt err -108
[ +0.000491] usb 5-1-port2: cannot reset (err = -22)
[ +0.000348] usb 5-1.4: cmd cmplt err -108
[ +0.000423] usb 5-1-port2: cannot reset (err = -22)
[ +0.000353] xhci-hcd xhci-hcd.0.auto: HC died; cleaning up
[ +0.000420] usb 5-1-port2: cannot reset (err = -22)
[ +0.000518] usb 4-1: USB disconnect, device number 2
[ +0.000410] usb 5-1.2: USB disconnect, device number 3
[ +0.001351] usb 5-1: USB disconnect, device number 2
[ +0.001152] sd 0:0:0:0: [sdb] Synchronizing SCSI cache
[ +0.003028] xhci-hcd xhci-hcd.0.auto: xHCI host not responding to stop endpoint command.
[ +0.020067] sd 0:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK
[ +0.000774] sd 0:0:0:0: [sdb] tag#0 CDB: Read(16) 88 00 00 00 00 01 72 5f 58 00 00 00 01 00 00 00
[ +0.000775] print_req_error: I/O error, dev sdb, sector 6213818368
[ +0.000652] sd 0:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK
[ +0.000775] sd 0:0:0:0: [sdb] tag#0 CDB: Write(16) 8a 00 00 00 00 01 71 e1 19 00 00 00 01 00 00 00
[ +0.000786] print_req_error: I/O error, dev sdb, sector 6205544704
[ +0.000568] EXT4-fs warning (device dm-1): ext4_end_bio:323: I/O error 10 writing to inode 21307152 (offset 536477696 size 131072 starting block 775692320)
[ +0.000491] EXT4-fs warning (device dm-1): ext4_end_bio:323: I/O error 10 writing to inode 21307152 (offset 144703488 size 131072 starting block 775593248)
[ +0.000728] Buffer I/O error on device dm-1, logical block 775692320
[ +0.000017] Buffer I/O error on device dm-1, logical block 775692321
[ +0.001208] Buffer I/O error on device dm-1, logical block 775593248
[ +0.000550] Buffer I/O error on device dm-1, logical block 775692322
[ +0.000556] Buffer I/O error on device dm-1, logical block 775593249
[ +0.000547] Buffer I/O error on device dm-1, logical block 775692323
[ +0.000551] Buffer I/O error on device dm-1, logical block 775593250
[ +0.000551] Buffer I/O error on device dm-1, logical block 775692324
[ +0.000594] Buffer I/O error on device dm-1, logical block 775593251
[ +0.000551] Buffer I/O error on device dm-1, logical block 775692325
')
ShapeShifter499
 
Posts: 34
Joined: Mon Nov 25, 2013 12:24 pm
Top

Next

Return to ARMv8 Devices

Who is online

Users browsing this forum: No registered users and 6 guests