mirror of
git://git.yoctoproject.org/meta-raspberrypi.git
synced 2025-07-19 12:59:03 +02:00
Add Raspberry Pi 5
Backport Raspberry Pi 5 support to branch kirkstone. This work was sponsored by GOVCERT.LU. Signed-off-by: Leon Anavi <leon.anavi@konsulko.com>
This commit is contained in:
parent
ab5815a2ca
commit
9dc6673d41
1
.github/workflows/yocto-builds.yml
vendored
1
.github/workflows/yocto-builds.yml
vendored
|
@ -23,6 +23,7 @@ jobs:
|
|||
- raspberrypi3
|
||||
- raspberrypi4-64
|
||||
- raspberrypi4
|
||||
- raspberrypi5
|
||||
- raspberrypi-cm3
|
||||
- raspberrypi-cm
|
||||
image: [rpi-test-image]
|
||||
|
|
|
@ -58,6 +58,10 @@ RPI_KERNEL_DEVICETREE_OVERLAYS ?= " \
|
|||
overlays/wm8960-soundcard.dtbo \
|
||||
"
|
||||
|
||||
RPI_KERNEL_DEVICETREE_OVERLAYS:append:raspberrypi5 = " \
|
||||
overlays/vc4-kms-v3d-pi5.dtbo \
|
||||
"
|
||||
|
||||
RPI_KERNEL_DEVICETREE ?= " \
|
||||
bcm2708-rpi-zero.dtb \
|
||||
bcm2708-rpi-zero-w.dtb \
|
||||
|
@ -73,6 +77,7 @@ RPI_KERNEL_DEVICETREE ?= " \
|
|||
bcm2708-rpi-cm.dtb \
|
||||
bcm2710-rpi-cm3.dtb \
|
||||
bcm2711-rpi-cm4.dtb \
|
||||
bcm2711-rpi-cm4s.dtb \
|
||||
"
|
||||
|
||||
KERNEL_DEVICETREE ??= " \
|
||||
|
|
46
conf/machine/raspberrypi-armv8.conf
Normal file
46
conf/machine/raspberrypi-armv8.conf
Normal file
|
@ -0,0 +1,46 @@
|
|||
# SPDX-FileCopyrightText: Andrei Gherzan <andrei.gherzan@huawei.com>
|
||||
#
|
||||
# SPDX-License-Identifier: MIT
|
||||
|
||||
#@TYPE: Machine
|
||||
#@NAME: RaspberryPi Development Boards (64bit)
|
||||
#@DESCRIPTION: Machine configuration for the RaspberryPi boards in 64 bit mode
|
||||
|
||||
require conf/machine/include/arm/armv8a/tune-cortexa53.inc
|
||||
include conf/machine/include/rpi-base.inc
|
||||
|
||||
MACHINE_FEATURES += "pci"
|
||||
MACHINE_EXTRA_RRECOMMENDS += "\
|
||||
linux-firmware-rpidistro-bcm43430 \
|
||||
linux-firmware-rpidistro-bcm43455 \
|
||||
linux-firmware-rpidistro-bcm43456 \
|
||||
linux-firmware-rpidistro-bcm43436 \
|
||||
linux-firmware-rpidistro-bcm43436s \
|
||||
bluez-firmware-rpidistro-bcm43430a1-hcd \
|
||||
bluez-firmware-rpidistro-bcm43430b0-hcd \
|
||||
bluez-firmware-rpidistro-bcm4345c0-hcd \
|
||||
bluez-firmware-rpidistro-bcm4345c5-hcd \
|
||||
"
|
||||
|
||||
RPI_KERNEL_DEVICETREE = " \
|
||||
broadcom/bcm2710-rpi-3-b.dtb \
|
||||
broadcom/bcm2710-rpi-3-b-plus.dtb \
|
||||
broadcom/bcm2837-rpi-3-b.dtb \
|
||||
broadcom/bcm2710-rpi-cm3.dtb \
|
||||
broadcom/bcm2710-rpi-zero-2.dtb \
|
||||
broadcom/bcm2711-rpi-4-b.dtb \
|
||||
broadcom/bcm2711-rpi-400.dtb \
|
||||
broadcom/bcm2711-rpi-cm4.dtb \
|
||||
broadcom/bcm2711-rpi-cm4s.dtb \
|
||||
"
|
||||
|
||||
RPI_KERNEL_DEVICETREE:append:raspberrypi5 = " broadcom/bcm2712-rpi-5-b.dtb"
|
||||
|
||||
SDIMG_KERNELIMAGE ?= "kernel8.img"
|
||||
KERNEL_IMAGETYPE_UBOOT ?= "Image"
|
||||
KERNEL_IMAGETYPE_DIRECT ?= "Image"
|
||||
KERNEL_BOOTCMD ?= "booti"
|
||||
UBOOT_MACHINE = "rpi_arm64_config"
|
||||
SERIAL_CONSOLES ?= "115200;ttyS0"
|
||||
|
||||
VC4DTBO ?= "vc4-fkms-v3d"
|
32
conf/machine/raspberrypi5.conf
Normal file
32
conf/machine/raspberrypi5.conf
Normal file
|
@ -0,0 +1,32 @@
|
|||
#@TYPE: Machine
|
||||
#@NAME: RaspberryPi 5 Development Board (64bit)
|
||||
#@DESCRIPTION: Machine configuration for the RaspberryPi 5 in 64 bits mode
|
||||
|
||||
require conf/machine/include/arm/armv8-2a/tune-cortexa76.inc
|
||||
include conf/machine/include/rpi-base.inc
|
||||
|
||||
PREFERRED_VERSION_linux-raspberrypi = "6.1%"
|
||||
|
||||
MACHINE_FEATURES += "pci"
|
||||
MACHINE_EXTRA_RRECOMMENDS += "\
|
||||
linux-firmware-rpidistro-bcm43455 \
|
||||
bluez-firmware-rpidistro-bcm4345c0-hcd \
|
||||
linux-firmware-rpidistro-bcm43456 \
|
||||
bluez-firmware-rpidistro-bcm4345c5-hcd \
|
||||
"
|
||||
|
||||
RPI_KERNEL_DEVICETREE = " \
|
||||
broadcom/bcm2712-rpi-5-b.dtb \
|
||||
"
|
||||
|
||||
SDIMG_KERNELIMAGE ?= "kernel_2712.img"
|
||||
SERIAL_CONSOLES ?= "115200;ttyAMA10"
|
||||
|
||||
VC4DTBO ?= "vc4-kms-v3d"
|
||||
|
||||
# When u-boot is enabled we need to use the "Image" format and the "booti"
|
||||
# command to load the kernel
|
||||
KERNEL_IMAGETYPE_UBOOT ?= "Image"
|
||||
# "zImage" not supported on arm64 and ".gz" images not supported by bootloader yet
|
||||
KERNEL_IMAGETYPE_DIRECT ?= "Image"
|
||||
KERNEL_BOOTCMD ?= "booti"
|
|
@ -292,6 +292,19 @@ do_deploy() {
|
|||
echo "# Enable WM8960" >> $CONFIG
|
||||
echo "dtoverlay=wm8960-soundcard" >> $CONFIG
|
||||
fi
|
||||
|
||||
# W1-GPIO - One-Wire Interface
|
||||
if [ "${ENABLE_W1}" = "1" ]; then
|
||||
echo "# Enable One-Wire Interface" >> $CONFIG
|
||||
echo "dtoverlay=w1-gpio" >> $CONFIG
|
||||
fi
|
||||
|
||||
# Reduce config.txt file size to avoid corruption and
|
||||
# to boot successfully Raspberry Pi 5. The issue has
|
||||
# been reported to related projects:
|
||||
# https://github.com/raspberrypi/firmware/issues/1848
|
||||
# https://github.com/Evilpaul/RPi-config/issues/9
|
||||
sed -i '/^##/d' $CONFIG
|
||||
}
|
||||
|
||||
do_deploy:append:raspberrypi3-64() {
|
||||
|
|
|
@ -12,3 +12,6 @@ do_install:append:rpi () {
|
|||
install -d ${D}${sysconfdir}
|
||||
install -m 0644 ${WORKDIR}/fw_env.config ${D}${sysconfdir}/fw_env.config
|
||||
}
|
||||
|
||||
# Temporary avoid Raspberry Pi 5 because U-Boot has not been ported yet
|
||||
COMPATIBLE_MACHINE:raspberrypi5 = "(-)"
|
||||
|
|
|
@ -27,6 +27,9 @@ KBUILD_DEFCONFIG:raspberrypi3 ?= "bcm2709_defconfig"
|
|||
KBUILD_DEFCONFIG:raspberrypi3-64 ?= "bcmrpi3_defconfig"
|
||||
KBUILD_DEFCONFIG:raspberrypi4 ?= "bcm2711_defconfig"
|
||||
KBUILD_DEFCONFIG:raspberrypi4-64 ?= "bcm2711_defconfig"
|
||||
KBUILD_DEFCONFIG:raspberrypi-armv7 ?= "bcm2711_defconfig"
|
||||
KBUILD_DEFCONFIG:raspberrypi-armv8 ?= "bcm2711_defconfig"
|
||||
KBUILD_DEFCONFIG:raspberrypi5 ?= "bcm2712_defconfig"
|
||||
|
||||
LINUX_VERSION_EXTENSION ?= ""
|
||||
|
||||
|
|
31
recipes-kernel/linux/linux-raspberrypi_6.1.bb
Normal file
31
recipes-kernel/linux/linux-raspberrypi_6.1.bb
Normal file
|
@ -0,0 +1,31 @@
|
|||
LINUX_VERSION ?= "6.1.61"
|
||||
LINUX_RPI_BRANCH ?= "rpi-6.1.y"
|
||||
LINUX_RPI_KMETA_BRANCH ?= "yocto-6.1"
|
||||
|
||||
SRCREV_machine = "f364e0eb8f973e1aa24a3c451d18e84247a8efcd"
|
||||
SRCREV_meta = "29ec3dc6f4f59b731badcc864b212767023cc40c"
|
||||
|
||||
KMETA = "kernel-meta"
|
||||
|
||||
SRC_URI = " \
|
||||
git://github.com/raspberrypi/linux.git;name=machine;branch=${LINUX_RPI_BRANCH};protocol=https \
|
||||
git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=${LINUX_RPI_KMETA_BRANCH};destsuffix=${KMETA} \
|
||||
file://powersave.cfg \
|
||||
file://android-drivers.cfg \
|
||||
"
|
||||
|
||||
require linux-raspberrypi.inc
|
||||
|
||||
KERNEL_DTC_FLAGS += "-@ -H epapr"
|
||||
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-base:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-base"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-image:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-image"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-dev:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-dev"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-vmlinux:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-vmlinux"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-modules:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-modules"
|
||||
RDEPENDS:${KERNEL_PACKAGE_NAME}-dbg:raspberrypi-armv7:append = " ${RASPBERRYPI_v7_KERNEL_PACKAGE_NAME}-dbg"
|
||||
|
||||
DEPLOYDEP = ""
|
||||
DEPLOYDEP:raspberrypi-armv7 = "${RASPBERRYPI_v7_KERNEL}:do_deploy"
|
||||
do_deploy[depends] += "${DEPLOYDEP}"
|
Loading…
Reference in New Issue
Block a user