User:Brendlefly62/Rockchip RK3288 Asus Tinker Board S/Assemble a Gentoo System
Lay out the Block Device(s)
Recommendation for this board and bootloader - use two partitions, one vfat for the boot directory and one ext4 for the rootfs. External mass storage can be added later for mountpoints such as /srv and so on.
device/file | start sector | Sectors | size | type | purpose, remarks |
---|---|---|---|---|---|
/dev/mmcblk0p1 | 8192 (*) | 512000 | 250M | c W95 | /boot/ -- kernel(s), extlinux.conf, etc |
/dev/mmcblk0p2 | 520192 | remaining | space | 83 Linux | / -- rootfs |
/var/cache/swap/swap1 | (**) | 6G | swap | augment board's meager 2G RAM | |
(*) Be sure to leave adequate room for the "u-boot-rockchip-with-spl.bin" bootloader file installed with dd
starting at sector 64. Note that other SBC bootloaders may also need to install other files at much higher starting sectors. 8192 should be reasonably conserviative for this system. (**) Using a swap file rather than swap partition provides a bit more flexibility, if resizing is necessary. Currently, significant swap space may be necessary to support memory-intensive compile jobs (gcc, rust, for example) if the use of binary packages and/or cross compiling is not available or desired. |
Format and Populate Partitions
Mount the boot and rootfs partitions to a folder structure on an Amd64 workstation (where components can be cross-compiled) or another Arm device (where it might be possible to continue the installation with a regular chroot transition as described in the Gentoo Handbook..
Root Filesystem
Mount the rootfs partition on (for example) /mnt/gentoo.
Follow the basic steps in a Gentoo Handbook such as for Amd64. Start with getting the appropriate stage 3, etc.
Boot Partition
Mount the boot partition on (for example) /mnt/gentoo/boot. Populate the /boot/ directory with artifacts re-used from another distribution - e.g. armbian kernel, initrd, dtb files and overlays, or build these as described in the next section. The endstate should look something like
user $
tree /boot/
/boot/ | |-- dts | ... | |-- rk3288-evb-act8846.dtb | |-- rk3288-evb-rk808.dtb | |-- rk3288-firefly-beta.dtb | |-- rk3288-firefly-reload.dtb | |-- rk3288-firefly.dtb | |-- rk3288-miqi.dtb | ... | |-- rv1108-evb.dtb | `-- rv1126-edgeble-neu2-io.dtb |-- extlinux | `-- extlinux.conf |-- hw_intf.conf |-- overlays | |-- ads7846-tinker.dtbo | |-- audioinjector-addons.dtbo | |-- camera-ov5647.dtbo | |-- ds1307.dtbo | ... | `-- waveshare35a-tinker.dtbo |-- rk3288-tinker-s.dtb |-- wlan_preload.EXAMPLE `-- zImage
Once the basic build steps described in the handbook are complete, the system should be bootable
Boot and then fine-tune the installation
Observe u-boot output on serial console, and be patient; it can take 45 seconds for the SPL to scan devices and do its thing before the HDMI console will starts up.