Introduce RK3562 family and KICKPI K3B#10142
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThis PR adds KICKPI K3B RK3562 support with board metadata, U-Boot and kernel configuration, RK3562 boot defaults, SWT6621S SDIO DKMS integration, display/touchscreen module ordering, and ALSA UCM audio profiles. ChangesKickPi K3B RK3562 board bring-up
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant Builder
participant BoardDefinition
participant DKMSExtension
participant Cache
participant SDCardChroot
participant ALSAUCM
Builder->>BoardDefinition: select KICKPI K3B RK3562 settings
BoardDefinition->>DKMSExtension: enable SWT6621S SDIO support
DKMSExtension->>Cache: download driver source tarball
DKMSExtension->>SDCardChroot: build and install DKMS module
BoardDefinition->>SDCardChroot: install module ordering configuration
BoardDefinition->>ALSAUCM: install HiFi UCM configuration
ALSAUCM-->>SDCardChroot: provide speaker and headphone playback setup
Possibly related issues
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Please validate u-boot compilation on Trixie (docker image) host. Soon, we will only use that. Perhaps only this is needed: #10094 |
Using the following commands: ./compile.sh BOARD=kickpi-k3b BRANCH=vendor RELEASE=resolute DOCKER_ARMBIAN_BASE_IMAGE=debian:trixieU-Boot seems to compile without any issues??? but the linux-rockchip-6.1 kernel build failed with errors. Here is the log: log-build-930cd2b9-163c-419a-897b-58b111af12e1.log.ans.txt After applying PR 10094, U-Boot still compiles without any issues. wget https://github.com/armbian/build/pull/10094.patch
patch -p1 < 10094.patch
docker rmi ghcr.io/armbian/docker-armbian-build:armbian-debian-trixie-latest
./compile.sh BOARD=kickpi-k3b BRANCH=vendor RELEASE=resolute DOCKER_ARMBIAN_BASE_IMAGE=debian:trixieHere is the log: |
|
Try clean build or with CLEAN_LEVEL=make,sources Kernel should build without issues. What concerncs me most is trixie compile and boot (boot loader part). |
After clearing the kernel source code under the cache directory and building with debian:trixie, the linux-rockchip-6.1 kernel no longer throws any errors. |
|
Remove incorrect ❯ cat RKBOOT/RK3562MINIALL.ini
......
[OUTPUT]
PATH=rk3562_spl_loader_v1.09.107.bin
......
❯ cat RKBOOT/RK3566MINIALL.ini
......
[OUTPUT]
PATH=rk356x_spl_loader_v1.25.114.bin
......
❯ cat RKBOOT/RK3568MINIALL.ini
......
[OUTPUT]
PATH=rk356x_spl_loader_v1.25.114.bin
...... |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (3)
config/sources/families/include/rockchip64_common.inc (1)
134-141: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick winConsider adding
ROCKUSB_BLOBfor MaskROM flashing support.The PR description documents MaskROM/eMMC installation methods, but the
rk3562block omitsROCKUSB_BLOB, which is used byrkdeveloptool/RKDevToolfor flashing in MASKROM mode. All other rk35xx SoCs that document MaskROM installation (rk3528, rk3566, rk3568, rk3588) define it. If MaskROM flashing is intended to work for this board, aROCKUSB_BLOBentry should be added.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@config/sources/families/include/rockchip64_common.inc` around lines 134 - 141, Add a ROCKUSB_BLOB assignment to the rk3562 case alongside the existing DDR_BLOB and BL31_BLOB settings, using the appropriate rk3562 RockUSB loader artifact consistent with other rk35xx SoC definitions. Preserve the existing boot configuration and case structure.extensions/seekwave-swt6621s-dkms.sh (2)
31-41: 🔒 Security & Privacy | 🔵 Trivial | 🏗️ Heavy liftPin the driver source and verify its integrity.
The tarball is fetched from a moving branch head (
kickpi-k3b-sdio-uart) with no commit pin or checksum verification. This makes builds non-reproducible and provides no protection against upstream tampering or a corrupted download. Consider pinning to a specific commit/tag and validating a known SHA-256 of the archive before extraction.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@extensions/seekwave-swt6621s-dkms.sh` around lines 31 - 41, Update the SeekWave source download flow around seekwave_tarball_url and the source.tar.gz output to use a pinned commit or tag instead of the moving kickpi-k3b-sdio-uart branch, and verify the downloaded archive against its known SHA-256 before extraction. Preserve the existing GITHUB_MIRROR URL handling and fail the build when integrity validation fails.
83-87: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueSimplify the shell quoting here. The current nested double quotes are brittle and easy to break during future edits; use single quotes around the inner command instead.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@extensions/seekwave-swt6621s-dkms.sh` around lines 83 - 87, Update the chroot_sdcard invocations that write module-load and modprobe configuration entries to use single quotes around each inner echo command, while preserving the existing redirection targets and append behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@extensions/seekwave-swt6621s-dkms.sh`:
- Around line 72-76: Update the guard in the DKMS build function around
target_kver to validate IMAGE_INSTALLED_KERNEL_VERSION before constructing or
using target_kver. Preserve the existing warning and early return when the
source kernel version is empty, preventing dkms build from receiving a malformed
-k value.
---
Nitpick comments:
In `@config/sources/families/include/rockchip64_common.inc`:
- Around line 134-141: Add a ROCKUSB_BLOB assignment to the rk3562 case
alongside the existing DDR_BLOB and BL31_BLOB settings, using the appropriate
rk3562 RockUSB loader artifact consistent with other rk35xx SoC definitions.
Preserve the existing boot configuration and case structure.
In `@extensions/seekwave-swt6621s-dkms.sh`:
- Around line 31-41: Update the SeekWave source download flow around
seekwave_tarball_url and the source.tar.gz output to use a pinned commit or tag
instead of the moving kickpi-k3b-sdio-uart branch, and verify the downloaded
archive against its known SHA-256 before extraction. Preserve the existing
GITHUB_MIRROR URL handling and fail the build when integrity validation fails.
- Around line 83-87: Update the chroot_sdcard invocations that write module-load
and modprobe configuration entries to use single quotes around each inner echo
command, while preserving the existing redirection targets and append behavior.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 89837820-43db-47a5-9c40-4446c9e62958
📒 Files selected for processing (7)
config/boards/kickpi-k3b.cscconfig/kernel/linux-rk35xx-vendor.configconfig/sources/families/include/rockchip64_common.incextensions/seekwave-swt6621s-dkms.shpackages/bsp/kickpi-k3b/kickpi-k3b-HiFi.confpackages/bsp/kickpi-k3b/kickpi-k3b.confpatch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
✅ Files skipped from review due to trivial changes (1)
- packages/bsp/kickpi-k3b/kickpi-k3b.conf
🚧 Files skipped from review as they are similar to previous changes (4)
- config/boards/kickpi-k3b.csc
- packages/bsp/kickpi-k3b/kickpi-k3b-HiFi.conf
- patch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
- config/kernel/linux-rk35xx-vendor.config
There was a problem hiding this comment.
🧹 Nitpick comments (2)
extensions/seekwave-swt6621s-dkms.sh (2)
39-41: 🔒 Security & Privacy | 🔵 Trivial | ⚡ Quick winDownloaded source is neither pinned nor integrity-checked.
The tarball is fetched from a moving branch head (
kickpi-k3b-sdio-uart) with no commit pin and no checksum verification, so build inputs can change silently and are not reproducible. Consider pinning to a specific commit/tag and verifying a known SHA-256 before extraction. This is intentional per the header comment, so treat it as a hardening suggestion.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@extensions/seekwave-swt6621s-dkms.sh` around lines 39 - 41, Harden the source download in the SeekWave SWT6621S flow by replacing the moving branch reference in seekwave_tarball_url with a pinned commit or tag, then verify the downloaded source.tar.gz against a known SHA-256 checksum before any extraction or use. Preserve the existing download logging and cache behavior while failing the build when verification fails.
83-87: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winSimplify the nested quoting here. Use single quotes for the echoed lines so the intent is clearer and the commands are less error-prone when edited.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@extensions/seekwave-swt6621s-dkms.sh` around lines 83 - 87, Update the five chroot_sdcard commands in the module-loading and modprobe dependency setup to use single quotes around each echoed line, while preserving the existing redirection targets and overwrite/append behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@extensions/seekwave-swt6621s-dkms.sh`:
- Around line 39-41: Harden the source download in the SeekWave SWT6621S flow by
replacing the moving branch reference in seekwave_tarball_url with a pinned
commit or tag, then verify the downloaded source.tar.gz against a known SHA-256
checksum before any extraction or use. Preserve the existing download logging
and cache behavior while failing the build when verification fails.
- Around line 83-87: Update the five chroot_sdcard commands in the
module-loading and modprobe dependency setup to use single quotes around each
echoed line, while preserving the existing redirection targets and
overwrite/append behavior.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 20430c87-3d44-4d72-a6e6-fd5409bcc823
📒 Files selected for processing (7)
config/boards/kickpi-k3b.cscconfig/kernel/linux-rk35xx-vendor.configconfig/sources/families/include/rockchip64_common.incextensions/seekwave-swt6621s-dkms.shpackages/bsp/kickpi-k3b/kickpi-k3b-HiFi.confpackages/bsp/kickpi-k3b/kickpi-k3b.confpatch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
✅ Files skipped from review due to trivial changes (1)
- packages/bsp/kickpi-k3b/kickpi-k3b-HiFi.conf
🚧 Files skipped from review as they are similar to previous changes (5)
- packages/bsp/kickpi-k3b/kickpi-k3b.conf
- config/kernel/linux-rk35xx-vendor.config
- patch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
- config/boards/kickpi-k3b.csc
- config/sources/families/include/rockchip64_common.inc
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@extensions/seekwave-swt6621s-dkms.sh`:
- Around line 83-87: Fix the command quoting in the modprobe dependency setup
around the two chroot_sdcard calls for swt6621s_wifi and skwbt. Use single
quotes for the inner echo strings so the complete softdep command, including
spaces, remains intact when passed to chroot_sdcard.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 0d609f20-7b08-49f6-ac97-caf8e9c467ea
📒 Files selected for processing (6)
config/boards/kickpi-k3b.cscconfig/kernel/linux-rk35xx-vendor.configconfig/sources/families/include/rockchip64_common.incextensions/seekwave-swt6621s-dkms.shpackages/bsp/kickpi-k3b/kickpi-k3b-HiFi.confpackages/bsp/kickpi-k3b/kickpi-k3b.conf
🚧 Files skipped from review as they are similar to previous changes (5)
- config/kernel/linux-rk35xx-vendor.config
- packages/bsp/kickpi-k3b/kickpi-k3b.conf
- config/sources/families/include/rockchip64_common.inc
- config/boards/kickpi-k3b.csc
- packages/bsp/kickpi-k3b/kickpi-k3b-HiFi.conf
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
config/sources/families/include/rockchip64_common.inc (1)
134-142: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueConsider defining
ROCKUSB_BLOBif the binary is available.The PR summary notes that the incorrect
ROCKUSB_BLOBwas removed because RK3562 usesrk3562_spl_loader_v1.09.107.bin. If this binary is currently available in thearmbian/rkbinrepository, consider defining it here so that MASKROM mode flashing viarkdeveloptoolorRKDevToolworks properly.💡 Proposed optional refactor
rk3562) CPUMAX=${CPUMAX:="2000000"} BOOT_SCENARIO="${BOOT_SCENARIO:=spl-blobs}" DDR_BLOB="${DDR_BLOB:-"rk35/rk3562_ddr_1056MHz_v1.07.bin"}" BL31_BLOB="${BL31_BLOB:-"rk35/rk3562_bl31_v1.21.elf"}" + ROCKUSB_BLOB="rk35/rk3562_spl_loader_v1.09.107.bin" BOOT_SOC_MKIMAGE="rk3562" BOOTENV_FILE='rk35xx.txt' ;;🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@config/sources/families/include/rockchip64_common.inc` around lines 134 - 142, In the rk3562 case of the board configuration, check whether rk3562_spl_loader_v1.09.107.bin is available in the armbian/rkbin repository and, if so, define ROCKUSB_BLOB with its correct repository path so MASKROM flashing tools use the proper loader.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@extensions/seekwave-swt6621s-dkms.sh`:
- Around line 31-36: Update the SeekWave source download flow near
seekwave_tarball_url to use a reviewed immutable commit archive instead of the
mutable branch URL, and define and validate its expected checksum after
downloading. Extract the verified archive with --strip-components=1 so
subsequent DKMS installation does not depend on GitHub’s generated top-level
directory name.
---
Nitpick comments:
In `@config/sources/families/include/rockchip64_common.inc`:
- Around line 134-142: In the rk3562 case of the board configuration, check
whether rk3562_spl_loader_v1.09.107.bin is available in the armbian/rkbin
repository and, if so, define ROCKUSB_BLOB with its correct repository path so
MASKROM flashing tools use the proper loader.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 9ed6e8ba-e7d2-4a85-b0bf-fb13796b7709
📒 Files selected for processing (7)
config/boards/kickpi-k3b.cscconfig/kernel/linux-rk35xx-vendor.configconfig/sources/families/include/rockchip64_common.incextensions/seekwave-swt6621s-dkms.shpackages/bsp/kickpi-k3b/kickpi-k3b-HiFi.confpackages/bsp/kickpi-k3b/kickpi-k3b.confpatch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
🚧 Files skipped from review as they are similar to previous changes (3)
- packages/bsp/kickpi-k3b/kickpi-k3b-HiFi.conf
- patch/u-boot/legacy/u-boot-radxa-rk35xx/board_kickpi-k3b/add-board-kickpi-k3b.patch
- config/kernel/linux-rk35xx-vendor.config
|
@igorpecovnik The SWT6621S firmware files have been migrated from GitHub Releases to the armbian/firmware repository, PR. Additionally, the swt6621s driver now supports searching for firmware in Tested on KICKPI K3B If you have any other suggestions, feel free to let me know and I will try them out, though my response might not be very timely. |
Description
This PR introduces Armbian support for the RK3562 family, with the KICKPI K3B serving as the first supported RK3562 SBC.
About KICKPI K3B
Product Page: https://www.kickpi.com/product/k3b/
WIKI: https://doc.kickpi.com/products/introduction/kickpi_k3b/
KICKPI K3B Armbian Peripheral Status
The serial boot log can be found here
Below are some images:
About RK3562 Armbian Bring-up
U-Boot: Since there is no mainline U-Boot support for the RK3562 yet, this implementation uses the Rockchip BSP U-Boot (2017 version) maintained by Radxa, along with board-specific patches. Modifications have been made to the armbian/build source code to support compilation for RK3562 U-Boot.
Kernel: Due to limited support for the RK3562 in the mainline kernel, the Rockchip 6.1 BSP kernel is used. All kernel-level support for the KICKPI K3B should be submitted to armbian/linux-rockchip via this PR.
Kernel Configuration: The required options have been enabled in linux-rk35xx-vendor.config.
WLAN/BT Driver: For the WLAN/BT drivers, a standalone driver repository is maintained and integrated using the Armbian DKMS extension. This approach allows more projects and kernels to benefit from the driver.
Display: Since the KICKPI K3B only features a MIPI DSI display interface, using a DSI panel is necessary for desktop scenarios. Utilizing a DTBO to support various DSI panels is a practical approach. This PR provides reference support for an 800x1280 10.1-inch MIPI 45-pin screen.
Artwork: The board image and vendor logo for armbian-imager are submitted via this PR.
How to Install Firmware on KICKPI K3B
Method 1: microSD Card
Flash the armbian.img to a microSD card and insert it into the board to boot.
Method 2: MaskROM Mode (eMMC Flashing)
Press the MaskROM button while connecting the board to your PC via a USB Type-A to Type-C cable. Then, use Rockchip's rkdeveloptool to flash armbian.img directly into the eMMC. You may need a loader during this process, which can be obtained as follows:
Note: After flashing via MaskROM, you must switch the power supply to a phone adapter or a DC power source for proper booting. The maximum output current from a PC's USB Type-A port is insufficient to power the KICKPI K3B during normal startup.
How Has This Been Tested?
Build Armbian image for KICKPI K3B, flash to eMMC, power on and test
Checklist:
Summary by CodeRabbit
Summary by CodeRabbit
New Features
Bug Fixes