8 ms·
Building a 64-bit aarch64 kernel and userspace for the Raspberry Pi 4
- bobowzki 7y agoUbuntu also has a nice aarch64 image for raspberry pi 4.
- tssva 7y agoThe Ubuntu image currently doesn't support USB on the 4GB model unless you configure the kernel to only use 3 of the 4GB.
- DoofusOfDeath 7y agoThanks for mentioning that! You probably just saved me a few wasted hours.
- DoofusOfDeath 7y agoStatus update on that bug: https://www.cnx-software.com/2019/11/04/raspberry-pi-4-4gb-models-usb-ports-dont-work-on-ubuntu-19-10/ https://www.cnx-software.com/2019/11/04/raspberry-pi-4-4gb-m...
- bobowzki 7y agoHope they fix that soon!
- esotericn 7y agoThey're using 5.3.0 which isn't supported by the RPi Foundation yet. The 4.19 line had an issue with RAM too but it's been fixed now so if you build from git it's fine. I'm running on 4gb.
- qubex 7y agoI understand the logic behind the Raspberry Pi Foundation’s decision to continue releasing a single Raspberrian version in 32-bit mode for compatibility reasons, but... on the other hand, it does severely handicap their newer hardware.
- codetrotter 7y agoI think a big part of the reason is also the fact that several parts of the userland don’t compile for aarch64. See e.g. https://github.com/raspberrypi/userland/issues/314 https://github.com/raspberrypi/userland/issues/314 One of the first comments there also say about the RPi 3: > The GPU is a 32 bit processor. I haven't checked, but I'm expecting that there's a heck of a lot more work to do to get Khronos or other multimedia extension stuff up and running against a 64bit kernel than just getting userland to build. Don’t know if that’s the case for the RPi 4 as well. And another comment too: > I'm sure there are certain applications where having a 64-bit kernel (let alone userland) may be beneficial, but I suspect the hoped-for performance improvements didn't materialise, otherwise people would be waving benchmark results at us demanding an RPi-supported aarch64 kernel. I’m missing this too, and am planning on eventually doing some benchmarking of my own to see if there is any advantage of running the aarch64 kernel for my applications.
- Avamander 7y agoThere's a full 64-bit Gentoo image available. It seems to work fine for all my use-cases. I'm not sure which parts of your comments really apply at this point in time.
- codetrotter 7y agoHardware accelerated OpenGL. As far as I have been able to tell, that will still be missing if you run an aarch64 kernel. And I think using the GPU to get hardware accelerated video decoding and encoding will not be available either. Edit: But if I understand https://github.com/popcornmix/omxplayer/issues/714 https://github.com/popcornmix/omxplayer/issues/714 correctly then you could do hardware accelerated decoding of HEVC on the CPU. I don’t know how the performance of that compares to the kind of video decoding that the GPU can do. That’s one of the things I’d like to see someone benchmark, or benchmark myself.
- bootloop 7y agoThat was the case but the VC4 instruction set is open/documented and there is a Mesa driver worked on to REPLACE the closed binary driver which is only available for 32-bit. When you use the Mesa VC4 driver you can also compile the whole user space for 64 bit including OpenGL ES support in a even newer version then the closed source one. (Supporting user kernels etc.) You can find some info about that here: https://wiki.gentoo.org/wiki/Raspberry_Pi_VC4 https://wiki.gentoo.org/wiki/Raspberry_Pi_VC4 Some side notes: Mesa is quite hungry in performance and memory to compile shaders (to VC4 instructions), way more then the closed driver requires, thats why older versions of the Pi with less powerfull ARM cores couldn't really use this approach. Source: I used to write custom user shaders in VC4 assembly to run on all Pis because the closed binary didn't offer OpenCL.
- Jonnax 7y agoWhat's the performance difference between 32 and 64 bit?
- qubex 7y agohttps://m.youtube.com/watch?v=cPk1pvgK7JA https://m.youtube.com/watch?v=cPk1pvgK7JA
- pantalaimon 7y agoIs there something like x32 for ARM?
- my123 7y agoYes, aarch64-ilp32. It's used in production for Apple Watch Series 4 onwards among other things.
- Vogtinator 7y agoFor openSUSE there's an aarch64 image as well: https://en.opensuse.org/HCL:Raspberry_Pi4 https://en.opensuse.org/HCL:Raspberry_Pi4 It uses mainline Linux, so no USB 3 (only USB 2 OTG/Gadget/Host on USB-C), but Ethernet is supposed to be working meanwhile.
- Abishek_Muthian 7y agoBtw, for those who are using RPi3 and want to try aarch64 kernel -archlinux|ARM has one and I've used it in my experiments to getting smoother desktop experience on Raspberry Pi[1]. [1]:https://abishekmuthian.com/getting-smoother-desktop-experience-on-raspberry-pi/ https://abishekmuthian.com/getting-smoother-desktop-experien...
- boris 7y agoSlightly off-topic: is there anything that is as or more powerful than RPi4 but has more/expandable memory (say 16G or more) and still works with mainline kernel/distributions? In other words, something that I could setup as a build machine for CI?
- numlock86 7y agoWell, any PC? What are your conditions? Price? Size?
- zamadatix 7y agoRealistically you probably want to just use QEMU for builds until you find yourself needing to scale to something like https://www.packet.com/cloud/servers/c1-large-arm/ https://www.packet.com/cloud/servers/c1-large-arm/ If you're doing it just for the novelty or really want to do it on site natively at a reasonable cost check out the Jetson TX2 dev kit. The TX2 has been mainlined for a while now and this kit offers 8 GB RAM with a fast CPU and the ability to connect fast SATA/NVMe storage. While most distros would run on it you would probably need to make your own install package (or just run container images for builds if you don't NEED to have an exact kernel)
- wmf 7y agohttps://www.solid-run.com/nxp-lx2160a-family/honeycomb-workstation/ https://www.solid-run.com/nxp-lx2160a-family/honeycomb-works... ?
- boris 7y agoThis looks promising (even at $750 for the motherboard and CPU) but it seems to be a work in progress, specifically at the bottom of the page it says: Mainline Kernel – work in progress UBoot – work in progress UEFI – work in progress But if anyone has any experience using this board, please share.
- kick 7y agoWhy not just build a CI machine? At a $750 price point, you could very easily build a fantastic one with half an hour's worth of work.
- navigatr 7y agoIs the RPi4 mainlined in the kernel, or does the board require porting new kernel versions?
- megous 7y agoIt doesn't seem it has dts file in 5.4 at all.
- adontz 7y agoI've found buildroot much easier to use.
- pizzazzaro 7y ago70 minutes on a threadripper? Someone forgot -j13 in his make command. And maybe forgot to "make menuconfig" first. There is no reason on this Earth why threadripper should take 70 minutes to compile a kernel meant for a single specific board. Ever.