Edit Info Other
Login

RaspberryPi"

Differences between revisions 11 and 12
Revision 11 as of 2021-06-26 10:06:52
Size: 4432
Editor: DamianWrobel
Comment: Improve information about updating Raspberry Pi 4 bootloader EEPROM
Revision 12 as of 2021-07-29 17:03:43
Size: 4855
Editor: DamianWrobel
Comment: Add info about uboot-tools packge affecting kernel upgrade
Deletions are marked like this. Additions are marked like this.
Line 53: Line 53:
=== Sysctl === === Sysctl (RPi 3 only) ===
Line 62: Line 62:
 * uboot-tools prevents clean update of kernel packages
The "/usr/lib/kernel/install.d/10-devicetree.install" script from uboot-tools package prevents older kernel packages from being removed cleanly during update:
{{{
  Erasing : kernel-core-5.10.35-1.rpi.fc33.armv7hl
warning: file /lib/modules/5.10.35-1.rpi.fc33.armv7hl/modules.builtin.alias.bin: remove failed: No such file or directory
}}}
To mitigate it run the following command:
{{{
$ echo "FIRMWAREDT=True" | sudo tee /etc/u-boot.conf
}}}
Line 66: Line 77:
 * You can report to our bugzilla, see [[ReportingBugs]], please mention using downstream kernel/components.

About this Howto

This documentation is about using Raspberry Pi Foundation "downstream kernel" and components on a Fedora (or CentOS) userspace. As with Fedora, this process is compatible with Raspberry Pi 2 and later model (No original Raspberry Pi or Pi Zero support is planned). Unless using a Raspberry Pi 4 with 4G of RAM. It's recommended to use the 32bit version over the 64bit (especially for the Workstation flavor). For graphics usage, it's really recommended to have a Raspberry Pi 4 which default to the vc4/v3d driver.

Kickstart files

Kickstart files are located at https://pagure.io/fork/dwrobel/fedora-kickstarts repository and are based on the original Fedora 34 files with the following modifications:

  • component

    Repositories

    comment

    kernel

    spec / copr

    Downstream kernel

    bcm434xx-firmware

    spec / copr

    bcm283x-firmware

    spec / copr

    pykickstart

    PR / copr

    Adds --priority=<priority>

    livecd-tools

    PR / copr

    Adds support for repository 'priority' configuration

The modifications in livecd-tools and pykickstart allows to generate image with selected downstream kernel (despite it has lower version) over the upstream one. On a system, all aforementioned repositories are installed with priority=50 option to instruct 'dnf' to choose packages from this repository, rather then Fedora default.

Pre-built images

The location of pre-generated images for Fedora 34 can be found below:

Flavor

armv7hl

aarch64

Server

image / checksum

image / checksum

Workstation

image / checksum

image / checksum

Raspberry Pi specific RPM Fusion RPI Repositories on Fedora

sudo dnf config-manager --add-repo=https://mirrors.rpmfusion.org/free/fedora/rpi/rpmfusion-rpi.repo
sudo dnf install raspberrypi-vc-utils raspberrypi-vc-libs

Updating Raspberry Pi 4 bootloader EEPROM

Follow the gist available at: https://gist.github.com/dwrobel/266ad5d4e59b05ea26d8bb6725118578.

Configurations

Booting from external USB drive

Write the image to the external drive, then mount the filesystem and change root=/dev/mmcblk0p2 to root=/dev/sda2 in the /boot/efi/cmdline.txt.

Resizing filesystem

After booting the system, please consider to resize the filesystem. The following example assumes system booted from internal SD card.

sudo growpart -u on /dev/mmcblk0 2
sudo btrfs filesystem resize max /

Sysctl (RPi 3 only)

# set vm.min_free_kbytes for rpi
cat>/etc/sysctl.d/98-rpi.conf<<EOF
vm.min_free_kbytes = 16384
EOF

Known issues

  • uboot-tools prevents clean update of kernel packages

The "/usr/lib/kernel/install.d/10-devicetree.install" script from uboot-tools package prevents older kernel packages from being removed cleanly during update:

  Erasing          : kernel-core-5.10.35-1.rpi.fc33.armv7hl
warning: file /lib/modules/5.10.35-1.rpi.fc33.armv7hl/modules.builtin.alias.bin: remove failed: No such file or directory

To mitigate it run the following command:

$ echo "FIRMWAREDT=True" | sudo tee /etc/u-boot.conf
  • There is a CMA memory allocation issue with graphics on the Pi3 using vc4, best is to disable vc4 (will be un-accelerated).

Bug Report


CategoryHowto

Howto/RaspberryPi (last edited 2024-04-24 07:23:36 by DamianWrobel)