summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--classes/sdcard_image-rpi.bbclass23
-rw-r--r--conf/machine/raspberrypi.conf3
-rw-r--r--recipes-bcm/common/firmware.inc4
-rw-r--r--recipes-bsp/rpi-mkimage/rpi-mkimage_git.bb2
-rw-r--r--recipes-kernel/linux/linux-raspberrypi.inc24
-rw-r--r--recipes-kernel/linux/linux-raspberrypi_3.18.5.bb5
6 files changed, 52 insertions, 9 deletions
diff --git a/classes/sdcard_image-rpi.bbclass b/classes/sdcard_image-rpi.bbclass
index 71b6477..63cd62a 100644
--- a/classes/sdcard_image-rpi.bbclass
+++ b/classes/sdcard_image-rpi.bbclass
@@ -50,7 +50,7 @@ IMAGE_DEPENDS_rpi-sdimg = " \
50 dosfstools-native \ 50 dosfstools-native \
51 virtual/kernel \ 51 virtual/kernel \
52 ${IMAGE_BOOTLOADER} \ 52 ${IMAGE_BOOTLOADER} \
53 ${@base_contains("KERNEL_IMAGETYPE", "uImage", "u-boot", "",d)} \ 53 ${@bb.utils.contains('KERNEL_IMAGETYPE', 'uImage', 'u-boot', '',d)} \
54 " 54 "
55 55
56# SD card image name 56# SD card image name
@@ -99,12 +99,23 @@ IMAGE_CMD_rpi-sdimg () {
99 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles/* ::/ 99 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles/* ::/
100 case "${KERNEL_IMAGETYPE}" in 100 case "${KERNEL_IMAGETYPE}" in
101 "uImage") 101 "uImage")
102 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/u-boot.img ::kernel.img 102 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/u-boot.img ::kernel.img
103 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::uImage 103 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::uImage
104 ;; 104 ;;
105 *) 105 *)
106 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::kernel.img 106 if test -n "${KERNEL_DEVICETREE}"; then
107 ;; 107 for DTB in ${KERNEL_DEVICETREE}; do
108 if echo ${DTB} | grep -q '/dts/'; then
109 bbwarn "${DTB} contains the full path to the the dts file, but only the dtb name should be used."
110 DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'`
111 fi
112 DTB_BASE_NAME=`basename ${DTB} .dtb`
113
114 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${DTB_BASE_NAME}.dtb ::${DTB_BASE_NAME}.dtb
115 done
116 fi
117 mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}${KERNEL_INITRAMFS}-${MACHINE}.bin ::kernel.img
118 ;;
108 esac 119 esac
109 120
110 if [ -n ${FATPAYLOAD} ] ; then 121 if [ -n ${FATPAYLOAD} ] ; then
diff --git a/conf/machine/raspberrypi.conf b/conf/machine/raspberrypi.conf
index 732ba32..01021ca 100644
--- a/conf/machine/raspberrypi.conf
+++ b/conf/machine/raspberrypi.conf
@@ -24,6 +24,9 @@ XSERVER = " \
24 24
25KERNEL_IMAGETYPE ?= "Image" 25KERNEL_IMAGETYPE ?= "Image"
26 26
27# Really supported starting from linux-rapsberry 3.18.y only !
28#KERNEL_DEVICETREE ?= "bcm2708-rpi-b.dtb bcm2708-rpi-b-plus.dtb"
29
27MACHINE_FEATURES = "kernel26 apm usbhost keyboard vfat ext2 screen touchscreen alsa bluetooth wifi sdio" 30MACHINE_FEATURES = "kernel26 apm usbhost keyboard vfat ext2 screen touchscreen alsa bluetooth wifi sdio"
28 31
29#RaspberryPi has no hardware clock 32#RaspberryPi has no hardware clock
diff --git a/recipes-bcm/common/firmware.inc b/recipes-bcm/common/firmware.inc
index 3223330..145ecce 100644
--- a/recipes-bcm/common/firmware.inc
+++ b/recipes-bcm/common/firmware.inc
@@ -1,5 +1,5 @@
1RPIFW_SRCREV ?= "43c5b2fc9bdb0a43ba67661b8677445e71ae9e82" 1RPIFW_SRCREV ?= "d426cd1e79f0785fae6c37db79da7d6dae39716d"
2RPIFW_DATE ?= "20140817" 2RPIFW_DATE ?= "20150204"
3RPIFW_SRC_URI ?= "git://github.com/raspberrypi/firmware.git;protocol=git;branch=master" 3RPIFW_SRC_URI ?= "git://github.com/raspberrypi/firmware.git;protocol=git;branch=master"
4RPIFW_S ?= "${WORKDIR}/git" 4RPIFW_S ?= "${WORKDIR}/git"
5 5
diff --git a/recipes-bsp/rpi-mkimage/rpi-mkimage_git.bb b/recipes-bsp/rpi-mkimage/rpi-mkimage_git.bb
index 24da7a0..1778275 100644
--- a/recipes-bsp/rpi-mkimage/rpi-mkimage_git.bb
+++ b/recipes-bsp/rpi-mkimage/rpi-mkimage_git.bb
@@ -5,7 +5,7 @@ SECTION = "bootloader"
5 5
6DEPENDS = "python" 6DEPENDS = "python"
7 7
8SRCREV = "330c72c2412f75a32932c4d9b51c9c678bce4180" 8SRCREV = "b9d7a8ac626e377577aa6900da5c5a965cafb66c"
9SRC_URI = " \ 9SRC_URI = " \
10 git://github.com/raspberrypi/tools.git;branch=master;protocol=git \ 10 git://github.com/raspberrypi/tools.git;branch=master;protocol=git \
11 file://License \ 11 file://License \
diff --git a/recipes-kernel/linux/linux-raspberrypi.inc b/recipes-kernel/linux/linux-raspberrypi.inc
index 4145b1a..ff0c5ce 100644
--- a/recipes-kernel/linux/linux-raspberrypi.inc
+++ b/recipes-kernel/linux/linux-raspberrypi.inc
@@ -21,6 +21,20 @@ CMDLINE_raspberrypi = "dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA
21 21
22UDEV_GE_141 ?= "1" 22UDEV_GE_141 ?= "1"
23 23
24# Set programmatically some variables during recipe parsing
25# See http://www.yoctoproject.org/docs/current/bitbake-user-manual/bitbake-user-manual.html#anonymous-python-functions
26python __anonymous () {
27 kerneltype = d.getVar('KERNEL_IMAGETYPE', True)
28 kerneldt = d.getVar('KERNEL_DEVICETREE', True)
29
30 # Add dependency to 'rpi-mkimage-native' package only if RPi bootloader is used with DT-enable kernel
31 if kerneldt:
32 if kerneltype != 'uImage' and len(kerneldt.strip()) > 1:
33 depends = d.getVar("DEPENDS", True)
34 depends = "%s rpi-mkimage-native" % depends
35 d.setVar("DEPENDS", depends)
36}
37
24do_kernel_configme_prepend() { 38do_kernel_configme_prepend() {
25 install -m 0644 ${S}/arch/${ARCH}/configs/${KERNEL_DEFCONFIG} ${WORKDIR}/defconfig || die "No default configuration for ${MACHINE} / ${KERNEL_DEFCONFIG} available." 39 install -m 0644 ${S}/arch/${ARCH}/configs/${KERNEL_DEFCONFIG} ${WORKDIR}/defconfig || die "No default configuration for ${MACHINE} / ${KERNEL_DEFCONFIG} available."
26} 40}
@@ -34,3 +48,13 @@ do_deploy_append() {
34 install -d ${DEPLOYDIR}/bcm2835-bootfiles 48 install -d ${DEPLOYDIR}/bcm2835-bootfiles
35 echo "${CMDLINE}" > ${DEPLOYDIR}/bcm2835-bootfiles/cmdline.txt 49 echo "${CMDLINE}" > ${DEPLOYDIR}/bcm2835-bootfiles/cmdline.txt
36} 50}
51
52do_rpiboot_mkimage() {
53 if test "x${KERNEL_IMAGETYPE}" != "xuImage" ; then
54 if test -n "${KERNEL_DEVICETREE}"; then
55 # Add RPi bootloader trailer to kernel image to enable DeviceTree support
56 ${STAGING_DIR_NATIVE}/usr/lib/rpi-mkimage/mkknlimg --dtok ${KERNEL_OUTPUT} ${KERNEL_OUTPUT}
57 fi
58 fi
59}
60addtask rpiboot_mkimage before do_install after do_compile
diff --git a/recipes-kernel/linux/linux-raspberrypi_3.18.5.bb b/recipes-kernel/linux/linux-raspberrypi_3.18.5.bb
new file mode 100644
index 0000000..663522e
--- /dev/null
+++ b/recipes-kernel/linux/linux-raspberrypi_3.18.5.bb
@@ -0,0 +1,5 @@
1SRCREV = "a6cf3c99bc89e2c010c2f78fbf9e3ed478ccfd46"
2SRC_URI = "git://github.com/raspberrypi/linux.git;protocol=git;branch=rpi-3.18.y \
3 file://sl030raspberrypii2ckernel.patch \
4 "
5require linux-raspberrypi.inc