154fa2f14a
Sibling to kernel-agent PR #8 which lands the scope-tagged board patches + fleet/ampere.yaml manifest. This PR carries the makepkg-side recipe. ## Baseline marfrit/linux-rk3588-marfrit @ f8f3ad9 (mainline v7.0-rc3 + 18 commits): 10 by Markus Fritsche (board DTS + Kconfig + suspend/wakeup + bt) 4 by Shawn Lin (phy: rockchip-snps-pcie3 stability) 2 by Cristian Ciocaltea (clk + dw-dp bridge — Collabora) 1 by Sebastian Reichel (Rock 5 ITX hdmirx — unused by ampere) 1 by Pedro Alves (CLK_SET_RATE_PARENT VOP2 fix) The 6 board-relevant patches (pwm15 pinctrl + RK806 power-off + genbook pwm-fan/speaker/USB-C/lid) are scope-tagged in kernel-agent. The 12 others are 'cherry-picks-in-baseline' currently — splitting them into scope-tagged patches is a follow-up. ## Source distribution The kernel tree isn't pushable to Gitea (boltzmann's working clone is shallow). Tarball (260MB) doesn't belong in marfrit-packages either. Pragmatic shortcut: ship prebuild.sh that produces the tarball locally from $LINUX_RK3588_MARFRIT_TREE (default ~/src/linux-rockchip) just before makepkg runs. PKGBUILD source array references the tarball by name; makepkg picks it up from the PKGBUILD dir. Build flow: cd arch/linux-ampere-fourier ./prebuild.sh # produces 260MB tarball; idempotent w/ sha check makepkg -s --noconfirm Future iteration: host the tarball on Gitea release assets or packages.reauktion.de/sources/ and switch source to URL. ## What the PR ships PKGBUILD — the recipe (linux-rk3588-marfrit @ f8f3ad9) config — snapshot of ampere's /proc/config.gz linux-ampere-fourier.preset — mkinitcpio preset, /boot/firmware/ paths extlinux-add.hook — alpm hook, fires on /boot/firmware/Image* changes extlinux-add.sh — idempotent managed-label injector for /boot/firmware/extlinux/extlinux.conf (vfat on mmcblk0p1, ampere-specific path) prebuild.sh — source-staging helper (see above) README.md — build + install runbook ## ampere-specific boot path differences vs fresnel ampere boots from /boot/firmware/ (vfat partition), not /boot/ (root partition) like fresnel. The PKGBUILD installs Image + initramfs + DTB under /boot/firmware/ directly. The extlinux-add hook fires on /boot/firmware/<X> path changes and edits /boot/firmware/extlinux/extlinux.conf. The mkinitcpio preset writes initramfs to /boot/firmware/. Only one PRESET ('default') — no fallback image — because /boot/firmware is ~1G total and two ~20MB initramfs files plus the DTB and a couple of kernel-image backups would squeeze it tight. ## Out of scope this PR - Ask 2 (VP9 enablement) and Ask 3 (AV1 dec) from kernel-agent issue #6 - Build + publish + install (sequenced after this PR + kernel-agent PR #8 merge) - Splitting the 12 non-board commits into scope-tagged kernel-agent patches
71 lines
2.6 KiB
Markdown
71 lines
2.6 KiB
Markdown
# linux-ampere-fourier
|
|
|
|
Kernel package for ampere (CoolPi GenBook RK3588). Baselined on
|
|
`marfrit/linux-rk3588-marfrit @ f8f3ad9` (mainline v7.0-rc3 + 18
|
|
RK3588-fleet-relevant commits — 10 Markus, 8 upstream cherry-picks).
|
|
|
|
See `marfrit/kernel-agent/fleet/ampere.yaml` for the manifest +
|
|
`marfrit/kernel-agent/patches/{soc,module,board}/...` for the
|
|
scope-tagged board patches in the baseline.
|
|
|
|
## Build
|
|
|
|
The kernel source isn't on Gitea — boltzmann's working clone is
|
|
shallow (Gitea refuses shallow pushes) and a 260MB tarball doesn't
|
|
belong in `marfrit-packages`. Stage the source locally from a
|
|
clone of the `linux-rk3588-marfrit` branch:
|
|
|
|
```sh
|
|
cd arch/linux-ampere-fourier
|
|
./prebuild.sh # produces linux-rk3588-marfrit-f8f3ad9.tar.gz
|
|
makepkg -s --noconfirm # native aarch64 build; no distcc
|
|
```
|
|
|
|
`prebuild.sh` looks at `$LINUX_RK3588_MARFRIT_TREE` (default
|
|
`~/src/linux-rockchip`) for the kernel working tree. The tip commit
|
|
must be reachable in that clone — fetch the `linux-rk3588-marfrit`
|
|
branch first if you cloned from elsewhere.
|
|
|
|
## Build hosts
|
|
|
|
Native aarch64 only (per kernel-agent `feedback_kernel_agent_no_distcc.md`).
|
|
Either ampere itself (8C/2.4GHz, 32GB, native arch) or boltzmann
|
|
(Rock 5 ITX+, same uarch). fermi as fallback.
|
|
|
|
## Install
|
|
|
|
Adds a managed label to `/boot/firmware/extlinux/extlinux.conf`:
|
|
|
|
```
|
|
label linux-ampere-fourier
|
|
menu label linux-ampere-fourier (managed)
|
|
kernel /Image-ampere-fourier
|
|
initrd /initramfs-ampere-fourier.img
|
|
fdt /rk3588-coolpi-cm5-genbook.dtb-ampere-fourier
|
|
append <inherited from arch_mainline>
|
|
```
|
|
|
|
Default label is NOT changed. After verifying boot of the managed
|
|
label at the u-boot menu, you flip `default` manually. Reverting =
|
|
boot a different label (e.g. `arch_mainline`, `ubuntu_mainline`).
|
|
|
|
## Boot path
|
|
|
|
ampere uses `/boot/firmware/` (vfat on mmcblk0p1, ~1G), distinct
|
|
from fresnel's `/boot/` on root partition. The PKGBUILD installs
|
|
Image, initramfs, and DTB directly under `/boot/firmware/`. No
|
|
DTB subdir — single board target.
|
|
|
|
## Open follow-ups (per kernel-agent issue #6)
|
|
|
|
- **Ask 2** (VP9 enablement on RK3588 rkvdec) — not addressed in this
|
|
iteration. Separate session.
|
|
- **Ask 3** (AV1 decoder integration) — backend libva work, not kernel.
|
|
- Hosting the source tarball publicly so `prebuild.sh` isn't needed —
|
|
candidate: Gitea release asset, or `packages.reauktion.de/sources/`.
|
|
- Splitting the 12 non-board cherry-pick commits in the baseline
|
|
(4 Shawn Lin phy, 2 Cristian Ciocaltea, etc.) into scope-tagged
|
|
patches in kernel-agent — currently they ride along inside the
|
|
pinned baseline rather than being explicit `includes:` in the
|
|
manifest.
|