Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rk35xx-vendor: bump to latest sdk release rkr3 #6853

Merged
merged 1 commit into from
Jul 19, 2024

Conversation

amazingfate
Copy link
Contributor

Description

Rockchip has released new sdk with rk3576 support and kernel's tag is linux-6.1-stan-rkr3.
I have rebased commits from rkr1 to rkr3 and this pr depends on armbian/linux-rockchip#200.
Prebuilt kernel can get downloaded from github actions: https://github.com/armbian/linux-rockchip/actions/runs/9740746614?pr=200

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Please also note any relevant details for your test configuration.

  • ./compile.sh BOARD=rock-5b BRANCH=vendor DEB_COMPRESS=xz KERNEL_CONFIGURE=no KERNEL_GIT=shallow
  • Kernel boots fine on rock5b.
  • rk356x boards need test
  • rk3528 boads need test
  • Other rk3588 boards need test

Checklist:

Please delete options that are not relevant.

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules

@amazingfate amazingfate marked this pull request as draft July 1, 2024 09:33
@github-actions github-actions bot added size/small PR with less then 50 lines Hardware Hardware related like kernel, U-Boot, ... Patches Patches related to kernel, U-Boot, ... labels Jul 1, 2024
@amazingfate amazingfate marked this pull request as ready for review July 16, 2024 14:53
@amazingfate
Copy link
Contributor Author

Tested with rk3568 board hinlink h66k and rk3528 board hinlink ht2, working fine.

@benhoff
Copy link
Collaborator

benhoff commented Jul 16, 2024

Not sure if I messed something up, with the compile, but could not get this to boot with orange pi 5 plus.

@amazingfate
Copy link
Contributor Author

Not sure if I messed something up, with the compile, but could not get this to boot with orange pi 5 plus.

Any serial logs?

@benhoff
Copy link
Collaborator

benhoff commented Jul 17, 2024

Any serial logs?

No, I wasn't getting any output on the HDMI. No blinkies on the ethernet either, which suggest to me that the image wasn't booting.

log-build-d190bf26-0659-404b-aeb8-abf5b212057d.log

Compile Log files are above. I'm going to be working on this today, going to reflash an image from the main armbian website ( need to compile mesa + Qt from scratch on a fresh image) so happy to take another swing if it's helpful!

edit: flashed a downloaded image to the same sd card, and it booted, so the SD card is good. I validated the SHAsum on the system I was flashing on (from the original file that didn't boot for me) and I use balena-etcher that I think does that as well, so as long as the build was clean, the result should be valid

@benhoff
Copy link
Collaborator

benhoff commented Jul 17, 2024

Someone on the discord explained how to get a serial console. I'm very new to hardware, but long time linux user.

Trying to boot from MMC1
Trying fit image at 0x4000 sector
## Verified-boot: 0
## Checking atf-1 0x00040000 ... sha256(a7d1d8d191...) + OK
## Checking uboot 0x00200000 ... sha256(90939e0876...) + OK
##  atf-3 0x000f0000 ... sha256(aa71013e72...) + OK
Jumping to U-Ba8a8422:derrick.huang, fwver: v1.45
NOTICE:  BL31: Built : 10:1 bcore1_rst = 0x0
INFO:    l3 cache partition cfg-0
INFO:    sreq_mhz= 2112MHz
INFO:    dfs DDR fsp_params[1].freq_mhz= 528MH
INFO:    SPSR = 0x3c9


U-Boot 2017.09-armbian-2017.09-S8ea7-Paff1-H8c72-V6123-Ba09ff78f0 - eb9fecd0
00: 0
Card did not respond to voltage select!
mmc_init: -95, tswitch to partitions #0, OK
mmc1 is current device
Boot from S
CLK: (sync kernel. arm: enter 1008000 KHz, init 1008000 KHz, kernel 0N/A)
  b0pll 24000 KHz
  b1pll 24000 KHz
  lpll 24000 KHnter_root 702000 KHz
  pclk_center_root 100000 KHz
  hclk_centtoboot('CTRL+C'):  0 
starting USB...
Bus usb@fc000000: usb maRegister 2000140 NbrPorts 2
Starting the controller
USB XHCI 1Register 2000140 NbrPorts 2
Starting the controller
USB XHCI 11 USB Device(s) found
scanning bus usb@fc800000 for devices... 1 USB Device(s) found
scanning bus usb@fc400000 for devices... to partitions #0, OK
mmc1 is current device
Scanning mmc 1:1...
Found U-Boot script /boot/boot.scr
0500000
Boot script loaded from mmc 1
Testing for existence mm/armbianEnv.txt ...
 1 /boot/armbianEnv.txt into 0x9000000 filesize 0xb5...
Importi15914619 bytes read in 1316 ms (11.5 MiB/s)
36776448 bytes read in 2989 ms (11.7 MiB/s)
** File not found /boot/dtb/rockchip/rk3588-orangepi-5-plus.dtb ommand 'kaslrseed' - try 'help'
Fdt Ramdisk skip relocation
5 Bytes = 15.2 MiB
   Load Address: 00000000
   Entry Point:  OK
ERROR: Did not find a cmdline Flattened Device Tree
Could ne 0: unknown device
No ethernet found.
missing environment variable: pxeuuid
missing environment variable: bo found.
missing environment variable: bootfile
Retrieving file environment variable: bootfile
Retrieving file: pxelinux.cfg/0t-arm
No ethernet found.
missing environment variable: bootfilFIT: No boot partition
FIT: No fit blob
FIT: No FIT image

@amazingfate
Copy link
Contributor Author

rk3588-orangepi-5-plus.dtb

I guess you are using this kernel source: https://github.com/armbian/linux-rockchip/tree/rk-6.1-rkr3, which does not have devicetree of opi5plus. This pr depends on armbian/linux-rockchip#200, so before that pr is merged, you have to use kernel source from my repo: https://github.com/amazingfate/linux-rockchip/tree/rk-6.1-rkr3_wip.

@benhoff
Copy link
Collaborator

benhoff commented Jul 17, 2024

@amazingfate , updating the kernel to that branch works for me, boots fine now

@rpardini
Copy link
Member

I've cherry picked and trying to build just built.
I'm facing build failures related to the wifi drivers.
Wondering if anyone got the same?

Subject: [PATCH] rk35xx-vendor: rkr3 won't build `driver_uwe5622` nor `driver_rtl8811_rtl8812_rtl8814_rtl8821` nor `driver_rtl8192EU` nor `driver_rtl8189ES`
---
diff --git a/config/sources/families/rk35xx.conf b/config/sources/families/rk35xx.conf
--- a/config/sources/families/rk35xx.conf	(revision 2f33cb45915c5cbd569ada2aad7fc393dc061cd1)
+++ b/config/sources/families/rk35xx.conf	(revision ceffbc20693fd7b65e62bf4cd2c0aa588fee0646)
@@ -33,6 +33,7 @@
 		KERNELSOURCE='https://github.com/armbian/linux-rockchip.git'
 		KERNELBRANCH='branch:rk-6.1-rkr3'
 		KERNELPATCHDIR='rk35xx-vendor-6.1'
+		KERNEL_DRIVERS_SKIP+=("driver_uwe5622" "driver_rtl8811_rtl8812_rtl8814_rtl8821" "driver_rtl8192EU" "driver_rtl8189ES") # won't build with rkr3
 		;;
 esac
 
diff --git a/config/sources/families/rockchip-rk3588.conf b/config/sources/families/rockchip-rk3588.conf
--- a/config/sources/families/rockchip-rk3588.conf	(revision 2f33cb45915c5cbd569ada2aad7fc393dc061cd1)
+++ b/config/sources/families/rockchip-rk3588.conf	(revision ceffbc20693fd7b65e62bf4cd2c0aa588fee0646)
@@ -37,6 +37,7 @@
 		KERNELBRANCH='branch:rk-6.1-rkr3'
 		KERNELPATCHDIR='rk35xx-vendor-6.1'
 		LINUXFAMILY=rk35xx
+		KERNEL_DRIVERS_SKIP+=("driver_uwe5622" "driver_rtl8811_rtl8812_rtl8814_rtl8821" "driver_rtl8192EU" "driver_rtl8189ES") # won't build with rkr3
 		;;
 
 	current)

@benhoff
Copy link
Collaborator

benhoff commented Jul 17, 2024

I've cherry picked and trying to build just built. I'm facing build failures related to the wifi drivers. Wondering if anyone got the same?

Yes, I think I built with a flag turned on to shutoff extra wifi because the patches were failing.

@rpardini
Copy link
Member

Realized now just picking this doesn't bring armbian/linux-rockchip#200 while that's not merged.

@rpardini
Copy link
Member

Pushed a commit disabling the drivers that don't build. I think uwe is actually required for some boards, though.

@amazingfate
Copy link
Contributor Author

I have sprdbt_tty, sprdwl_ng, and 8192eu built.
And github workflow also built them: https://github.com/armbian/linux-rockchip/actions/runs/9957894813/job/27510953792

@rpardini
Copy link
Member

I have sprdbt_tty, sprdwl_ng, and 8192eu built.
And github workflow also built them: armbian/linux-rockchip/actions/runs/9957894813/job/27510953792

Interesting. Guess I've something different, somehow; I'll unpush that disablement commit so we can get to the bottom of this.

@rpardini
Copy link
Member

Yeah sorry for the noise with the wifi-drivers. I've dropped the commit and rebuilt and all was fine. I guess the first try I had a different/newer host OS and gcc was stricter with warnings/errors etc.

@amazingfate
Copy link
Contributor Author

Let's merge it, so we can continue with support for rk3576.

@amazingfate amazingfate merged commit 7cf6f99 into armbian:main Jul 19, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hardware Hardware related like kernel, U-Boot, ... Patches Patches related to kernel, U-Boot, ... size/small PR with less then 50 lines
Development

Successfully merging this pull request may close these issues.

3 participants