sbeaugrand
-
Posts
7 -
Joined
-
Last visited
Content Type
Forums
Store
Crowdfunding
Applications
Events
Community Map
Posts posted by sbeaugrand
-
-
Two good news :
- Rockpi S is supported again
- There is a bugfix to get gpio values via sysfs and libgpiod
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git/commit/drivers/gpio/gpio-rockchip.c?h=linux-5.19.y&id=a11544efbcf5caa1c6e7ccc8e0f3bf1b63c9b500
Kernel must be >= 5.19.17, or wait the next release of armbian rockpi s.
I have two Rockpi S without SDNAND and one refuse to boot on SDcard.
If you have the same problem :sed -i 's/^IDBLOADER_BLOB/#IDBLOADER_BLOB/' config/sources/families/rockpis.conf touch .ignore_changes sudo rm ./cache/sources/u-boot/v2022.04/idbloader.bin ./compile.sh ...
If you use armbian 22.11, spi2 is disabled, see :
https://github.com/armbian/build/commit/d3a3afe3850861ceaeb44f3631251c764a28cd43
For the moment i don't use spi but this overlay :overlay-rockpi-s.dts
You can replace "disabled" by "okay", and :sudo /usr/sbin/armbian-add-overlay overlay-rockpi-s.dts && sudo reboot
In this overlay, gpio-line-names is usefull with libgpiod (sysfs is deprecated
https://www.thegoodpenguin.co.uk/blog/stop-using-sys-class-gpio-its-deprecated/)
to have the standard gpio pin between pin1 to pin24. I have equivalent overlays
for Orange Pi Zero and Nanopi Neo and access pins with their physical pin number. -
Rockpi S is not supported and the last release is on 26-Aug-2021.
I have tested armbian 22.08 with bullseye and kernel 5.18 (edge), and it works. My usage: ethernet, usb, audio dac lineout, ir, i2c, spi, gpio.
With kernel 5.15 (current), module snd_soc_rk3308 is loaded, but there is no audio device.
How to build on debian with cross compilers installed :
df -h . # 6,5G needed git clone https://github.com/armbian/build.git armbian-build cd armbian-build sudo apt install debootstrap sudo modprobe loop systemd-run -p CPUQuota=$((`nproc`*50))% --scope bash -c './compile.sh BOARD=rockpi-s BRANCH=edge BUILD_MINIMAL=yes BUILD_DESKTOP=no KERNEL_ONLY=no KERNEL_CONFIGURE=no CLEAN_LEVEL=, RELEASE=bullseye SKIP_EXTERNAL_TOOLCHAINS=yes' cd output/images ls -l Armbian_22.08.0-trunk_Rockpi-s_bullseye_edge_5.18.5_minimal.img -rw-rw-r-- 1 root sudo 1061158912 19 juin 21:16 Armbian_22.08.0-trunk_Rockpi-s_bullseye_edge_5.18.5_minimal.img
-
Same thing for me.
There are no merge from master to v20.11 yet : https://github.com/armbian/build/commits/v20.11
-
Spoiler
git clone https://github.com/armbian/build.git armbian-build
cd armbian-build
./compile.sh BOARD=rockpi-s BRANCH=current KERNEL_ONLY=yes KERNEL_CONFIGURE=no
export user=xxx
export host=xxx
scp output/debs/linux-image-current-rockchip64_21.02.0-trunk_arm64.deb $user@$host:/home/$user/
scp output/debs/linux-dtb-current-rockchip64_21.02.0-trunk_arm64.deb $user@$host:/home/$user/
ssh $user@$host
sudo dpkg -i linux-image-current-rockchip64_21.02.0-trunk_arm64.deb
sudo dpkg -i linux-dtb-current-rockchip64_21.02.0-trunk_arm64.deb
sudo reboot
lsusb
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 002: ID 152d:2329 JMicron Technology Corp. / JMicron USA Technology Corp. JM20329 SATA Bridge
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hubSuper ! Thank you very much !
-
I forgot this:
Spoiler&u2phy {
status = "okay";
u2phy_host: host-port {
phy-supply = <&vcc5v0_otg>;
status = "okay";
};
u2phy_otg: otg-port {
vbus-supply = <&vcc5v0_otg>;
status = "okay";
};
};And I fixed this : cp ../armbian-build/config/kernel/linux-rockchip64-current.config .config
But again no device found.Spoilerdmesg | grep 'usb\|ehci'
[ 0.000000] Kernel command line: root=UUID=a1255f02-b778-4121-85dd-b01a09bf801b rootwait rootfstype=ext4 console=ttyS0,1500000 consoleblank=0 loglevel=1 ubootpart=408ad6cd-01 usb-storage.quirks=0x2537:0x1066:u,0x2537:0x1068:u swiotlb=1024 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1
[ 1.369267] usbcore: registered new interface driver usbfs
[ 1.369337] usbcore: registered new interface driver hub
[ 1.369483] usbcore: registered new device driver usb
[ 2.900246] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 2.900303] ehci-pci: EHCI PCI platform driver
[ 2.900365] ehci-platform: EHCI generic platform driver
[ 2.901948] usbcore: registered new interface driver usb-storage
[ 2.995777] usbcore: registered new interface driver usbhid
[ 2.995784] usbhid: USB HID core driver
lsusb | wc -l
0I can use armbian with kernel 4.4 for the moment, but I must compile the gpio-ir-recv module, it works
and I have a lot of lines "rc rc0: IR event FIFO is full!" in syslog. With armbian and kernel 5.9 this
module is present and works without these lines.
Perhaps a little effort to fix usb may be better.
-
For usb, I try this:
Spoilergit clone https://github.com/armbian/build.git armbian-build git clone https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git -b linux-5.9.y armbian-kernel # optionnal: tar cf armbian-build.tar armbian-build/.git # optionnal: tar cf armbian-kernel.tar armbian-kernel/.git vi armbian-build/patch/kernel/rockchip64-current/rockpis-0023-dts-usb.patch
--- arch/arm64/boot/dts/rockchip/rk3308-rock-pi-s.dts +++ arch/arm64/boot/dts/rockchip/rk3308-rock-pi-s.dts @@ -331,3 +331,16 @@ pinctrl-0 = <&uart4_xfer &uart4_rts &uart4_cts>; status = "okay"; }; + +&usb20_otg { + dr_mode = "otg"; + status = "okay"; +}; + +&usb_host0_ehci { + status = "okay"; +}; + +&usb_host0_ohci{ + status = "okay"; +}; --- arch/arm64/boot/dts/rockchip/rk3308.dtsi +++ arch/arm64/boot/dts/rockchip/rk3308.dtsi @@ -244,6 +244,43 @@ status = "disabled"; }; + usb2phy_grf: syscon@ff008000 { + compatible = "rockchip,rk3308-usb2phy-grf", "syscon", + "simple-mfd"; + reg = <0x0 0xff008000 0x0 0x4000>; + #address-cells = <1>; + #size-cells = <1>; + + u2phy: usb2-phy@100 { + compatible = "rockchip,rk3308-usb2phy"; + reg = <0x100 0x10>; + clocks = <&cru SCLK_USBPHY_REF>; + clock-names = "phyclk"; + #clock-cells = <0>; + assigned-clocks = <&cru USB480M>; + assigned-clock-parents = <&u2phy>; + clock-output-names = "usb480m_phy"; + status = "disabled"; + + u2phy_otg: otg-port { + #phy-cells = <0>; + interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "otg-bvalid", "otg-id", + "linestate"; + status = "disabled"; + }; + + u2phy_host: host-port { + #phy-cells = <0>; + interrupts = <GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>; + interrupt-names = "linestate"; + status = "disabled"; + }; + }; + }; + wdt: watchdog@ff080000 { compatible = "snps,dw-wdt"; reg = <0x0 0xff080000 0x0 0x100>; @@ -763,6 +800,44 @@ status = "disabled"; }; + usb20_otg: usb@ff400000 { + compatible = "rockchip,rk3066-usb", "snps,dwc2"; + reg = <0x0 0xff400000 0x0 0x40000>; + interrupts = <GIC_SPI 66 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&cru HCLK_OTG>; + clock-names = "otg"; + dr_mode = "otg"; + g-np-tx-fifo-size = <16>; + g-rx-fifo-size = <280>; + g-tx-fifo-size = <256 128 128 64 32 16>; + g-use-dma; + phys = <&u2phy_otg>; + phy-names = "usb2-phy"; + status = "disabled"; + }; + + usb_host0_ehci: usb@ff440000 { + compatible = "generic-ehci"; + reg = <0x0 0xff440000 0x0 0x10000>; + interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&cru HCLK_HOST>, <&cru HCLK_HOST_ARB>, <&u2phy>; + clock-names = "usbhost", "arbiter", "utmi"; + phys = <&u2phy_host>; + phy-names = "usb"; + status = "disabled"; + }; + + usb_host0_ohci: usb@ff450000 { + compatible = "generic-ohci"; + reg = <0x0 0xff450000 0x0 0x10000>; + interrupts = <GIC_SPI 72 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&cru HCLK_HOST>, <&cru HCLK_HOST_ARB>, <&u2phy>; + clock-names = "usbhost", "arbiter", "utmi"; + phys = <&u2phy_host>; + phy-names = "usb"; + status = "disabled"; + }; + sdmmc: mmc@ff480000 { compatible = "rockchip,rk3308-dw-mshc", "rockchip,rk3288-dw-mshc"; reg = <0x0 0xff480000 0x0 0x4000>;
cd armbian-kernel find ../armbian-build/patch/kernel/rockchip64-current -type f -name '*.patch' -print0 | sort -z | xargs -t -0 -n 1 patch -p1 -N -i cp ../armbian-build/config/kernel/linux-rockpis-dev.config .config export ARCH=arm64 export CROSS_COMPILE=/usr/bin/aarch64-linux-gnu- make oldconfig make V=1 dtbs export user=xxx export host=xxx scp arch/arm64/boot/dts/rockchip/rk3308-rock-pi-s.dtb $user@$host:/home/$user/ ssh $user@$host sudo cp -b rk3308-rock-pi-s.dtb /boot/dtb/rockchip/
But :
dmesg | grep usb [ 0.000000] Kernel command line: root=UUID=a1255f02-b778-4121-85dd-b01a09bf801b rootwait rootfstype=ext4 console=ttyS0,1500000 consoleblank=0 loglevel=1 ubootpart=408ad6cd-01 usb-storage.quirks=0x2537:0x1066:u,0x2537:0x1068:u swiotlb=1024 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1 [ 1.365523] usbcore: registered new interface driver usbfs [ 1.365593] usbcore: registered new interface driver hub [ 1.365865] usbcore: registered new device driver usb [ 2.900775] usbcore: registered new interface driver usb-storage [ 2.995068] usbcore: registered new interface driver usbhid [ 2.995074] usbhid: USB HID core driver lsusb | wc -l 0
On radxa image I have :
Spoilerdmesg | grep usb [ 0.156638] usbcore: registered new interface driver usbfs [ 0.156744] usbcore: registered new interface driver hub [ 0.156883] usbcore: registered new device driver usb [ 0.944414] ff400000.usb supply vusb_d not found, using dummy regulator [ 0.945113] ff400000.usb supply vusb_a not found, using dummy regulator [ 1.061993] dwc2 ff400000.usb: EPs: 10, dedicated fifos, 972 entries in SPRAM [ 1.063239] dwc2 ff400000.usb: DWC OTG Controller [ 1.063728] dwc2 ff400000.usb: new USB bus registered, assigned bus number 1 [ 1.064422] dwc2 ff400000.usb: irq 21, io mem 0xff400000 [ 1.065121] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002 [ 1.065765] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 1.066498] usb usb1: Product: DWC OTG Controller [ 1.066954] usb usb1: Manufacturer: Linux 4.4.143-52-rockchip-g7ed61b60d176 dwc2_hsotg [ 1.067711] usb usb1: SerialNumber: ff400000.usb [ 1.710048] phy phy-ff008000.syscon:usb2-phy@100.0: charger = USB_FLOATING_CHARGER [ 1.714605] ehci-platform ff440000.usb: EHCI Host Controller [ 1.715405] ehci-platform ff440000.usb: new USB bus registered, assigned bus number 2 [ 1.716296] ehci-platform ff440000.usb: irq 22, io mem 0xff440000 [ 1.725989] ehci-platform ff440000.usb: USB 2.0 started, EHCI 1.00 [ 1.726771] usb usb2: New USB device found, idVendor=1d6b, idProduct=0002 [ 1.727415] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 1.728111] usb usb2: Product: EHCI Host Controller [ 1.728578] usb usb2: Manufacturer: Linux 4.4.143-52-rockchip-g7ed61b60d176 ehci_hcd [ 1.729320] usb usb2: SerialNumber: ff440000.usb [ 1.733361] ohci-platform ff450000.usb: Generic Platform OHCI controller [ 1.734289] ohci-platform ff450000.usb: new USB bus registered, assigned bus number 3 [ 1.735166] ohci-platform ff450000.usb: irq 23, io mem 0xff450000 [ 1.794218] usb usb3: New USB device found, idVendor=1d6b, idProduct=0001 [ 1.794863] usb usb3: New USB device strings: Mfr=3, Product=2, SerialNumber=1 [ 1.795560] usb usb3: Product: Generic Platform OHCI controller [ 1.796121] usb usb3: Manufacturer: Linux 4.4.143-52-rockchip-g7ed61b60d176 ohci_hcd [ 1.796864] usb usb3: SerialNumber: ff450000.usb [ 1.803207] usbcore: registered new interface driver uvcvideo [ 1.934162] usbcore: registered new interface driver usbhid [ 1.934705] usbhid: USB HID core driver [ 2.042066] usb 2-1: new high-speed USB device number 2 using ehci-platform [ 2.251932] usb 2-1: New USB device found, ...
Rock Pi S, RK3308 CPU, is it supported by anything?
in Off-topic
Posted
@brentr
"v12 20190910" on both boards. One of them doesn't seem to be working well. Never mind.
I agree to disable the spi2.
Best regards