WIP: Add Seeed Studio reComputer RK3576/RK3588 DevKit support#9719
WIP: Add Seeed Studio reComputer RK3576/RK3588 DevKit support#9719baorepo wants to merge 32 commits intoarmbian:mainfrom
Conversation
Extract duplicated hooks from rk3576 and rk3588 board configs into recomputer-rk35xx-common.inc. Both configs source the shared file and keep only SoC-specific hooks. Common hooks: bluez (FCS960K), USB gadget, Morse FGH100M tools, AIC8800 wireless, security hardening, PATH config, USB auto-mount. Key fixes included: - USB gadget: NM managed via ExecStartPost in usbdevice.service drop-in (not via broken keyfile unmanaged-devices exception) - dnsmasq: After=usbdevice + Restart=on-failure for reliable boot - serial-getty@ttyGS0: ordering via drop-in, not custom service - USB auto-mount: udev SYSTEMD_WANTS triggers usb-automount@.service, mounts under /media/seeed/ with proper ownership - SSH: MaxAuthTries 6 (OpenSSH default) to support multi-key clients Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
When usbdevice fails on first attempt, serial-getty@ttyGS0 tries to start before ttyGS0 exists and stays dead. Add Restart=on-failure so it retries after usbdevice eventually succeeds. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
bind-interfaces fails if usb0 doesn't exist at startup, requiring After=usbdevice + Restart=on-failure workarounds. bind-dynamic tolerates missing interfaces and serves DHCP when usb0 appears, removing the need for the dnsmasq systemd drop-in entirely. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Clear BindsTo=dev-ttyGS0.device from the base unit via drop-in override. ttyGS0 is a USB gadget device not present at boot, so the base unit's BindsTo causes a dependency failure. Also drop Restart=on-failure override to preserve the base unit's Restart=always, preventing the getty from staying dead after a normal logout. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
Important Review skippedIgnore keyword(s) in the title. ⛔ Ignored keywords (2)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. 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 |
The BT UART assignment is per-board, not per-SoC. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Move BT UART selection from BOOT_SOC-based case logic in common.inc to per-board BT_UART variables. RK3576 DevKit uses ttyS4, RK3588 DevKit uses ttyS6. Remove redundant pre_umount_final_image BT UART hook from RK3576 config since common.inc BSP hook now handles it. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
| AIC8800_TYPE="sdio" | ||
| enable_extension "radxa-aic8800" | ||
|
|
||
| source "${SRC}/config/boards/recomputer-rk35xx-common.inc" |
There was a problem hiding this comment.
Hi, this is not standard. There's no real standard for this, really, except using extensions and/or using family code. Long ago I've tried a "vendor" common dir for the Mekotronics, see sources/vendors/mekotronics and config/boards/mekotronics-r58x.csc? In the end it's just about the file/folder structure.
There was a problem hiding this comment.
Okay, I made revisions based on your two references. Thanks
|
@EvilOlaf Thanks for the feedback on What we found: The kernel artifact cache key is We checked: no other board in Options we're considering:
Our preference is option 1 for now — it's the smallest fix that correctly tracks the cache hash, and we can revisit the family structure later if needed. What do you think? |
|
I be totally honest, I don't know exactly how the internals on this work, I just know from previous PRs that on various occasions board-level kernel adjustments are flagged as a bad idea since it breaks apt repo Anyway it might be possible to move all of this to family level and work around this. I just throw in some random thoughts, may be totally wrong though.
If the issue is that, when built as module, it loads (too) late, perhaps create a hook for initramfs generation to force the module into initramfs image? Then it should behave similar to being built-in I guess
If module is sufficient, I'd do the same as above
Without looking deeper, tbh not sure how to exactly handle this. Perhaps there are other extensions already that add some sort of drivers which obviously also come with kernel config settings.
If added as module I don't see a reason not to add to family kernel config and if needed again force move into initramfs. |
At a high level the issue is with the software deployment lifecycle via apt and the Armbian apt repositories. kernel apt packages are produced and populated into the apt repositories keyed by Family-Branch. So after initial image creation when an apt update/upgrade is run the latest kernel package from the repositories will be deployed to the device which will upgrade the kernel to the standard kernel for the Family-Branch. Which will effectively remove any board specific kernel that was originally installed. The Armbian concept of Family is a superset of kernel features that work for all boards within the family. Generally adding additional board feature to the family kernel won't be a problem, but it can sometimes cause conflicts. The other consideration is that this is done to minimize Armbian infrastructure costs. If each board had its own kernel, the storage and infrastructure cost for the build farms and the apt mirrors would be unmaintainable. |
|
@EvilOlaf @SteeManMI Thanks both for the detailed explanation — that clears up a lot. @SteeManMI The apt repository deployment angle makes perfect sense now. We hadn't considered the full lifecycle beyond the build cache — the fact that @EvilOlaf The initramfs hook approach for forcing module load is a good idea for PCA953X and RTC. For the Morse wireless bits we'll look at how other extensions handle driver kernel config additions. The direction seems clear: move our config changes to family level (or an extension, for the Morse driver parts), prefer modules over built-in, and use initramfs hooks for anything that needs to be available early. We'll take some time to figure out the right split and come back with a concrete proposal. Thanks again for the guidance. |
Move enable_extension "seeed_armbian_extension" back to top-level code in recomputer-rk35xx-common.inc. The armbian framework finalizes the extension system before post_family_config hooks run, so calling enable_extension inside a hook triggers "already initialized" error. The git clone/pull remains in the hook to defer network I/O.
Reverts the split introduced by 3f3a384 and partially reverted by ade3393. Both the git clone/pull and enable_extension must execute at top-level in recomputer-rk35xx-common.inc; they cannot be deferred to a post_family_config hook. Root cause ---------- The Armbian extension system has a strict initialization sequence: 1. Board/family config files are sourced (top-level code runs) 2. enable_extension() calls register extensions 3. initialize_extension_manager() scans all __-separated hook functions via compgen -A function, then locks further enable_extension() calls (counter > 0 → fatal exit) 4. post_family_config hooks are called enable_extension() is hard-gated after step 3 (see lib/functions/general/extensions.sh:461-465). All hooks, including post_family_config, run at step 4 — too late to call enable_extension(). Previous attempts ----------------- - 3f3a384 moved both clone and enable_extension into a post_family_config hook → "already initialized" fatal error because enable_extension runs after the manager is locked. - ade3393 moved enable_extension back to top-level but kept git clone in the hook → "cant find extension 'seeed_armbian_extension' anywhere" because enable_extension runs before the hook clones the extension files to disk. Both attempts fail because they split an atomic operation: the extension files must exist on disk before enable_extension() is called, and enable_extension() must run before the extension manager initializes. Therefore both steps must happen at top-level during config file sourcing (step 1). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
The previous dpkg --force-depends installation can leave apt dependency tracking in a broken state. Add --fix-broken install to repair it.
- board-images/recomputer-rk3576-devkit.png - board-images/recomputer-rk3588-devkit.png - board-vendor-logos/seeed-studio-logo.png Required by armbian/build#9719
Replace manual prebuilt deb downloads and source compilation with apt-get install from the Seeed APT repository hosted on GitHub Pages. This applies to all Seeed packages across RK3576 and RK3588 boards: - fcs960k-aic-bluez, usbdevice-gadget, morse tools (common) - camera-engine-rkaiq-rk3576 (RK3576) - libmali-g610, camera-engine-rkaiq-rk3588, realtek-r8125-dkms (RK3588) Use chroot_sdcard instead of chroot_sdcard_apt_get_install to avoid the framework's bind-mounted apt lists cache overwriting the Seeed repo index. Extract seeed_recomputer_install_from_apt() helper to centralize the add-repo/install/remove cycle.
* Add Seeed Studio reComputer board images and vendor logo - board-images/recomputer-rk3576-devkit.png - board-images/recomputer-rk3588-devkit.png - board-vendor-logos/seeed-studio-logo.png Required by armbian/build#9719 * Add border to Seeedstudio logo and run trough size optimizer --------- Co-authored-by: pillar1989 <zuobaozhu@gmail.com> Co-authored-by: Igor Pecovnik <igor@armbian.com>
…lict - Add post_family_tweaks_bsp hook to write seeed.list with signed-by GPG key into the final image, enabling apt upgrade for Seeed packages - Import GPG key with gpg --dearmor (binary format required by signed-by) - Only refresh Seeed source index during build (skip Ubuntu/Armbian) to cut build time from ~54 min to ~22 min - Move fcs960k-aic-bluez install to post_repo_customize_image hook so it replaces bluez after desktop packages are installed
The package uses generic Rockchip configfs USB gadget which works on both RK3576 and RK3588.
🚫 Missing required board assetsThis PR adds new board configuration(s). Required assets must already exist in github/armbian/armbian.github.io.
Missing items
Once the missing files are added (or a PR is opened in armbian/armbian.github.io), re-run this check. |
Summary
Add board support for Seeed Studio's reComputer RK3576 DevKit and reComputer RK3588 DevKit to the Armbian build framework. These are industrial-grade single-board computers based on Rockchip RK3576 (octa-core A72/A53) and RK3588 (octa-core A76/A55) SoCs, targeting edge AI and IoT applications.
Board Support
config/boards/recomputer-rk3576-devkit.conf): RK3576 SoC,BOARDFAMILY=rk35xx, vendor kernel, custom bootscript, PCA953X GPIO expander, AD5398 DAC for fan control, X11 KMS on card0, ES8311 audio codecconfig/boards/recomputer-rk3588-devkit.conf): RK3588 SoC,BOARDFAMILY=rockchip-rk3588, vendor kernel, custom bootscript, Mali-G610 GPU (libmali), Realtek r8125 Ethernet DKMS, multi-display audio naming (HDMI0/HDMI1/HDMI-In/DP0/ES8311)config/boards/recomputer-rk35xx-common.inc): Extracted ~300 lines of common hooks covering wireless, Bluetooth, USB gadget, security hardening, PATH, and OTA support. BT UART selection uses${BOOT_SOC}case branching (rk3576→ttyS4, rk3588→ttyS6)Hardware Support
security-hardening/recomputer-security.sh/media/seeed/LABELseeed_armbian_extension)RK_AUTO_DECRYP=yes)Boot & Firmware
boot-seeed-rk3576.cmd,boot-seeed-rk35xx.cmd) with SPI flash boot supportrk3576-recomputer-rk3576-devkit.dts,rk3588-recomputer-rk3588-devkit.dtsBuild Framework Integration
lib/functions/compilation/patch/drivers_network.sh: Driver harness integration for Morse wireless FGH100M kernel modulelib/functions/compilation/patch/drivers-harness.sh: Hook for Morse driver buildENABLE_SEEED_RK_EXTENSION=yesclonesseeed_armbian_extensionfrom GitHub for OTA, encryption, and secure boot featuresChanged Files
config/boards/recomputer-rk3576-devkit.confconfig/boards/recomputer-rk3588-devkit.confconfig/boards/recomputer-rk35xx-common.incconfig/bootscripts/boot-seeed-rk3576.cmdconfig/bootscripts/boot-seeed-rk35xx.cmdconfig/kernel/linux-rk35xx-vendor.configpatch/kernel/rockchip-rk35xx-legacy/patch/kernel/rockchip-rk3588-legacy/patch/kernel/rockchip64-7.0/patch/misc/wireless-fgh100m.patchpatch/u-boot/*lib/functions/compilation/patch/How to Test
Serial console:
minicom -b 1500000 -D /dev/ttyUSB0Summary by CodeRabbit
Release Notes
New Features
Bug Fixes