diff options
Diffstat (limited to 'meta-raspberrypi')
57 files changed, 666 insertions, 244 deletions
diff --git a/meta-raspberrypi/README.md b/meta-raspberrypi/README.md index 898426d8f..e69b0effb 100644 --- a/meta-raspberrypi/README.md +++ b/meta-raspberrypi/README.md @@ -28,7 +28,7 @@ The core BSP part of meta-raspberrypi should work with different OpenEmbedded/Yocto distributions and layer stacks, such as: * Distro-less (only with OE-Core). -* Angstrom. +* Yoe Disto (Video and Camera Products). * Yocto/Poky (main focus of testing). ## Dependencies diff --git a/meta-raspberrypi/classes/sdcard_image-rpi.bbclass b/meta-raspberrypi/classes/sdcard_image-rpi.bbclass index 43426b275..8197978a3 100644 --- a/meta-raspberrypi/classes/sdcard_image-rpi.bbclass +++ b/meta-raspberrypi/classes/sdcard_image-rpi.bbclass @@ -26,7 +26,7 @@ inherit image_types IMAGE_TYPEDEP_rpi-sdimg = "${SDIMG_ROOTFS_TYPE}" # Set kernel and boot loader -IMAGE_BOOTLOADER ?= "bcm2835-bootfiles" +IMAGE_BOOTLOADER ?= "bootfiles" # Kernel image name SDIMG_KERNELIMAGE_raspberrypi ?= "kernel.img" @@ -49,6 +49,8 @@ SDIMG_ROOTFS = "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${SDIMG_ROOTFS_TYPE}" # For the names of kernel artifacts inherit kernel-artifact-names +RPI_SDIMG_EXTRA_DEPENDS ?= "" + do_image_rpi_sdimg[depends] = " \ parted-native:do_populate_sysroot \ mtools-native:do_populate_sysroot \ @@ -59,6 +61,7 @@ do_image_rpi_sdimg[depends] = " \ ${@bb.utils.contains('MACHINE_FEATURES', 'armstub', 'armstubs:do_deploy', '' ,d)} \ ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \ ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot-default-script:do_deploy', '',d)} \ + ${RPI_SDIMG_EXTRA_DEPENDS} \ " do_image_rpi_sdimg[recrdeps] = "do_build" @@ -114,7 +117,7 @@ IMAGE_CMD_rpi-sdimg () { BOOT_BLOCKS=$(LC_ALL=C parted -s ${SDIMG} unit b print | awk '/ 1 / { print substr($4, 1, length($4 -1)) / 512 /2 }') rm -f ${WORKDIR}/boot.img mkfs.vfat -F32 -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS - mcopy -v -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles/* ::/ || bbfatal "mcopy cannot copy ${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles/* into boot.img" + mcopy -v -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${BOOTFILES_DIR_NAME}/* ::/ || bbfatal "mcopy cannot copy ${DEPLOY_DIR_IMAGE}/${BOOTFILES_DIR_NAME}/* into boot.img" if [ "${@bb.utils.contains("MACHINE_FEATURES", "armstub", "1", "0", d)}" = "1" ]; then mcopy -v -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/armstubs/${ARMSTUB} ::/ || bbfatal "mcopy cannot copy ${DEPLOY_DIR_IMAGE}/armstubs/${ARMSTUB} into boot.img" fi @@ -148,6 +151,22 @@ IMAGE_CMD_rpi-sdimg () { fi fi + # Add files (eg. hypervisor binaries) from the deploy dir + if [ -n "${DEPLOYPAYLOAD}" ] ; then + echo "Copying deploy file payload into VFAT" + for entry in ${DEPLOYPAYLOAD} ; do + # Split entry at optional ':' to enable file renaming for the destination + if [ $(echo "$entry" | grep -c :) = "0" ] ; then + DEPLOY_FILE="$entry" + DEST_FILENAME="$entry" + else + DEPLOY_FILE="$(echo "$entry" | cut -f1 -d:)" + DEST_FILENAME="$(echo "$entry" | cut -f2- -d:)" + fi + mcopy -v -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${DEPLOY_FILE} ::${DEST_FILENAME} || bbfatal "mcopy cannot copy ${DEPLOY_DIR_IMAGE}/${DEPLOY_FILE} into boot.img" + done + fi + if [ -n "${FATPAYLOAD}" ] ; then echo "Copying payload into VFAT" for entry in ${FATPAYLOAD} ; do diff --git a/meta-raspberrypi/conf/layer.conf b/meta-raspberrypi/conf/layer.conf index 4ed79591f..98cd6f460 100644 --- a/meta-raspberrypi/conf/layer.conf +++ b/meta-raspberrypi/conf/layer.conf @@ -9,7 +9,7 @@ BBFILE_COLLECTIONS += "raspberrypi" BBFILE_PATTERN_raspberrypi := "^${LAYERDIR}/" BBFILE_PRIORITY_raspberrypi = "9" -LAYERSERIES_COMPAT_raspberrypi = "sumo thud warrior zeus dunfell" +LAYERSERIES_COMPAT_raspberrypi = "sumo thud warrior zeus dunfell gatesgarth" # Additional license directories. LICENSE_PATH += "${LAYERDIR}/files/custom-licenses" @@ -31,6 +31,8 @@ BBFILES_DYNAMIC += " \ networking-layer:${LAYERDIR}/dynamic-layers/networking-layer/*/*/*.bbappend \ qt5-layer:${LAYERDIR}/dynamic-layers/qt5-layer/*/*/*.bb \ qt5-layer:${LAYERDIR}/dynamic-layers/qt5-layer/*/*/*.bbappend \ + multimedia-layer:${LAYERDIR}/dynamic-layers/multimedia-layer/*/*/*.bb \ + multimedia-layer:${LAYERDIR}/dynamic-layers/multimedia-layer/*/*/*.bbappend \ " DEFAULT_TEST_SUITES_remove_rpi = "parselogs" diff --git a/meta-raspberrypi/conf/machine/include/rpi-base.inc b/meta-raspberrypi/conf/machine/include/rpi-base.inc index 7a87bd13a..cd6d0b0f2 100644 --- a/meta-raspberrypi/conf/machine/include/rpi-base.inc +++ b/meta-raspberrypi/conf/machine/include/rpi-base.inc @@ -28,6 +28,7 @@ RPI_KERNEL_DEVICETREE_OVERLAYS ?= " \ overlays/iqaudio-dacplus.dtbo \ overlays/miniuart-bt.dtbo \ overlays/mcp2515-can0.dtbo \ + overlays/mcp2515-can1.dtbo \ overlays/pitft22.dtbo \ overlays/pitft28-resistive.dtbo \ overlays/pitft28-capacitive.dtbo \ @@ -39,6 +40,8 @@ RPI_KERNEL_DEVICETREE_OVERLAYS ?= " \ overlays/vc4-fkms-v3d.dtbo \ overlays/w1-gpio-pullup.dtbo \ overlays/w1-gpio.dtbo \ + overlays/gpio-ir.dtbo \ + overlays/gpio-ir-tx.dtbo \ " RPI_KERNEL_DEVICETREE ?= " \ @@ -78,7 +81,13 @@ MACHINE_FEATURES_BACKFILL_CONSIDERED = "rtc" MACHINE_EXTRA_RRECOMMENDS += "kernel-modules udev-rules-rpi" MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "${@oe.utils.conditional('ENABLE_I2C', '1', 'kernel-module-i2c-dev kernel-module-i2c-bcm2708', '', d)}" +MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "${@oe.utils.conditional('ENABLE_IR', '1', 'kernel-module-gpio-ir kernel-module-gpio-ir-tx', '', d)}" +SERIAL_CONSOLES_CHECK ??= "${SERIAL_CONSOLES}" + +# The name of the deploy directory for raspberry pi boot files. +# This variable is referred to by recipes fetching / generating the files. +BOOTFILES_DIR_NAME ?= "bootfiles" # Set Raspberrypi splash image SPLASH = "psplash-raspberrypi" @@ -106,14 +115,14 @@ def make_dtb_boot_files(d): return ' '.join([transform(dtb) for dtb in alldtbs.split(' ') if dtb]) -IMAGE_BOOT_FILES ?= "bcm2835-bootfiles/* \ +IMAGE_BOOT_FILES ?= "${BOOTFILES_DIR_NAME}/* \ ${@make_dtb_boot_files(d)} \ ${@bb.utils.contains('RPI_USE_U_BOOT', '1', \ '${KERNEL_IMAGETYPE} u-boot.bin;${SDIMG_KERNELIMAGE} boot.scr', \ '${KERNEL_IMAGETYPE};${SDIMG_KERNELIMAGE}', d)} \ " do_image_wic[depends] += " \ - bcm2835-bootfiles:do_deploy \ + bootfiles:do_deploy \ ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \ " diff --git a/meta-raspberrypi/conf/machine/include/rpi-default-settings.inc b/meta-raspberrypi/conf/machine/include/rpi-default-settings.inc index 716a8bbb7..bb18496c9 100644 --- a/meta-raspberrypi/conf/machine/include/rpi-default-settings.inc +++ b/meta-raspberrypi/conf/machine/include/rpi-default-settings.inc @@ -1,3 +1,9 @@ # RaspberryPi BSP default settings IMAGE_CLASSES += "sdcard_image-rpi" + +# RPI kernel has errors of its own which should be filtered +# therefore use parselogs_rpi test instead of parselogs from oe-core +# +DEFAULT_TEST_SUITES_append_rpi = " parselogs_rpi" +DEFAULT_TEST_SUITES_remove_rpi = " parselogs" diff --git a/meta-raspberrypi/conf/machine/include/rpi-default-versions.inc b/meta-raspberrypi/conf/machine/include/rpi-default-versions.inc index 9983b61a6..e57c702b3 100644 --- a/meta-raspberrypi/conf/machine/include/rpi-default-versions.inc +++ b/meta-raspberrypi/conf/machine/include/rpi-default-versions.inc @@ -1,3 +1,3 @@ # RaspberryPi BSP default versions -PREFERRED_VERSION_linux-raspberrypi ??= "4.19.%" +PREFERRED_VERSION_linux-raspberrypi ??= "5.4.%" diff --git a/meta-raspberrypi/docs/extra-build-config.md b/meta-raspberrypi/docs/extra-build-config.md index 843247aaa..84601848e 100644 --- a/meta-raspberrypi/docs/extra-build-config.md +++ b/meta-raspberrypi/docs/extra-build-config.md @@ -1,6 +1,6 @@ # Optional build configuration -There are a set of ways in which a user can influence different paramenters of +There are a set of ways in which a user can influence different parameters of the build. We list here the ones that are closely related to this BSP or specific to it. For the rest please check: <http://www.yoctoproject.org/docs/latest/ref-manual/ref-manual.html> @@ -37,7 +37,7 @@ By default, each machine uses `vc4` for graphics. This will in turn sets mesa as ## Add purchased license codecs -To add you own licenses use variables `KEY_DECODE_MPG2` and `KEY_DECODE_WVC1` in +To add your own licenses use variables `KEY_DECODE_MPG2` and `KEY_DECODE_WVC1` in local.conf. Example: KEY_DECODE_MPG2 = "12345678" @@ -77,7 +77,7 @@ To remove (or adjust) this delay set these variables in local.conf: ## Set overclocking options The Raspberry Pi can be overclocked. As of now overclocking up to the "Turbo -Mode" is officially supported by the raspbery and does not void warranty. Check +Mode" is officially supported by the Raspberry Pi and does not void warranty. Check the config.txt for a detailed description of options and modes. The following variables are supported in local.conf: `ARM_FREQ`, `GPU_FREQ`, `CORE_FREQ`, `SDRAM_FREQ` and `OVER_VOLTAGE`. @@ -172,6 +172,31 @@ To build an initramfs image: - `INITRAMFS_MAXSIZE = "315400"` - `IMAGE_FSTYPES_pn-${INITRAMFS_IMAGE} = "${INITRAMFS_FSTYPES}"` +## Including additional files in the SD card image boot partition + +The SD card image class supports adding extra files into the boot +partition, where the files are copied from either the image root +partition or from the build image deploy directory. + +To copy files that are present in the root partition into boot, +FATPAYLOAD is a simple space-separated list of files to be copied: + + FATPAYLOAD = "/boot/example1 /boot/example2" + +To copy files from the image deploy directory, the files should be +listed in the DEPLOYPAYLOAD as a space-separated list of entries. +Each entry lists a file to be copied, and an optional destination +filename can be specified by supplying it after a colon separator. + + DEPLOYPAYLOAD = "example1-${MACHINE}:example1 example2" + +Files that are to be included from the deploy directory will be produced +by tasks that image building task must depend upon, to ensure that the +files are available when they are needed, so these component deploy +tasks must be added to: RPI_SDIMG_EXTRA_DEPENDS. + + RPI_SDIMG_EXTRA_DEPENDS_append = " example:do_deploy" + ## Enable SPI bus When using device tree kernels, set this variable to enable the SPI bus: @@ -224,7 +249,7 @@ Screen LCD, HDMI interface (<http://www.waveshare.com/7inch-HDMI-LCD-C.htm>) Rev RaspberryPi 0, 1, 2 and CM will have UART console enabled by default. RaspberryPi 0 WiFi and 3 does not have the UART enabled by default because this -needs a fixed core frequency and enable_uart wil set it to the minimum. Certain +needs a fixed core frequency and enable_uart will set it to the minimum. Certain operations - 60fps h264 decode, high quality deinterlace - which aren't performed on the ARM may be affected, and we wouldn't want to do that to users who don't want to use the serial port. Users who want serial console support on @@ -252,14 +277,39 @@ When using device tree kernels, set this variable to enable the 802.15.4 hat: See: <https://openlabs.co/OSHW/Raspberry-Pi-802.15.4-radio> -## Enable CAN with Pican2 +## Enable CAN -In order to use Pican2 CAN module, set the following variables: +In order to use CAN with an MCP2515-based module, set the following variables: ENABLE_SPI_BUS = "1" ENABLE_CAN = "1" -See: <http://skpang.co.uk/catalog/pican2-canbus-board-for-raspberry-pi-23-p-1475.html> +In case of dual CAN module (e.g. PiCAN2 Duo), set following variables instead: + + ENABLE_SPI_BUS = "1" + ENABLE_DUAL_CAN = "1" + +Some modules may require setting the frequency of the crystal oscillator used on the particular board. The frequency is usually marked on the package of the crystal. By default, it is set to 16 MHz. To change that to 8 MHz, the following variable also has to be set: + + CAN_OSCILLATOR="8000000" + +Tested modules: + +* PiCAN2 (16 MHz crystal): <http://skpang.co.uk/catalog/pican2-canbus-board-for-raspberry-pi-23-p-1475.html> +* WaveShare RS485 CAN HAT (8 MHz or 12 MHz crystal): <https://www.waveshare.com/rs485-can-hat.htm> +* PiCAN2 Duo (16 MHz crystal): <http://skpang.co.uk/catalog/pican2-duo-canbus-board-for-raspberry-pi-23-p-1480.html> + +## Enable infrared + +Users who want to enable infrared support, for example for using LIRC (Linux +Infrared Remote Control), have to explicitly set in local.conf: + + ENABLE_IR = "1" + +This will add device tree overlays gpio-ir and gpio-ir-tx to config.txt. +Appropriate kernel modules will be also included in the image. By default the +GPIO pin for gpio-ir is set to 18 and the pin for gpio-ir-tx is 17. Both pins +can be easily changed by modifying variables `GPIO_IR` and `GPIO_IR_TX`. ## Manual additions to config.txt diff --git a/meta-raspberrypi/docs/layer-contents.md b/meta-raspberrypi/docs/layer-contents.md index 14e6b996e..5483708d8 100644 --- a/meta-raspberrypi/docs/layer-contents.md +++ b/meta-raspberrypi/docs/layer-contents.md @@ -8,6 +8,8 @@ * raspberrypi2 * raspberrypi3 * raspberrypi3-64 (64 bit kernel & userspace) +* raspberrypi4 +* raspberrypi4-64 (64 bit kernel & userspace) * raspberrypi-cm (dummy alias for raspberrypi) * raspberrypi-cm3 diff --git a/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lirc-gpio-ir-0.10.patch b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lirc-gpio-ir-0.10.patch new file mode 100644 index 000000000..c0fdd189b --- /dev/null +++ b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lirc-gpio-ir-0.10.patch @@ -0,0 +1,175 @@ +diff -ruN lirc-0.10.1.orig/lib/config_file.c lirc-0.10.1/lib/config_file.c +--- lirc-0.10.1.orig/lib/config_file.c 2017-09-10 17:52:19.000000000 +0900 ++++ lirc-0.10.1/lib/config_file.c 2019-06-26 00:39:45.734320696 +0900 +@@ -71,7 +71,7 @@ + typedef void* (*array_guest_func)(void* item, void* arg); + + +-#define LINE_LEN 1024 ++#define LINE_LEN 4096 + #define MAX_INCLUDES 10 + + const char* whitespace = " \t"; +diff -ruN lirc-0.10.1.orig/lib/ir_remote.h lirc-0.10.1/lib/ir_remote.h +--- lirc-0.10.1.orig/lib/ir_remote.h 2017-09-10 17:52:19.000000000 +0900 ++++ lirc-0.10.1/lib/ir_remote.h 2019-06-26 00:39:45.714321224 +0900 +@@ -110,12 +110,17 @@ + + static inline int is_pulse(lirc_t data) + { +- return data & PULSE_BIT ? 1 : 0; ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_PULSE) ? 1 : 0; + } + + static inline int is_space(lirc_t data) + { +- return !is_pulse(data); ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_SPACE) ? 1 : 0; ++} ++ ++static inline int is_timeout(lirc_t data) ++{ ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_TIMEOUT) ? 1 : 0; + } + + static inline int has_repeat(const struct ir_remote* remote) +diff -ruN lirc-0.10.1.orig/lib/irrecord.c lirc-0.10.1/lib/irrecord.c +--- lirc-0.10.1.orig/lib/irrecord.c 2017-09-10 17:52:19.000000000 +0900 ++++ lirc-0.10.1/lib/irrecord.c 2019-06-26 00:39:45.724320960 +0900 +@@ -1398,9 +1398,16 @@ + state->retval = 0; + return STS_LEN_TIMEOUT; + } ++ if (is_timeout(state->data)) { ++ return STS_LEN_AGAIN; ++ } + state->count++; + if (state->mode == MODE_GET_GAP) { +- state->sum += state->data & PULSE_MASK; ++ if (state->sum != 0 || is_pulse(state->data)) { ++ state->sum += state->data & PULSE_MASK; ++ }else{ ++ return STS_LEN_AGAIN; ++ } + if (state->average == 0 && is_space(state->data)) { + if (state->data > 100000) { + state->sum = 0; +@@ -1472,6 +1479,10 @@ + state->keypresses = lastmaxcount; + return STS_LEN_AGAIN; + } else if (state->mode == MODE_HAVE_GAP) { ++ if (state->count==1 && is_space(state->data)) { ++ state->count = 0; ++ return STS_LEN_AGAIN; ++ } + if (state->count <= MAX_SIGNALS) { + signals[state->count - 1] = state->data & PULSE_MASK; + } else { +@@ -1510,7 +1521,7 @@ + /* such long pulses may appear with + * crappy hardware (receiver? / remote?) + */ +- else { ++ else if(is_pulse(state->data)) { + remote->gap = 0; + return STS_LEN_NO_GAP_FOUND; + } +@@ -1811,22 +1822,24 @@ + + static int raw_data_ok(struct button_state* btn_state) + { +- int r; ++ int r = 0; + int ref; + +- if (!is_space(btn_state->data)) { ++ if (is_pulse(btn_state->data)) { + r = 0; +- } else if (is_const(&remote)) { +- if (remote.gap > btn_state->sum) { +- ref = (remote.gap - btn_state->sum); +- ref *= (100 - remote.eps); +- ref /= 100; ++ } else if (is_space(btn_state->data)) { ++ if (is_const(&remote)) { ++ if (remote.gap > btn_state->sum) { ++ ref = (remote.gap - btn_state->sum); ++ ref *= (100 - remote.eps); ++ ref /= 100; ++ } else { ++ ref = 0; ++ } ++ r = btn_state->data > ref; + } else { +- ref = 0; ++ r = btn_state->data > (remote.gap * (100 - remote.eps)) / 100; + } +- r = btn_state->data > ref; +- } else { +- r = btn_state->data > (remote.gap * (100 - remote.eps)) / 100; + } + return r; + } +@@ -1970,7 +1983,7 @@ + btn_state->data = remote.gap; + } + if (btn_state->count == 0) { +- if (!is_space(btn_state->data) ++ if (is_pulse(btn_state->data) + || btn_state->data < + remote.gap - remote.gap * remote.eps / + 100) { +diff -ruN lirc-0.10.1.orig/lib/lirc/ir_remote.h lirc-0.10.1/lib/lirc/ir_remote.h +--- lirc-0.10.1.orig/lib/lirc/ir_remote.h 2017-09-10 17:52:58.000000000 +0900 ++++ lirc-0.10.1/lib/lirc/ir_remote.h 2019-06-26 00:39:45.724320960 +0900 +@@ -110,12 +110,17 @@ + + static inline int is_pulse(lirc_t data) + { +- return data & PULSE_BIT ? 1 : 0; ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_PULSE) ? 1 : 0; + } + + static inline int is_space(lirc_t data) + { +- return !is_pulse(data); ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_SPACE) ? 1 : 0; ++} ++ ++static inline int is_timeout(lirc_t data) ++{ ++ return ((data & LIRC_MODE2_MASK)==LIRC_MODE2_TIMEOUT) ? 1 : 0; + } + + static inline int has_repeat(const struct ir_remote* remote) +diff -ruN lirc-0.10.1.orig/tools/mode2.cpp lirc-0.10.1/tools/mode2.cpp +--- lirc-0.10.1.orig/tools/mode2.cpp 2017-09-10 17:52:19.000000000 +0900 ++++ lirc-0.10.1/tools/mode2.cpp 2019-06-26 00:45:38.840404976 +0900 +@@ -326,12 +326,24 @@ + void print_mode2_data(unsigned int data) + { + static int bitno = 1; ++ static bool leading_space = true; ++ unsigned int msg = data & LIRC_MODE2_MASK; + + switch (opt_dmode) { + case 0: +- printf("%s %u\n", ( +- data & PULSE_BIT) ? "pulse" : "space", +- (uint32_t)(data & PULSE_MASK)); ++ if (leading_space && msg == LIRC_MODE2_SPACE ) { ++ break; ++ } else { ++ leading_space = false; ++ } ++ if (msg == LIRC_MODE2_PULSE) { ++ printf("pulse %u\n", (__u32)(data & PULSE_MASK)); ++ } else if (msg == LIRC_MODE2_SPACE) { ++ printf("space %u\n", (__u32)(data & PULSE_MASK)); ++ } else if (msg == LIRC_MODE2_TIMEOUT) { ++ printf("timeout %u\n", (__u32)(data & PULSE_MASK)); ++ leading_space = true; ++ } + break; + case 1: { + /* print output like irrecord raw config file data */ diff --git a/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lircd.service b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lircd.service new file mode 100644 index 000000000..03ecbb065 --- /dev/null +++ b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc/lircd.service @@ -0,0 +1,11 @@ +[Unit] +Description=LIRC Infrared Signal Decoder +Wants=lircd-setup.service +After=network.target lircd-setup.service + +[Service] +Type=simple +ExecStart=/usr/sbin/lircd --nodaemon + +[Install] +WantedBy=multi-user.target diff --git a/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc_0.10.1.bbappend b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc_0.10.1.bbappend new file mode 100644 index 000000000..5d3ab4dfd --- /dev/null +++ b/meta-raspberrypi/dynamic-layers/meta-python/recipes-connectivity/lirc/lirc_0.10.1.bbappend @@ -0,0 +1,6 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" + +SRC_URI_append_rpi = " \ + file://lirc-gpio-ir-0.10.patch \ + file://lircd.service \ +" diff --git a/meta-raspberrypi/dynamic-layers/multimedia-layer/recipes-multimedia/libcamera/libcamera.bbappend b/meta-raspberrypi/dynamic-layers/multimedia-layer/recipes-multimedia/libcamera/libcamera.bbappend new file mode 100644 index 000000000..8076ac79e --- /dev/null +++ b/meta-raspberrypi/dynamic-layers/multimedia-layer/recipes-multimedia/libcamera/libcamera.bbappend @@ -0,0 +1,2 @@ +PACKAGECONFIG[raspberrypi] = "-Dpipelines=raspberrypi" +PACKAGECONFIG_append_rpi = " raspberrypi" diff --git a/meta-raspberrypi/lib/oeqa/runtime/cases/parselogs_rpi.py b/meta-raspberrypi/lib/oeqa/runtime/cases/parselogs_rpi.py index 5cf9af17c..4a9431034 100644 --- a/meta-raspberrypi/lib/oeqa/runtime/cases/parselogs_rpi.py +++ b/meta-raspberrypi/lib/oeqa/runtime/cases/parselogs_rpi.py @@ -4,6 +4,9 @@ rpi_errors = [ 'bcmgenet fd580000.genet: failed to get enet-eee clock', 'bcmgenet fd580000.genet: failed to get enet-wol clock', 'bcmgenet fd580000.genet: failed to get enet clock', + 'bcmgenet fd580000.ethernet: failed to get enet-eee clock', + 'bcmgenet fd580000.ethernet: failed to get enet-wol clock', + 'bcmgenet fd580000.ethernet: failed to get enet clock', ] ignore_errors['raspberrypi4'] = rpi_errors + common_errors diff --git a/meta-raspberrypi/recipes-bsp/bootfiles/bcm2835-bootfiles.bb b/meta-raspberrypi/recipes-bsp/bootfiles/bootfiles.bb index d20312c14..80e226d46 100644 --- a/meta-raspberrypi/recipes-bsp/bootfiles/bcm2835-bootfiles.bb +++ b/meta-raspberrypi/recipes-bsp/bootfiles/bootfiles.bb @@ -1,4 +1,4 @@ -DESCRIPTION = "Closed source binary files to help boot the ARM on the BCM2835." +DESCRIPTION = "Closed source binary files to help boot all raspberry pi devices." LICENSE = "Broadcom-RPi" LIC_FILES_CHKSUM = "file://LICENCE.broadcom;md5=c403841ff2837657b2ed8e5bb474ac8d" diff --git a/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb b/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb index 5315676fd..9489951ec 100644 --- a/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb +++ b/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb @@ -25,200 +25,216 @@ PITFT35r="${@bb.utils.contains("MACHINE_FEATURES", "pitft35r", "1", "0", d)}" VC4GRAPHICS="${@bb.utils.contains("MACHINE_FEATURES", "vc4graphics", "1", "0", d)}" VC4DTBO ?= "vc4-kms-v3d" +GPIO_IR ?= "18" +GPIO_IR_TX ?= "17" + +CAN_OSCILLATOR ?= "16000000" inherit deploy nopackages do_deploy() { - install -d ${DEPLOYDIR}/bcm2835-bootfiles + install -d ${DEPLOYDIR}/${BOOTFILES_DIR_NAME} - cp ${S}/config.txt ${DEPLOYDIR}/bcm2835-bootfiles/ + cp ${S}/config.txt ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/ if [ -n "${KEY_DECODE_MPG2}" ]; then - sed -i '/#decode_MPG2=/ c\decode_MPG2=${KEY_DECODE_MPG2}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#decode_MPG2=/ c\decode_MPG2=${KEY_DECODE_MPG2}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${KEY_DECODE_WVC1}" ]; then - sed -i '/#decode_WVC1=/ c\decode_WVC1=${KEY_DECODE_WVC1}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#decode_WVC1=/ c\decode_WVC1=${KEY_DECODE_WVC1}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${DISABLE_OVERSCAN}" ]; then - sed -i '/#disable_overscan=/ c\disable_overscan=${DISABLE_OVERSCAN}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#disable_overscan=/ c\disable_overscan=${DISABLE_OVERSCAN}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ "${DISABLE_SPLASH}" = "1" ]; then - sed -i '/#disable_splash=/ c\disable_splash=${DISABLE_SPLASH}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#disable_splash=/ c\disable_splash=${DISABLE_SPLASH}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Set overclocking options if [ -n "${ARM_FREQ}" ]; then - sed -i '/#arm_freq=/ c\arm_freq=${ARM_FREQ}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#arm_freq=/ c\arm_freq=${ARM_FREQ}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${GPU_FREQ}" ]; then - sed -i '/#gpu_freq=/ c\gpu_freq=${GPU_FREQ}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#gpu_freq=/ c\gpu_freq=${GPU_FREQ}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${CORE_FREQ}" ]; then - sed -i '/#core_freq=/ c\core_freq=${CORE_FREQ}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#core_freq=/ c\core_freq=${CORE_FREQ}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${SDRAM_FREQ}" ]; then - sed -i '/#sdram_freq=/ c\sdram_freq=${SDRAM_FREQ}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#sdram_freq=/ c\sdram_freq=${SDRAM_FREQ}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${OVER_VOLTAGE}" ]; then - sed -i '/#over_voltage=/ c\over_voltage=${OVER_VOLTAGE}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#over_voltage=/ c\over_voltage=${OVER_VOLTAGE}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # GPU memory if [ -n "${GPU_MEM}" ]; then - sed -i '/#gpu_mem=/ c\gpu_mem=${GPU_MEM}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#gpu_mem=/ c\gpu_mem=${GPU_MEM}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${GPU_MEM_256}" ]; then - sed -i '/#gpu_mem_256=/ c\gpu_mem_256=${GPU_MEM_256}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#gpu_mem_256=/ c\gpu_mem_256=${GPU_MEM_256}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${GPU_MEM_512}" ]; then - sed -i '/#gpu_mem_512=/ c\gpu_mem_512=${GPU_MEM_512}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#gpu_mem_512=/ c\gpu_mem_512=${GPU_MEM_512}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${GPU_MEM_1024}" ]; then - sed -i '/#gpu_mem_1024=/ c\gpu_mem_1024=${GPU_MEM_1024}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#gpu_mem_1024=/ c\gpu_mem_1024=${GPU_MEM_1024}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Set boot delay if [ -n "${BOOT_DELAY}" ]; then - sed -i '/#boot_delay=/ c\boot_delay=${BOOT_DELAY}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#boot_delay=/ c\boot_delay=${BOOT_DELAY}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${BOOT_DELAY_MS}" ]; then - sed -i '/#boot_delay_ms=/ c\boot_delay_ms=${BOOT_DELAY_MS}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#boot_delay_ms=/ c\boot_delay_ms=${BOOT_DELAY_MS}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Set HDMI and composite video options if [ -n "${HDMI_FORCE_HOTPLUG}" ]; then - sed -i '/#hdmi_force_hotplug=/ c\hdmi_force_hotplug=${HDMI_FORCE_HOTPLUG}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#hdmi_force_hotplug=/ c\hdmi_force_hotplug=${HDMI_FORCE_HOTPLUG}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${HDMI_DRIVE}" ]; then - sed -i '/#hdmi_drive=/ c\hdmi_drive=${HDMI_DRIVE}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#hdmi_drive=/ c\hdmi_drive=${HDMI_DRIVE}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${HDMI_GROUP}" ]; then - sed -i '/#hdmi_group=/ c\hdmi_group=${HDMI_GROUP}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#hdmi_group=/ c\hdmi_group=${HDMI_GROUP}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${HDMI_MODE}" ]; then - sed -i '/#hdmi_mode=/ c\hdmi_mode=${HDMI_MODE}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#hdmi_mode=/ c\hdmi_mode=${HDMI_MODE}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${CONFIG_HDMI_BOOST}" ]; then - sed -i '/#config_hdmi_boost=/ c\config_hdmi_boost=${CONFIG_HDMI_BOOST}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#config_hdmi_boost=/ c\config_hdmi_boost=${CONFIG_HDMI_BOOST}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${SDTV_MODE}" ]; then - sed -i '/#sdtv_mode=/ c\sdtv_mode=${SDTV_MODE}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#sdtv_mode=/ c\sdtv_mode=${SDTV_MODE}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${SDTV_ASPECT}" ]; then - sed -i '/#sdtv_aspect=/ c\sdtv_aspect=${SDTV_ASPECT}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#sdtv_aspect=/ c\sdtv_aspect=${SDTV_ASPECT}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ -n "${DISPLAY_ROTATE}" ]; then - sed -i '/#display_rotate=/ c\display_rotate=${DISPLAY_ROTATE}' ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + sed -i '/#display_rotate=/ c\display_rotate=${DISPLAY_ROTATE}' ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Video camera support if [ "${VIDEO_CAMERA}" = "1" ]; then - echo "# Enable video camera" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "start_x=1" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable video camera" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "start_x=1" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Offline compositing support if [ "${DISPMANX_OFFLINE}" = "1" ]; then - echo "# Enable offline compositing" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dispmanx_offline=1" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable offline compositing" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dispmanx_offline=1" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # SPI bus support if [ "${ENABLE_SPI_BUS}" = "1" ] || [ "${PITFT}" = "1" ]; then - echo "# Enable SPI bus" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtparam=spi=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable SPI bus" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtparam=spi=on" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # I2C support if [ "${ENABLE_I2C}" = "1" ] || [ "${PITFT}" = "1" ]; then - echo "# Enable I2C" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtparam=i2c1=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtparam=i2c_arm=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable I2C" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtparam=i2c1=on" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtparam=i2c_arm=on" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # PiTFT22 display support if [ "${PITFT22}" = "1" ]; then - echo "# Enable PITFT22 display" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=pitft22,rotate=270,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable PITFT22 display" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=pitft22,rotate=270,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ "${PITFT28r}" = "1" ]; then - echo "# Enable PITFT28r display" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=pitft28-resistive,rotate=90,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable PITFT28r display" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=pitft28-resistive,rotate=90,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ "${PITFT28c}" = "1" ]; then - echo "# Enable PITFT28c display" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=pitft28-capacitive,rotate=90,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=pitft28-capacitive,touch-swapxy,touch-invx" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable PITFT28c display" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=pitft28-capacitive,rotate=90,speed=32000000,txbuflen=32768" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=pitft28-capacitive,touch-swapxy,touch-invx" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi if [ "${PITFT35r}" = "1" ]; then - echo "# Enable PITFT35r display" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=pitft35-resistive,rotate=90,speed=42000000,fps=20" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable PITFT35r display" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=pitft35-resistive,rotate=90,speed=42000000,fps=20" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # UART support if [ "${ENABLE_UART}" = "1" ]; then - echo "# Enable UART" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "enable_uart=1" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable UART" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "enable_uart=1" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + fi + + # Infrared support + if [ "${ENABLE_IR}" = "1" ]; then + echo "# Enable infrared" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=gpio-ir,gpio_pin=${GPIO_IR}" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=gpio-ir-tx,gpio_pin=${GPIO_IR_TX}" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # VC4 Graphics support if [ "${VC4GRAPHICS}" = "1" ]; then - echo "# Enable VC4 Graphics" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=${VC4DTBO}" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable VC4 Graphics" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=${VC4DTBO}" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Waveshare "C" 1024x600 7" Rev2.1 IPS capacitive touch (http://www.waveshare.com/7inch-HDMI-LCD-C.htm) if [ "${WAVESHARE_1024X600_C_2_1}" = "1" ]; then - echo "# Waveshare \"C\" 1024x600 7\" Rev2.1 IPS capacitive touch screen" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "max_usb_current=1" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "hdmi_group=2" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "hdmi_mode=87" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "hdmi_cvt 1024 600 60 6 0 0 0" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "hdmi_drive=1" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Waveshare \"C\" 1024x600 7\" Rev2.1 IPS capacitive touch screen" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "max_usb_current=1" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "hdmi_group=2" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "hdmi_mode=87" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "hdmi_cvt 1024 600 60 6 0 0 0" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "hdmi_drive=1" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # DWC2 USB peripheral support if [ "${ENABLE_DWC2_PERIPHERAL}" = "1" ]; then - echo "# Enable USB peripheral mode" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=dwc2,dr_mode=peripheral" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable USB peripheral mode" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=dwc2,dr_mode=peripheral" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # AT86RF23X support if [ "${ENABLE_AT86RF}" = "1" ]; then - echo "# Enable AT86RF23X" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=at86rf233,speed=3000000" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable AT86RF23X" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=at86rf233,speed=3000000" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi + # ENABLE DUAL CAN + if [ "${ENABLE_DUAL_CAN}" = "1" ]; then + echo "# Enable DUAL CAN" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=mcp2515-can0,oscillator=${CAN_OSCILLATOR},interrupt=25" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=mcp2515-can1,oscillator=${CAN_OSCILLATOR},interrupt=24" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt # ENABLE CAN - if [ "${ENABLE_CAN}" = "1" ]; then - echo "# Enable CAN" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtoverlay=mcp2515-can0,oscillator=16000000,interrupt=25" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt + elif [ "${ENABLE_CAN}" = "1" ]; then + echo "# Enable CAN" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtoverlay=mcp2515-can0,oscillator=${CAN_OSCILLATOR},interrupt=25" >>${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt fi # Append extra config if the user has provided any - printf "${RPI_EXTRA_CONFIG}\n" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + printf "${RPI_EXTRA_CONFIG}\n" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt # Handle setup with armstub file if [ "${@bb.utils.contains("MACHINE_FEATURES", "armstub", "1", "0", d)}" = "1" ]; then - echo "\n# ARM stub configuration" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "armstub=${ARMSTUB}" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "\n# ARM stub configuration" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "armstub=${ARMSTUB}" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt case "${ARMSTUB}" in *-gic.bin) - echo "enable_gic=1" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "enable_gic=1" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt ;; esac fi } do_deploy_append_raspberrypi3-64() { - echo "# have a properly sized image" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "disable_overscan=1" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# have a properly sized image" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "disable_overscan=1" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt - echo "# Enable audio (loads snd_bcm2835)" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt - echo "dtparam=audio=on" >> ${DEPLOYDIR}/bcm2835-bootfiles/config.txt + echo "# Enable audio (loads snd_bcm2835)" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt + echo "dtparam=audio=on" >> ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/config.txt } addtask deploy before do_build after do_install -do_deploy[dirs] += "${DEPLOYDIR}/bcm2835-bootfiles" +do_deploy[dirs] += "${DEPLOYDIR}/${BOOTFILES_DIR_NAME}" PACKAGE_ARCH = "${MACHINE_ARCH}" diff --git a/meta-raspberrypi/recipes-bsp/common/raspberrypi-firmware.inc b/meta-raspberrypi/recipes-bsp/common/raspberrypi-firmware.inc index 5e4b77268..32cc4807d 100644 --- a/meta-raspberrypi/recipes-bsp/common/raspberrypi-firmware.inc +++ b/meta-raspberrypi/recipes-bsp/common/raspberrypi-firmware.inc @@ -1,10 +1,9 @@ -RPIFW_DATE ?= "20200504" -SRCREV ?= "7eff9f6774bb43bfd61e749a0b45ffddc98c2311" -RPIFW_SRC_URI ?= "https://github.com/raspberrypi/firmware/archive/${SRCREV}.tar.gz" +RPIFW_DATE ?= "20201002" +SRCREV ?= "11e3c314bc2b64f7d862bac00ff3d9f42f3c5a50" +RPIFW_SRC_URI ?= "https://github.com/raspberrypi/firmware/archive/${SRCREV}.tar.gz;downloadfilename=raspberrypi-firmware-${SRCREV}.tar.gz" RPIFW_S ?= "${WORKDIR}/firmware-${SRCREV}" SRC_URI = "${RPIFW_SRC_URI}" -SRC_URI[md5sum] = "05cd161dca5a6f02684794960913e04c" -SRC_URI[sha256sum] = "77ad450dd7cabb58ca04a18fd704844df6e642374346cf006a07edca46615af1" +SRC_URI[sha256sum] = "b8c9f5a3e987f418f11526cbf59f6a6c8103e8f5e94bccffb9ef3fd7ae834f98" PV = "${RPIFW_DATE}" diff --git a/meta-raspberrypi/recipes-bsp/common/raspberrypi-tools.inc b/meta-raspberrypi/recipes-bsp/common/raspberrypi-tools.inc index 0d4c627cb..93f9d7ac9 100644 --- a/meta-raspberrypi/recipes-bsp/common/raspberrypi-tools.inc +++ b/meta-raspberrypi/recipes-bsp/common/raspberrypi-tools.inc @@ -1,9 +1,9 @@ -SRCREV ?= "b0c869bc929587a7e1d20a98e2dc828a24ca396a" -RPITOOLS_SRC_URI ?= "https://github.com/raspberrypi/tools/archive/${SRCREV}.tar.gz" +RPITOOLS_DATE ?= "20200803" +SRCREV ?= "0c39cb5b5ac9851312a38c54f5aea770d976de7a" +RPITOOLS_SRC_URI ?= "https://github.com/raspberrypi/tools/archive/${SRCREV}.tar.gz;downloadfilename=raspberrypi-tools-${SRCREV}.tar.gz" RPITOOLS_S ?= "${WORKDIR}/tools-${SRCREV}" SRC_URI = "${RPITOOLS_SRC_URI}" -SRC_URI[md5sum] = "fd999aad4424088b5e8746a9d946bb56" -SRC_URI[sha256sum] = "a0a8aff308d9302318442e6bcd2df14cbbb3b633f12ca6b9c43c4ab69bf45bb1" +SRC_URI[sha256sum] = "ef56a891eef387d2278e6f9d20b462021faace14aceeb2048b5e5973069c25c0" -PV = "0.0+git${SRCREV}" +PV = "${RPITOOLS_DATE}" diff --git a/meta-raspberrypi/recipes-bsp/rpi-u-boot-scr/files/boot.cmd.in b/meta-raspberrypi/recipes-bsp/rpi-u-boot-scr/files/boot.cmd.in index ad54cd067..627d18156 100644 --- a/meta-raspberrypi/recipes-bsp/rpi-u-boot-scr/files/boot.cmd.in +++ b/meta-raspberrypi/recipes-bsp/rpi-u-boot-scr/files/boot.cmd.in @@ -1,3 +1,4 @@ fdt addr ${fdt_addr} && fdt get value bootargs /chosen bootargs fatload mmc 0:1 ${kernel_addr_r} @@KERNEL_IMAGETYPE@@ +if test ! -e mmc 0:1 uboot.env; then saveenv; fi; @@KERNEL_BOOTCMD@@ ${kernel_addr_r} - ${fdt_addr} diff --git a/meta-raspberrypi/recipes-bsp/u-boot/files/0001-dm-core-Move-ofdata_to_platdata-call-earlier.patch b/meta-raspberrypi/recipes-bsp/u-boot/files/0001-dm-core-Move-ofdata_to_platdata-call-earlier.patch new file mode 100644 index 000000000..996ad1074 --- /dev/null +++ b/meta-raspberrypi/recipes-bsp/u-boot/files/0001-dm-core-Move-ofdata_to_platdata-call-earlier.patch @@ -0,0 +1,51 @@ +From 336d86ebd146905cf4384912f4f27699b6e37c72 Mon Sep 17 00:00:00 2001 +From: Simon Glass <sjg@chromium.org> +Date: Sun, 29 Dec 2019 21:19:17 -0700 +Subject: [PATCH] dm: core: Move ofdata_to_platdata() call earlier + +This method is supposed to extract platform data from the device tree. It +should be done before the device itself is probed. Move it earlier in the +device_probe() function. + +Upstream-Status: Backport + +Signed-off-by: Simon Glass <sjg@chromium.org> +--- + drivers/core/device.c | 14 +++++++------- + 1 file changed, 7 insertions(+), 7 deletions(-) + +diff --git a/drivers/core/device.c b/drivers/core/device.c +index 4e03708..291ff4c 100644 +--- a/drivers/core/device.c ++++ b/drivers/core/device.c +@@ -375,6 +375,13 @@ int device_probe(struct udevice *dev) + return 0; + } + ++ if (drv->ofdata_to_platdata && ++ (CONFIG_IS_ENABLED(OF_PLATDATA) || dev_has_of_node(dev))) { ++ ret = drv->ofdata_to_platdata(dev); ++ if (ret) ++ goto fail; ++ } ++ + seq = uclass_resolve_seq(dev); + if (seq < 0) { + ret = seq; +@@ -411,13 +418,6 @@ int device_probe(struct udevice *dev) + goto fail; + } + +- if (drv->ofdata_to_platdata && +- (CONFIG_IS_ENABLED(OF_PLATDATA) || dev_has_of_node(dev))) { +- ret = drv->ofdata_to_platdata(dev); +- if (ret) +- goto fail; +- } +- + /* Only handle devices that have a valid ofnode */ + if (dev_of_valid(dev)) { + /* +-- +2.7.4 + diff --git a/meta-raspberrypi/recipes-bsp/u-boot/files/fw_env.config b/meta-raspberrypi/recipes-bsp/u-boot/files/fw_env.config new file mode 100644 index 000000000..d00df0cb3 --- /dev/null +++ b/meta-raspberrypi/recipes-bsp/u-boot/files/fw_env.config @@ -0,0 +1 @@ +/boot/uboot.env 0x0000 0x4000 diff --git a/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend b/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend index 9ce642563..cdfe5bb8b 100644 --- a/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend +++ b/meta-raspberrypi/recipes-bsp/u-boot/u-boot_%.bbappend @@ -1 +1,15 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" + +SRC_URI_append_rpi = " \ + file://fw_env.config \ +" + +# special fix for raspberrypi-cm3 +SRC_URI_append_raspberrypi-cm3 = " file://0001-dm-core-Move-ofdata_to_platdata-call-earlier.patch" + DEPENDS_append_rpi = " u-boot-default-script" + +do_install_append_rpi () { + install -d ${D}${sysconfdir} + install -m 0644 ${WORKDIR}/fw_env.config ${D}${sysconfdir}/fw_env.config +} diff --git a/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb index 3dbe96d43..87de35586 100644 --- a/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb +++ b/meta-raspberrypi/recipes-core/packagegroups/packagegroup-rpi-test.bb @@ -20,7 +20,7 @@ RDEPENDS_${PN} = "\ python3-sense-hat \ connman \ connman-client \ - wireless-regdb \ + wireless-regdb-static \ bluez5 \ " diff --git a/meta-raspberrypi/recipes-devtools/python/python3-rtimu_git.bb b/meta-raspberrypi/recipes-devtools/python/python3-rtimu_git.bb index c0cb31100..4f13a38bb 100644 --- a/meta-raspberrypi/recipes-devtools/python/python3-rtimu_git.bb +++ b/meta-raspberrypi/recipes-devtools/python/python3-rtimu_git.bb @@ -10,6 +10,6 @@ SRC_URI = "git://github.com/RPi-Distro/RTIMULib.git;protocol=http;branch=master " SRCREV = "b949681af69b45f0f7f4bb53b6770037b5b02178" -S = "${WORKDIR}/git/Linux/python/" +S = "${WORKDIR}/git/Linux/python" inherit setuptools3 diff --git a/meta-raspberrypi/recipes-devtools/python/rpi-gpio_0.7.0.bb b/meta-raspberrypi/recipes-devtools/python/rpi-gpio_0.7.0.bb index fcce88f83..8b13d53a6 100644 --- a/meta-raspberrypi/recipes-devtools/python/rpi-gpio_0.7.0.bb +++ b/meta-raspberrypi/recipes-devtools/python/rpi-gpio_0.7.0.bb @@ -12,3 +12,7 @@ SRC_URI[md5sum] = "777617f9dea9a1680f9af43db0cf150e" SRC_URI[sha256sum] = "7424bc6c205466764f30f666c18187a0824077daf20b295c42f08aea2cb87d3f" COMPATIBLE_MACHINE = "^rpi$" + +# ignore issues with -fno-common from gcc-10 until it's fixed in upstream: +# https://sourceforge.net/p/raspberry-gpio-python/tickets/187/ +CFLAGS += "-fcommon" diff --git a/meta-raspberrypi/recipes-graphics/libsdl2/libsdl2_%.bbappend b/meta-raspberrypi/recipes-graphics/libsdl2/libsdl2_%.bbappend new file mode 100644 index 000000000..cb9c24e4d --- /dev/null +++ b/meta-raspberrypi/recipes-graphics/libsdl2/libsdl2_%.bbappend @@ -0,0 +1,5 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" + +# when using userland graphic KHR/khrplatform.h is provided by userland but virtual/libgl is provided by mesa-gl where +# we explicitly delete KHR/khrplatform.h since its already coming from userland package +DEPENDS_append_rpi = " ${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', 'userland', d)}" diff --git a/meta-raspberrypi/recipes-graphics/mesa/files/0001-dri2-query-dma-buf-modifiers.patch b/meta-raspberrypi/recipes-graphics/mesa/files/0001-dri2-query-dma-buf-modifiers.patch deleted file mode 100644 index 0bda01450..000000000 --- a/meta-raspberrypi/recipes-graphics/mesa/files/0001-dri2-query-dma-buf-modifiers.patch +++ /dev/null @@ -1,43 +0,0 @@ -mesa: querying dma_buf_modifiers for specific formats - -mesa wl_drm protocol is the backend for wayland server side which requires -the dmabuf modifiers for some DRM formats on specific devices like RPI. -Currently there is no support of giving any dmabuf modifiers on wl_drm protocol. -This dma_buf modifiers allows EGL implementations to add extra attributes -to drm_fourcc format. - -Upstream-Status: Pending - -Signed-off-by: Balaji Velmurugan <balaji.velmurugan@ltts.com> - ---- a/src/gallium/state_trackers/dri/dri2.c -+++ b/src/gallium/state_trackers/dri/dri2.c -@@ -1366,14 +1366,28 @@ dri2_from_planar(__DRIimage *image, int - return img; - } - -+static boolean -+dri2_query_dma_buf_modifiers(__DRIscreen *_screen, int fourcc, int max, -+ uint64_t *modifiers, unsigned int *external_only, -+ int *count); - static __DRIimage * - dri2_from_fds(__DRIscreen *screen, int width, int height, int fourcc, - int *fds, int num_fds, int *strides, int *offsets, - void *loaderPrivate) - { -+ uint64_t modifier= DRM_FORMAT_MOD_INVALID; -+ unsigned int external_only= 0; -+ int count= 0; -+ boolean result; -+ result= dri2_query_dma_buf_modifiers( screen, fourcc, 1, &modifier, &external_only, &count); -+ return dri2_create_image_from_fd(screen, width, height, fourcc, -+ modifier, fds, num_fds, -+ strides, offsets, NULL, loaderPrivate); -+ #if 0 - return dri2_create_image_from_fd(screen, width, height, fourcc, - DRM_FORMAT_MOD_INVALID, fds, num_fds, - strides, offsets, NULL, loaderPrivate); -+ #endif - } - - static boolean diff --git a/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend b/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend index d3435e720..eaa46f27b 100644 --- a/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend +++ b/meta-raspberrypi/recipes-graphics/mesa/mesa_%.bbappend @@ -1,10 +1,6 @@ -FILESEXTRAPATHS_prepend := "${THISDIR}/files:" # DRI3 note: # With oe-core commit 8509e2e1a87578882b71948ccef3b50ccf1228b3 dri3 is set # as default. To state out clearly that Raspi needs dri3 and to avoid surprises # in case oe-core changes this default, we set dri3 explicitly. - -SRC_URI_append_rpi = " file://0001-dri2-query-dma-buf-modifiers.patch " - PACKAGECONFIG_append_rpi = " gallium vc4 v3d kmsro ${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'x11 dri3', '', d)}" DRIDRIVERS_class-target_rpi = "" diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch b/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch index 21b40a3e1..ca39b78cd 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0001-Allow-applications-to-set-next-resource-handle.patch @@ -1,7 +1,7 @@ -From 4ffe3e0bc856ce1d2c52e84be6ea9337a5ce5410 Mon Sep 17 00:00:00 2001 +From d0956d198ceaf611314d61a0835fb5924b8a3577 Mon Sep 17 00:00:00 2001 From: Dom Cobley <dc4@broadcom.com> Date: Tue, 9 Jul 2013 09:26:26 -0400 -Subject: [PATCH] Allow applications to set next resource handle +Subject: [PATCH 01/21] Allow applications to set next resource handle This patch adds provisions in userland to let apps callers set the next rendereing dispmanx resource. @@ -203,3 +203,6 @@ index 8a5734c..51b3580 100644 FN(void, eglIntSelectMipmap_impl, (EGL_SURFACE_ID_T s, int level)) FN(void, eglIntGetColorData_impl, (EGL_SURFACE_ID_T s, KHRN_IMAGE_FORMAT_T format, uint32_t width, uint32_t height, int32_t stride, uint32_t y_offset, void *data)) +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch b/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch index 9b0dd21eb..d2d9b497d 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0002-wayland-Add-support-for-the-Wayland-winsys.patch @@ -1,7 +1,7 @@ -From 21dba61f098020d1143289017841ca76995618d4 Mon Sep 17 00:00:00 2001 +From 75eb8ab4bec3e462607214d2e14c9f2eef73435f Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso <tomeu.vizoso@collabora.com> Date: Tue, 1 Oct 2013 13:19:20 +0200 -Subject: [PATCH] wayland: Add support for the Wayland winsys +Subject: [PATCH 02/21] wayland: Add support for the Wayland winsys * Adds EGL_WL_bind_wayland_display extension * Adds wayland-egl library @@ -23,7 +23,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> CMakeLists.txt | 11 + README.md | 4 + buildme | 10 +- - .../linux/apps/raspicam/CMakeLists.txt | 3 +- + .../linux/apps/raspicam/CMakeLists.txt | 2 +- interface/khronos/CMakeLists.txt | 54 +++- interface/khronos/common/khrn_client.c | 15 ++ interface/khronos/common/khrn_client.h | 10 + @@ -49,7 +49,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> interface/vmcs_host/vc_vchi_dispmanx.h | 15 ++ interface/wayland/dispmanx.xml | 123 +++++++++ makefiles/cmake/Wayland.cmake | 72 +++++ - 30 files changed, 1258 insertions(+), 99 deletions(-) + 30 files changed, 1257 insertions(+), 99 deletions(-) create mode 100644 interface/khronos/common/linux/khrn_wayland.c copy interface/{vmcs_host/vc_vchi_dispmanx.h => khronos/common/linux/khrn_wayland.h} (56%) create mode 100644 interface/khronos/ext/egl_wayland.c @@ -69,10 +69,10 @@ index 63570f1..1459436 100644 *.mkv +*~ diff --git a/CMakeLists.txt b/CMakeLists.txt -index d8ba238..8c5bf5f 100644 +index fe67fc8..80337b2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -20,6 +20,17 @@ include(makefiles/cmake/global_settings.cmake) +@@ -24,6 +24,17 @@ include(makefiles/cmake/global_settings.cmake) include(makefiles/cmake/arm-linux.cmake) include(makefiles/cmake/vmcs.cmake) @@ -133,19 +133,18 @@ index 9e2d405..7b8c0d6 100755 if [ "$1" != "" ]; then diff --git a/host_applications/linux/apps/raspicam/CMakeLists.txt b/host_applications/linux/apps/raspicam/CMakeLists.txt -index 656a9a0..4b0a888 100644 +index eb1ef7c..5aeeb2e 100644 --- a/host_applications/linux/apps/raspicam/CMakeLists.txt +++ b/host_applications/linux/apps/raspicam/CMakeLists.txt -@@ -59,7 +59,8 @@ add_executable(raspivid ${COMMON_SOURCES} RaspiVid.c) +@@ -61,7 +61,7 @@ add_executable(raspivid ${COMMON_SOURCES} RaspiVid.c) add_executable(raspividyuv ${COMMON_SOURCES} RaspiVidYUV.c) set (MMAL_LIBS mmal_core mmal_util mmal_vc_client) -target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host ${EGL_LIBS} m dl) -+ +target_link_libraries(raspistill ${MMAL_LIBS} vcos bcm_host ${EGL_LIBS} m dl ${WAYLAND_SERVER_LIBRARIES} ${WAYLAND_CLIENT_LIBRARIES}) - target_link_libraries(raspiyuv ${MMAL_LIBS} vcos bcm_host) - target_link_libraries(raspivid ${MMAL_LIBS} vcos bcm_host) - target_link_libraries(raspividyuv ${MMAL_LIBS} vcos bcm_host) + target_link_libraries(raspiyuv ${MMAL_LIBS} vcos bcm_host m) + target_link_libraries(raspivid ${MMAL_LIBS} vcos bcm_host m) + target_link_libraries(raspividyuv ${MMAL_LIBS} vcos bcm_host m) diff --git a/interface/khronos/CMakeLists.txt b/interface/khronos/CMakeLists.txt index 9ad615b..95c0e11 100644 --- a/interface/khronos/CMakeLists.txt @@ -1894,3 +1893,6 @@ index 0000000..ad90d30 + list(APPEND ${_sources} "${_server_header}") + set(${_sources} ${${_sources}} PARENT_SCOPE) +endfunction() +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch b/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch index b99576966..59fc366e7 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0003-wayland-Add-Wayland-example.patch @@ -1,17 +1,17 @@ -From d2fd39ea43f948feba34e895600afd801e03691f Mon Sep 17 00:00:00 2001 +From 3b568db9460c0359e8bda8256aa2161e5aafe07c Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso <tomeu.vizoso@collabora.com> Date: Tue, 1 Oct 2013 13:19:20 +0200 -Subject: [PATCH] wayland: Add Wayland example +Subject: [PATCH 03/21] wayland: Add Wayland example --- .../linux/apps/hello_pi/CMakeLists.txt | 1 + + .../linux/apps/hello_pi/Makefile | 2 + .../hello_pi/hello_wayland/CMakeLists.txt | 8 + .../hello_pi/hello_wayland/Djenne_128_128.raw | 3 + .../apps/hello_pi/hello_wayland/Makefile | 5 + .../hello_wayland/cube_texture_and_coords.h | 100 +++ .../apps/hello_pi/hello_wayland/triangle.c | 666 ++++++++++++++++++ - .../linux/apps/hello_pi/rebuild.sh | 3 +- - 7 files changed, 785 insertions(+), 1 deletion(-) + 7 files changed, 785 insertions(+) create mode 100644 host_applications/linux/apps/hello_pi/hello_wayland/CMakeLists.txt create mode 100644 host_applications/linux/apps/hello_pi/hello_wayland/Djenne_128_128.raw create mode 100644 host_applications/linux/apps/hello_pi/hello_wayland/Makefile @@ -30,6 +30,24 @@ index b28a94a..2849fad 100644 if(BUILD_FONT) set(VGFONT_SRCS libs/vgfont/font.c libs/vgfont/vgft.c libs/vgfont/graphics.c) +diff --git a/host_applications/linux/apps/hello_pi/Makefile b/host_applications/linux/apps/hello_pi/Makefile +index 4c2b2ef..d2b2555 100644 +--- a/host_applications/linux/apps/hello_pi/Makefile ++++ b/host_applications/linux/apps/hello_pi/Makefile +@@ -24,6 +24,7 @@ apps: libs/ilclient/libilclient.a libs/vgfont/libvgfont.a libs/revision/librevis + $(MAKE) -C hello_teapot + $(MAKE) -C hello_fft + $(MAKE) -C hello_mmal_encode ++ $(MAKE) -C hello_wayland + + clean: + $(MAKE) -C libs/ilclient clean +@@ -43,4 +44,5 @@ clean: + $(MAKE) -C hello_teapot clean + $(MAKE) -C hello_fft clean + $(MAKE) -C hello_mmal_encode clean ++ $(MAKE) -C hello_wayland clean + diff --git a/host_applications/linux/apps/hello_pi/hello_wayland/CMakeLists.txt b/host_applications/linux/apps/hello_pi/hello_wayland/CMakeLists.txt new file mode 100644 index 0000000..9a2f75c @@ -843,21 +861,6 @@ index 0000000..1a7bfc4 + return 0; +} + -diff --git a/host_applications/linux/apps/hello_pi/rebuild.sh b/host_applications/linux/apps/hello_pi/rebuild.sh -index 8225dd5..0be6ce7 100755 ---- a/host_applications/linux/apps/hello_pi/rebuild.sh -+++ b/host_applications/linux/apps/hello_pi/rebuild.sh -@@ -14,6 +14,7 @@ make -C hello_videocube clean - make -C hello_teapot clean - make -C hello_fft clean - make -C hello_mmal_encode clean -+make -C hello_wayland clean - - make -C libs/ilclient - make -C libs/vgfont -@@ -31,4 +32,4 @@ make -C hello_videocube - make -C hello_teapot - make -C hello_fft - make -C hello_mmal_encode -- -+make -C hello_wayland +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch b/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch index b08146833..ac4c5135d 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0004-wayland-egl-Add-bcm_host-to-dependencies.patch @@ -1,7 +1,7 @@ -From 53ef88cdb879050fc6f5247e7ca05260af69f2e8 Mon Sep 17 00:00:00 2001 +From 3ce83fc1d4974d4db15ff72b4e856a29c60dbb83 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Mon, 10 Aug 2015 02:38:27 -0700 -Subject: [PATCH] wayland-egl: Add bcm_host to dependencies +Subject: [PATCH 04/21] wayland-egl: Add bcm_host to dependencies It uses headers like vcos_platform_types.h but does not depend on module which should add the required include paths @@ -23,3 +23,6 @@ index 8bafc15..fd259c9 100644 +Requires: bcm_host Libs: -L${libdir} -lwayland-egl Cflags: -I${includedir} +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch b/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch index 27e69a91c..33d4a5539 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0005-interface-remove-faulty-assert-to-make-weston-happy-.patch @@ -1,8 +1,8 @@ -From 237b9690154d2840d02aa927c56d80ef43f384b3 Mon Sep 17 00:00:00 2001 +From cf4d2dba7150aad7f85eb7f5df0b0cfa9389da57 Mon Sep 17 00:00:00 2001 From: "Yann E. MORIN" <yann.morin.1998@free.fr> Date: Sat, 24 Jan 2015 22:07:19 +0100 -Subject: [PATCH] interface: remove faulty assert() to make weston happy at - runtime +Subject: [PATCH 05/21] interface: remove faulty assert() to make weston happy + at runtime This was removed after a discussion on IRC with the weston guys ('daniels' on irc.freenode.net/#wayland). @@ -24,3 +24,6 @@ index eab146e..29e0dee 100755 dispmanx_client.update_callback(handle, dispmanx_client.update_callback_param); } } else { +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch b/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch index 872bc7b82..690d51daf 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0006-zero-out-wl-buffers-in-egl_surface_free.patch @@ -1,7 +1,7 @@ -From 5acedbd1d27fe528687f27173d2af9b1786f580d Mon Sep 17 00:00:00 2001 +From ce90048cb25a0c2c49c585ce3a4cd8c73a8ff55b Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 6 Feb 2016 11:10:47 -0800 -Subject: [PATCH] zero-out wl buffers in egl_surface_free +Subject: [PATCH 06/21] zero-out wl buffers in egl_surface_free origins from buildroot @@ -28,3 +28,6 @@ index 42350bf..1f923d9 100644 } #endif } +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch b/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch index 0494e6ed8..d964ed5a6 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0007-initialize-front-back-wayland-buffers.patch @@ -1,7 +1,7 @@ -From 9159eff795a8ef3be0b3bfd554ef1aa23340884d Mon Sep 17 00:00:00 2001 +From 7f7e5b87104134b6710985c5f1c5936a59cccc98 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 6 Feb 2016 11:11:41 -0800 -Subject: [PATCH] initialize front back wayland buffers +Subject: [PATCH 07/21] initialize front back wayland buffers origins from metrological wayland support @@ -29,3 +29,6 @@ index 1f923d9..9a9582c 100644 resource = DISPMANX_NO_HANDLE; } #endif +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch b/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch index 68875eb50..d9aba5e93 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0008-Remove-RPC_FLUSH.patch @@ -1,7 +1,7 @@ -From 581742c1edf89d4ed3728a3c6d59484ced4234cc Mon Sep 17 00:00:00 2001 +From 2291cf20017c297e6ed3afd56945cf8768c9901e Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 6 Feb 2016 11:09:18 -0800 -Subject: [PATCH] Remove RPC_FLUSH +Subject: [PATCH 08/21] Remove RPC_FLUSH Origins from buildroot @@ -22,3 +22,6 @@ index f9b7287..b04ffef 100644 #if EGL_BRCM_global_image } #endif +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch b/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch index fceeb6ebf..898408b62 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0009-fix-cmake-dependency-race.patch @@ -1,7 +1,7 @@ -From acc4ffbb0f2a64e82b9cceda201a59df969e1d0f Mon Sep 17 00:00:00 2001 +From 736f489743b4a761afc928cbac197b28b3209bf1 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 6 Feb 2016 13:12:47 -0800 -Subject: [PATCH] fix cmake dependency race +Subject: [PATCH 09/21] fix cmake dependency race Fixes errors like @@ -73,3 +73,6 @@ index f0bae30..8c44c58 100644 struct wl_dispmanx_server_buffer { struct wl_resource *resource; struct wl_dispmanx *dispmanx; +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch b/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch index 0ddef975c..37f6abbfe 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0010-Fix-for-framerate-with-nested-composition.patch @@ -1,7 +1,7 @@ -From 0af26805c35c6a600a13ed106bbc7cf85a37ce66 Mon Sep 17 00:00:00 2001 +From 450341ccd98801be1c3dc648e18211177f81a60d Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Tue, 29 Mar 2016 20:38:30 -0700 -Subject: [PATCH] Fix for framerate with nested composition +Subject: [PATCH 10/21] Fix for framerate with nested composition frame rate appears irregular and lower than expected when using nested composition. @@ -55,3 +55,6 @@ index 03fe67b..13a110c 100644 #ifdef ANDROID CLIENT_UNLOCK(); +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch b/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch index 6e2f658d4..77f9ccb9c 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0011-build-shared-library-for-vchostif.patch @@ -1,7 +1,7 @@ -From 6172dbb6fd7cf821471d721569abe9a0de0d869d Mon Sep 17 00:00:00 2001 +From 13f2a4d1c6b6e79389ac3aa64512d78882a11b2f Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 2 Apr 2016 10:37:24 -0700 -Subject: [PATCH] build shared library for vchostif +Subject: [PATCH 11/21] build shared library for vchostif Fixes #149 @@ -23,3 +23,6 @@ index 16d3184..e54f046 100755 #add_library(bufman vc_vchi_bufman.c ) set(INSTALL_TARGETS vchostif) +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch b/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch index 19939e07e..53403d7d1 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0012-implement-buffer-wrapping-interface-for-dispmanx.patch @@ -1,7 +1,7 @@ -From efd80d2b278c326cc3dae7eeb1fed6c4dd12a8a6 Mon Sep 17 00:00:00 2001 +From a09feea5ceb0af717c17a3a7df8a638f8e858f52 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sat, 2 Apr 2016 10:54:59 -0700 -Subject: [PATCH] implement buffer wrapping interface for dispmanx +Subject: [PATCH 12/21] implement buffer wrapping interface for dispmanx Courtesy: Zan Dobersek @@ -87,3 +87,6 @@ index c18626d..11ed1ef 100644 </interface> </protocol> +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch b/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch index 3df1f6d22..d5702cbc9 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0013-Implement-triple-buffering-for-wayland.patch @@ -1,7 +1,7 @@ -From 2e1e3c857cdf365c5a13bcd5d09685cf12f8047c Mon Sep 17 00:00:00 2001 +From dd8017ebccfa9c439a4e8dd501872e2052016f10 Mon Sep 17 00:00:00 2001 From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com> Date: Thu, 19 Jan 2017 18:56:07 +0000 -Subject: [PATCH] Implement triple buffering for wayland +Subject: [PATCH 13/21] Implement triple buffering for wayland Change from double to triple buffering for wayland. This enables higher frame rates without tearing artifacts @@ -85,3 +85,6 @@ index e328b77..58a3184 100644 /* back_wl_buffer +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch b/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch index 1d5247de0..52f03159b 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0014-GLES2-gl2ext.h-Define-GL_R8_EXT-and-GL_RG8_EXT.patch @@ -1,7 +1,7 @@ -From a64be7ff40bd6de2ac099c3f0091f14edfe57fe7 Mon Sep 17 00:00:00 2001 +From afe3917b1a236c08b1ed01053e3da9ab283db1ec Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Wed, 10 May 2017 06:39:34 +0000 -Subject: [PATCH] GLES2/gl2ext.h: Define GL_R8_EXT and GL_RG8_EXT +Subject: [PATCH 14/21] GLES2/gl2ext.h: Define GL_R8_EXT and GL_RG8_EXT weston code uses these defines Upstream-Status: Pending @@ -30,3 +30,6 @@ index 4eacf7f..b1acc9f 100644 /* GL_EXT_texture_type_2_10_10_10_REV */ #ifndef GL_EXT_texture_type_2_10_10_10_REV #define GL_UNSIGNED_INT_2_10_10_10_REV_EXT 0x8368 +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch b/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch index a77f6d480..964d0ecee 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0015-EGL-glplatform.h-define-EGL_CAST.patch @@ -1,7 +1,7 @@ -From 8f32b772d869481f88d9b7e14feb43c39b3fc33d Mon Sep 17 00:00:00 2001 +From 47972590947e5da25d77cae0ce060f7b8d022a10 Mon Sep 17 00:00:00 2001 From: Andrea Galbusera <gizero@gmail.com> Date: Fri, 14 Jul 2017 09:52:54 +0200 -Subject: [PATCH] EGL/glplatform.h: define EGL_CAST +Subject: [PATCH 15/21] EGL/glplatform.h: define EGL_CAST C++ / C typecast macros for special EGL handle values: used by libepoxy code The definition comes from the updated version of this header in mesa. @@ -27,3 +27,6 @@ index 1f7c930..c39d425 100644 +#endif + #endif /* __eglplatform_h */ +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch b/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch index 444595859..3790f80e4 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0016-Allow-multiple-wayland-compositor-state-data-per-pro.patch @@ -1,7 +1,8 @@ -From fe9ff55dac403b148f229c865bf2826ea4edf447 Mon Sep 17 00:00:00 2001 +From 1eb8bdb4d45e3de9582145c120b0d3ede187c7a9 Mon Sep 17 00:00:00 2001 From: Jeff Wannamaker <jeff_wannamaker@cable.comcast.com> Date: Sat, 27 Jan 2018 12:28:31 -0500 -Subject: [PATCH] Allow multiple wayland compositor state data per process +Subject: [PATCH 16/21] Allow multiple wayland compositor state data per + process When eglBindWaylandDisplayWL is called store the wl_global created in a list associated with the wayland display. @@ -139,3 +140,6 @@ index 9ef89cd..abd5ab3 100644 CLIENT_UNLOCK(); +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch b/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch index a2f2ded45..c3457cde9 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0017-khronos-backport-typedef-for-EGL_EXT_image_dma_buf_i.patch @@ -1,7 +1,8 @@ -From 8f8c22bc8aad6eb0f7c1b68f9f9a89f99adff996 Mon Sep 17 00:00:00 2001 +From 99a210c93019d37dd7f044102c4314c8cb988ed4 Mon Sep 17 00:00:00 2001 From: Hugo Hromic <hhromic@gmail.com> Date: Sun, 13 May 2018 10:49:04 +0100 -Subject: [PATCH] khronos: backport typedef for EGL_EXT_image_dma_buf_import +Subject: [PATCH 17/21] khronos: backport typedef for + EGL_EXT_image_dma_buf_import The `gstreamer1.0-plugins-base` package version `1.14` uses `EGL_EXT_image_dma_buf_import`, which expects the `EGLuint64KHR` typedef that is present in recent versions of Khronos. @@ -32,3 +33,6 @@ index d7e5ba7..dcc90ce 100755 #ifndef EGL_WL_bind_wayland_display #define EGL_WL_bind_wayland_display 1 +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch b/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch index defaf3e24..5317c60e3 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0018-Add-EGL_IMG_context_priority-related-defines.patch @@ -1,7 +1,7 @@ -From fe9bf7b9d79133ca5c72f68ed33002a7539e9797 Mon Sep 17 00:00:00 2001 +From 82cf4bc5623c5220dfa1c096ea192f2509837782 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Sun, 15 Jul 2018 00:48:38 -0700 -Subject: [PATCH] Add EGL_IMG_context_priority related defines +Subject: [PATCH 18/21] Add EGL_IMG_context_priority related defines These defines are needed for compiling weston 4.x taken from Khronos headers @@ -30,3 +30,6 @@ index dcc90ce..6842bf9 100755 #ifndef EGL_KHR_vg_parent_image #define EGL_KHR_vg_parent_image 1 #define EGL_VG_PARENT_IMAGE_KHR 0x30BA /* eglCreateImageKHR target */ +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0019-libfdt-Undefine-__wordsize-if-already-defined.patch b/meta-raspberrypi/recipes-graphics/userland/files/0019-libfdt-Undefine-__wordsize-if-already-defined.patch index 34ca21add..cd6306bb0 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0019-libfdt-Undefine-__wordsize-if-already-defined.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0019-libfdt-Undefine-__wordsize-if-already-defined.patch @@ -1,7 +1,7 @@ -From 339af0cea0dc29b33773a3d851ea17c42610de7b Mon Sep 17 00:00:00 2001 +From 1112539d9fde6428c1230b4fc9ea479623e9f968 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Thu, 25 Jul 2019 23:30:27 -0700 -Subject: [PATCH] libfdt: Undefine __wordsize if already defined +Subject: [PATCH 19/21] libfdt: Undefine __wordsize if already defined glibc 2.30+ defines __wordsize, which is same so its easier to compile for multiple versions of glibc even ones which does not have this define @@ -26,3 +26,6 @@ index f4608be..5e83a27 100644 #ifdef __CHECKER__ #define FDT_FORCE __attribute__((force)) #define FDT_BITWISE __attribute__((bitwise)) +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0020-openmaxil-add-pkg-config-file.patch b/meta-raspberrypi/recipes-graphics/userland/files/0020-openmaxil-add-pkg-config-file.patch index 3823c12e7..e9d9da6fc 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0020-openmaxil-add-pkg-config-file.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0020-openmaxil-add-pkg-config-file.patch @@ -1,7 +1,7 @@ -From d1a9839c6e4b4d187382baf341d25b3d023242cd Mon Sep 17 00:00:00 2001 +From 488916a6b366bfa5da2907b5892798eb2306a17d Mon Sep 17 00:00:00 2001 From: Martin Jansa <martin.jansa@lge.com> Date: Wed, 13 Jun 2018 18:22:22 +0000 -Subject: [PATCH] openmaxil: add pkg-config file +Subject: [PATCH 20/21] openmaxil: add pkg-config file --- CMakeLists.txt | 2 +- @@ -10,10 +10,10 @@ Subject: [PATCH] openmaxil: add pkg-config file create mode 100644 pkgconfig/openmaxil.pc.in diff --git a/CMakeLists.txt b/CMakeLists.txt -index 8c5bf5f..9f4165a 100644 +index 80337b2..3e3c90e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -131,7 +131,7 @@ include_directories("${PROJECT_BINARY_DIR}") +@@ -133,7 +133,7 @@ include_directories("${PROJECT_BINARY_DIR}") include(FindPkgConfig QUIET) if(PKG_CONFIG_FOUND) # Produce a pkg-config file @@ -38,3 +38,6 @@ index 0000000..8793a61 +Version: 1 +Libs: -L${libdir} -lopenmaxil -lvcos -lvchiq_arm -pthread +Cflags: -I${includedir} -I${includedir}/IL -I${includedir}/interface/vmcs_host/linux -I${includedir}/interface/vcos/pthreads -DUSE_VCHIQ_ARM +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/files/0021-cmake-Disable-format-overflow-warning-as-error.patch b/meta-raspberrypi/recipes-graphics/userland/files/0021-cmake-Disable-format-overflow-warning-as-error.patch index 703d3006c..c762a9fc4 100644 --- a/meta-raspberrypi/recipes-graphics/userland/files/0021-cmake-Disable-format-overflow-warning-as-error.patch +++ b/meta-raspberrypi/recipes-graphics/userland/files/0021-cmake-Disable-format-overflow-warning-as-error.patch @@ -1,7 +1,7 @@ -From 4886bd9f33727f6a16aeb3b1aa3c25e459f06581 Mon Sep 17 00:00:00 2001 +From ee842886f3c0589d6df5a0687973beb18a3be524 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> Date: Tue, 31 Mar 2020 11:51:02 -0700 -Subject: [PATCH] cmake: Disable format-overflow warning as error +Subject: [PATCH 21/21] cmake: Disable format-overflow warning as error gcc10 complains about a check which could potentially be null @@ -19,6 +19,8 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> host_applications/linux/libs/bcm_host/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) +diff --git a/host_applications/linux/libs/bcm_host/CMakeLists.txt b/host_applications/linux/libs/bcm_host/CMakeLists.txt +index a863cb6..f358135 100644 --- a/host_applications/linux/libs/bcm_host/CMakeLists.txt +++ b/host_applications/linux/libs/bcm_host/CMakeLists.txt @@ -3,7 +3,7 @@ if (WIN32) @@ -26,7 +28,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com> else () set(VCOS_PLATFORM pthreads) - add_definitions(-Wall -Werror) -+ add_definitions(-Wall) ++ add_definitions(-Wall -Werror -Wno-error=format-overflow) endif () # set this as we want all the source of vchostif to be available in libbcm_host +-- +2.27.0 + diff --git a/meta-raspberrypi/recipes-graphics/userland/userland_git.bb b/meta-raspberrypi/recipes-graphics/userland/userland_git.bb index eefc1ecd8..24f0eaf0c 100644 --- a/meta-raspberrypi/recipes-graphics/userland/userland_git.bb +++ b/meta-raspberrypi/recipes-graphics/userland/userland_git.bb @@ -13,11 +13,11 @@ COMPATIBLE_MACHINE = "^rpi$" SRCBRANCH = "master" SRCFORK = "raspberrypi" -SRCREV = "6fb59736b1ae80fc62cddfe3309c800f72e1c07e" +SRCREV = "188d3bfe4a0ac36b119a2cee35a6be8d0c68e09e" # Use the date of the above commit as the package version. Update this when # SRCREV is changed. -PV = "20200316" +PV = "20200624" SRC_URI = "\ git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \ @@ -43,6 +43,9 @@ SRC_URI = "\ file://0020-openmaxil-add-pkg-config-file.patch \ file://0021-cmake-Disable-format-overflow-warning-as-error.patch \ " + +SRC_URI_remove_toolchain-clang = "file://0021-cmake-Disable-format-overflow-warning-as-error.patch" + S = "${WORKDIR}/git" inherit cmake pkgconfig diff --git a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend b/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend index fba163219..9574fa5b8 100644 --- a/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend +++ b/meta-raspberrypi/recipes-graphics/xorg-xserver/xserver-xorg_%.bbappend @@ -1 +1,5 @@ OPENGL_PKGCONFIGS_rpi = "dri glx ${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', 'dri3 xshmfence glamor', '', d)}" + +# when using userland graphic KHR/khrplatform.h is provided by userland but virtual/libgl is provided by mesa-gl where +# we explicitly delete KHR/khrplatform.h since its already coming from userland package +DEPENDS_append_rpi = " ${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '', 'userland', d)}" diff --git a/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb b/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb index 833f8f68a..99afde848 100644 --- a/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb +++ b/meta-raspberrypi/recipes-kernel/linux-firmware-rpidistro/linux-firmware-rpidistro_git.bb @@ -35,8 +35,8 @@ NO_GENERIC_LICENSE[WHENCE] = "WHENCE" SRC_URI = "git://github.com/RPi-Distro/firmware-nonfree" -SRCREV = "616fc2dd4df421e3974179d9e46d45e7006aeb28" -PV = "20190114-1+rpt6" +SRCREV = "98e815735e2c805d65994ccc608f399595b74438" +PV = "20190114-1+rpt8" S = "${WORKDIR}/git" @@ -59,6 +59,11 @@ do_install() { for fw in brcmfmac43430-sdio brcmfmac43455-sdio ; do install -m 0644 brcm/${fw}.* ${D}${nonarch_base_libdir}/firmware/brcm/ done + # add compat links. Fixes errors like + # brcmfmac mmc1:0001:1: Direct firmware load for brcm/brcmfmac43455-sdio.raspberrypi,4-model-b.txt failed with error -2 + ln -s brcmfmac43455-sdio.txt ${D}${nonarch_base_libdir}/firmware/brcm/brcmfmac43455-sdio.raspberrypi,4-model-b.txt + ln -s brcmfmac43455-sdio.txt ${D}${nonarch_base_libdir}/firmware/brcm/brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt + ln -s brcmfmac43430-sdio.txt ${D}${nonarch_base_libdir}/firmware/brcm/brcmfmac43430-sdio.raspberrypi,3-model-b.txt } PACKAGES = "\ diff --git a/meta-raspberrypi/recipes-kernel/linux/files/0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch b/meta-raspberrypi/recipes-kernel/linux/files/0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch index 59183dc30..66efde138 100644 --- a/meta-raspberrypi/recipes-kernel/linux/files/0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch +++ b/meta-raspberrypi/recipes-kernel/linux/files/0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch @@ -1,16 +1,18 @@ -From a7783676c60dd90a6f4c26bcb9be03dc5703b74e Mon Sep 17 00:00:00 2001 +From 754e3030788702c1f013a88a4fc8546742d84e27 Mon Sep 17 00:00:00 2001 From: Khem Raj <raj.khem@gmail.com> -Date: Mon, 13 Apr 2020 11:25:32 -0700 -Subject: [PATCH 1/2] Revert "selftests/bpf: Skip perf hw events test if the - setup disabled it" +Date: Thu, 18 Jun 2020 13:45:04 -0700 +Subject: [PATCH] Revert "selftests/bpf: Skip perf hw events test if the setup + disabled it" This reverts commit da43712a7262891317883d4b3a909fb18dac4b1d. + +Signed-off-by: Khem Raj <raj.khem@gmail.com> --- .../selftests/bpf/prog_tests/stacktrace_build_id_nmi.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/tools/testing/selftests/bpf/prog_tests/stacktrace_build_id_nmi.c b/tools/testing/selftests/bpf/prog_tests/stacktrace_build_id_nmi.c -index 1735faf17536..f62aa0eb959b 100644 +index 437cb93e72ac..f62aa0eb959b 100644 --- a/tools/testing/selftests/bpf/prog_tests/stacktrace_build_id_nmi.c +++ b/tools/testing/selftests/bpf/prog_tests/stacktrace_build_id_nmi.c @@ -49,12 +49,8 @@ void test_stacktrace_build_id_nmi(void) @@ -20,7 +22,7 @@ index 1735faf17536..f62aa0eb959b 100644 - if (pmu_fd < 0 && errno == ENOENT) { - printf("%s:SKIP:no PERF_COUNT_HW_CPU_CYCLES\n", __func__); - test__skip(); -- goto cleanup; +- goto close_prog; - } - if (CHECK(pmu_fd < 0, "perf_event_open", "err %d errno %d\n", + if (CHECK(pmu_fd < 0, "perf_event_open", @@ -29,5 +31,5 @@ index 1735faf17536..f62aa0eb959b 100644 goto close_prog; -- -2.26.0 +2.27.0 diff --git a/meta-raspberrypi/recipes-kernel/linux/files/android-drivers.cfg b/meta-raspberrypi/recipes-kernel/linux/files/android-drivers.cfg new file mode 100644 index 000000000..f74ac0e1c --- /dev/null +++ b/meta-raspberrypi/recipes-kernel/linux/files/android-drivers.cfg @@ -0,0 +1,8 @@ +CONFIG_ANDROID=y + +#CONFIG_ANDROID_BINDERFS is not set +CONFIG_ANDROID_BINDER_IPC=y +CONFIG_ANDROID_BINDER_DEVICES="binder" + +CONFIG_ASHMEM=y + diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc index 3c3a8e534..3219a231f 100644 --- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc +++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi.inc @@ -130,11 +130,13 @@ do_compile_append() { } do_deploy_append() { - # Deploy cmdline.txt - install -d ${DEPLOYDIR}/bcm2835-bootfiles - PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}" - if [ ${PITFT} = "1" ]; then - PITFT_PARAMS="fbcon=map:10 fbcon=font:VGA8x8" + # Deploy cmdline.txt only for the main kernel package + if [ ${KERNEL_PACKAGE_NAME} = "kernel" ]; then + install -d ${DEPLOYDIR}/${BOOTFILES_DIR_NAME} + PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}" + if [ ${PITFT} = "1" ]; then + PITFT_PARAMS="fbcon=map:10 fbcon=font:VGA8x8" + fi + echo "${CMDLINE}${PITFT_PARAMS}" > ${DEPLOYDIR}/${BOOTFILES_DIR_NAME}/cmdline.txt fi - echo "${CMDLINE}${PITFT_PARAMS}" > ${DEPLOYDIR}/bcm2835-bootfiles/cmdline.txt } diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.19.bb b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.19.bb index 03053dac3..93a29f008 100644 --- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.19.bb +++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_4.19.bb @@ -1,7 +1,7 @@ -LINUX_VERSION ?= "4.19.120" +LINUX_VERSION ?= "4.19.126" LINUX_RPI_BRANCH ?= "rpi-4.19.y" -SRCREV = "9da67d7329873623bd5c13fae5835d76d5be8806" +SRCREV = "f6b3ac28f0a9137d4c24c0b8832e693bbd16f5b7" require linux-raspberrypi_4.19.inc diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.bb b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.bb index ec0767ee6..4a7182f8a 100644 --- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.bb +++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.bb @@ -1,13 +1,13 @@ -LINUX_VERSION ?= "5.4.40" +LINUX_VERSION ?= "5.4.72" LINUX_RPI_BRANCH ?= "rpi-5.4.y" -SRCREV = "97badb4baeb8999263a9bc2fa85c3060ffff344b" +SRCREV_machine = "154de7bbd5844a824a635d4f9e3f773c15c6ce11" +SRCREV_meta = "5d52d9eea95fa09d404053360c2351b2b91b323b" require linux-raspberrypi_5.4.inc -SRC_URI += "file://0001-perf-Make-perf-able-to-build-with-latest-libbfd.patch \ - file://0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch \ +SRC_URI += "file://0001-Revert-selftests-bpf-Skip-perf-hw-events-test-if-the.patch \ file://0002-Revert-selftests-bpf-Fix-perf_buffer-test-on-systems.patch \ - file://0001-selftest-bpf-Use-CHECK-macro-instead-of-RET_IF.patch \ file://powersave.cfg \ + file://android-drivers.cfg \ " diff --git a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.inc b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.inc index 232f8a97d..9e8934a70 100644 --- a/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.inc +++ b/meta-raspberrypi/recipes-kernel/linux/linux-raspberrypi_5.4.inc @@ -1,7 +1,10 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/linux-raspberrypi:" +KMETA = "kernel-meta" + SRC_URI = " \ - git://github.com/raspberrypi/linux.git;branch=${LINUX_RPI_BRANCH} \ + git://github.com/raspberrypi/linux.git;name=machine;branch=${LINUX_RPI_BRANCH} \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.4;destsuffix=${KMETA} \ " SRC_URI_remove = "file://rpi-kernel-misc.cfg" |