Hello,
I've just posted a
v1.5.0 release of my bootable 64-bit Gentoo image on GitHub (
here, includes full download instructions).
This release marks a significant milestone for the project, as the RPi4 is now supported (in addition to the RPi3 model B and B+, which remain supported too).
Thanks to rapid upstream progress on aarch64 kernel work for the new board, there are surprisingly few compromises required when running the Pi4 under a 'pure' 64-bit OS such as this one. Specifically, for the Pi4 in this 1.5.0 release:
- V3D graphics acceleration is supported in X under vc4-fkms-v3d / Mesa;
- the full 4GiB complement of memory is usable (if you are lucky enough to own a top-of-the-line model, that is ^-^);
- the V4L2 M2M video codecs and optional plug-in camera module are both usable;
- use of dual HDMI displays is supported;
- Bluetooth, fast Ethernet, and dual-band WiFi work.
All software on the image (userland and kernel) has been ground-up recompiled using "march=armv8-a+crc -mtune=cortex-a72 -O2" CFLAGS, meaning it should be optimized for the out-of-order pipeline provided by the newer Pi4's Cortex-A72 SoC, while still retaining backwards compatibility with the older RPi3 B/B+'s Cortex-A53.
A
screenshot of the image running on a dual-display RPi4 B may be viewed
here.
As always, you can burn the image (~1,643MiB compressed) to a microSD card (>=16GB), then boot your RPi3 or RPi4 from it directly (the root partition will be automatically resized to fill the card on first boot). Full instructions for download and use are provided on the project's
GitHub page.
Since the image contains a complete (OpenRC-based) Gentoo system (including a full Portage tree, up-to-date as of 10 August 2019), you can run emerge operations immediately. But as it also comes with a reasonably populated userland (see the screenshot referred to
above; all the apps shown, and many others, are bundled), you can get productive
without having to compile or configure anything first (unless you want to, of course ^-^). Just download, xzcat to a microSD card (or use
Etcher), and boot!
NB: as you may have noticed, the project's name on GitHub has changed, from gentoo-on-rpi3-64bit to gentoo-on-rpi-64bit, to reflect the fact that the RPi4 is now also supported. Thanks to the way GitHub does things, people trying to find the old project should be automagically redirected to the renamed version. My bad in choosing an over-limiting moniker first time ><
A changelog from the prior release image (with full manual upgrade instructions) may be viewed
here, but in summary:
- Updated the RPi3 kernel (from the bcmrpi3-kernel-bis weekly autobuild) to version 4.19.66.20190816.
- Added an additional kernel (from the bcm2711-kernel-bis weekly autobuild). This second kernel is used when booting the RPi4, lives at /boot/kernel8-p4.img, and is a tweaked version, as the name suggests, of a completely separate configuration: bcm2711_defconfig, as opposed to bcmrpi3_defconfig. The two kernels have distinguished release names, and so separate subdirectories in /lib/modules, but as they are built together, they share a common kernel tree tip commit. The kernel version used in this release includes (on the bcm2711 build) the recently-upstreamed PR#3144 (which allows the full 4GiB of RAM to be used, where present) and PR#3063 (which enables the use of V3D acceleration on the Pi4). The two kernels have auto-generated ebuilds by which they are installed: sys-kernel/bcmrpi3-kernel-bis-bin and sys-kernel/bcm2711-kernel-bis-bin, respectively.
- Boot firmware updated to sys-boot/rpi3-64bit-firmware-1.20190718, and userland libraries to media-libs/raspberrypi-userland-1.20190808 (for dual-monitor aware tvservice utility etc.)
- Size of the boot partition on the image expanded, from 63MiB to 255MiB, to accommodate the new dual-kernel setup just described (required for RPi3/4 booting).
- Added dev-lang/go (it's been the most frequently requested package), and (an arm64 Pi4 patched version of) dev-libs/pigpio (for easy control of GPIOs) to the core package set.
- Added sys-block/gparted (for disk management), net-misc/xorgxrdp and net-misc/tigervnc[server] (for remote access), media-sound/pavucontrol for pulseaudio (also made this a default USE flag), and x11-misc/arandr (for multi-screen layouts) to the xfce package set. (Also modified the arandr ebuild to add a login service that auto-loads layouts saved to ~/.screenlayout/default.sh).
- Added app-office/abiword to the apps set (a lighter alternative to libreoffice writer - which remains bundled too - that some may prefer).
- Included a slightly tweaked media-libs/mesa to allow v3d acceleration on the RPi4. Standard vc4 acceleration on the RPi3 is still supported.
- Updated the pyconfig_gen application (found at Settings -> RPi Config Tool): now supports configuring a second monitor (on the Pi4), and also setting the WiFi regulatory domain (RPi3/4). A simple overclocking "manettino" ^-^ for the Pi4 is also provided (all permitted settings should be warranty-safe, per RPF advice, but use at your own risk!).
- Updated the media-video/pi-ffcam "camera live view" applet to work with the Pi4 (found in the Multimedia menu).
- Also updated the media/video/pi-ffplay application for the Pi4 (again found in the Multimedia menu, this is a trivial app to illustrate accessing the Pi 3/4's hardware video codecs via v4l2m2m).
- Moved 6by9's patches to media-video/ffmpeg (upon which the two apps above rely) forward to version 4.1.4, as these don't seem to be upstream yet.
- Tidied up a number of boot-time services for RPi4 compatibility (e.g., x11-misc/rpi3-safecompositor etc.). Note that for simplicity I have not renamed these, so please don't disable or remove services just because their name starts with "rpi3-" (as for the most part, they still do something useful on an RPi4 too!).
- I did change the name of the main repo used by the image though, from "rpi3" to "genpi64", and migrated the custom profile too. You can read more about this here.
- Version bumped sys-boot/rpi3-boot-config, to update the baseline /boot/config.txt file for use with the Pi4 (while still retaining compatibility with the Pi3B/B+).
- Renamed the master meta-package, from rpi3-64bit-meta to rpi-64bit-meta.
- Added LLVM_TARGETS="WebAssembly BPF" (in addition to the default AArch64), to allow dev-lang/rust to be built with the wasm USE flag.
- Various minor ebuild tidy-ups.
- All packages brought up-to-date against the Gentoo tree, as of 10 August 2019 (which means e.g., www-client/firefox-68.0.1, www-client/chromium-76.0.3809.87-r1, app-office/libreoffice-6.3.0.4 etc. are bundled; a full list of installed packages may be found here).
A variant image for the Pi-Top v1 (an RPi3-based DIY laptop) is also included, as usual.
I also aim to provide PINN versions of both these images shortly, for those that prefer that installation route.
Have fun ^-^
And, as always, any problems or comments, please post either in this thread, or in the project's thread on the Raspberry Pi forums (
here).
PS: Updated EEPROM Firmware
If you are using a Pi4, don't forget to update your EEPROM firmware; there's an official fix released that will allow your system to use ~300mW less power. For more information, please see
here.
PPS: USB Shortcomings
As this release comes early in the lifecycle of the RPi4, expect to find a number of bugs and issues with it! In particular, one major issue, (due, as I understand it, per
this post by 6by9, to a lack of FIQ fast interrupt handling on aarch64) is that
isochronous transfers over USB are likely to be pretty bad in 64-bit compared to 32-bit. For example, USB webcams etc will drop frames (
bulk transfers, as you might get e.g. when copying large files to and from a storage device, work fine on USB under 64-bit however; as do low-speed peripherals such as mice and keyboards).
Acknowledgement
Thanks to NeddySeagoon for maintaining his public
bloodnoc.org armv8a binhost - I needed to do a full --emptytree @world rebuild as part of this image prep, which highlighted quite a few issues (packages that no longer built from source properly, but had tbz2s in my
isshoni.org binhost and so didn't show up in regular @world updates) - having his tbz2's to check build settings against (qtbz2 and qxpak are your friends!) was a really useful resource!
Edited to add acknowledgement.