diff options
Diffstat (limited to 'meta/recipes-kernel/linux')
18 files changed, 334 insertions, 174 deletions
diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb b/meta/recipes-kernel/linux/kernel-devsrc.bb index 196c8c7a24..7004261ce5 100644 --- a/meta/recipes-kernel/linux/kernel-devsrc.bb +++ b/meta/recipes-kernel/linux/kernel-devsrc.bb @@ -6,7 +6,6 @@ development or external module builds" SECTION = "kernel" LICENSE = "GPLv2" -LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6" inherit linux-kernel-base @@ -28,9 +27,6 @@ do_configure[noexec] = "1" do_compile[noexec] = "1" do_populate_sysroot[noexec] = "1" -# Define where the kernel headers are installed on the target as well as where -# they are staged. -KERNEL_SRC_PATH = "/usr/src/kernel" S = "${STAGING_KERNEL_DIR}" B = "${STAGING_KERNEL_BUILDDIR}" @@ -57,6 +53,13 @@ do_install() { # architecture (since scripts and helpers are native format). KBUILD_OUTPUT="$kerneldir" oe_runmake -C $kerneldir CC="${KERNEL_CC}" LD="${KERNEL_LD}" clean _mrproper_scripts + # make clean generates an absolute path symlink called "source" + # in $kerneldir points to $kerneldir, which doesn't make any + # sense, so remove it. + if [ -L $kerneldir/source ]; then + bbnote "Removing $kerneldir/source symlink" + rm -f $kerneldir/source + fi # As of Linux kernel version 3.0.1, the clean target removes # arch/powerpc/lib/crtsavres.o which is present in diff --git a/meta/recipes-kernel/linux/linux-dtb.inc b/meta/recipes-kernel/linux/linux-dtb.inc index 651a19e4ae..0174c80d85 100644 --- a/meta/recipes-kernel/linux/linux-dtb.inc +++ b/meta/recipes-kernel/linux/linux-dtb.inc @@ -1,6 +1,8 @@ # Support for device tree generation FILES_kernel-devicetree = "/${KERNEL_IMAGEDEST}/devicetree*" +PACKAGE_WRITE_DEPS += "virtual/update-alternatives-native" + python __anonymous () { d.appendVar("PACKAGES", " kernel-devicetree") } @@ -33,42 +35,57 @@ do_compile_append() { do_install_append() { for DTB in ${KERNEL_DEVICETREE}; do DTB=`normalize_dtb "${DTB}"` - DTB_BASE_NAME=`basename ${DTB} .dtb` - DTB_SYMLINK_NAME=`echo ${KERNEL_IMAGE_SYMLINK_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` - DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"` - install -m 0644 ${DTB_PATH} ${D}/${KERNEL_IMAGEDEST}/devicetree-${DTB_SYMLINK_NAME}.dtb + DTB_EXT=${DTB##*.} + DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"` + for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do + symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME} + DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` + DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"` + install -m 0644 ${DTB_PATH} ${D}/${KERNEL_IMAGEDEST}/devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} + done done } do_deploy_append() { for DTB in ${KERNEL_DEVICETREE}; do DTB=`normalize_dtb "${DTB}"` - DTB_BASE_NAME=`basename ${DTB} .dtb` - DTB_NAME=`echo ${KERNEL_IMAGE_BASE_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` - DTB_SYMLINK_NAME=`echo ${KERNEL_IMAGE_SYMLINK_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` - DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"` - install -d ${DEPLOYDIR} - install -m 0644 ${DTB_PATH} ${DEPLOYDIR}/${DTB_NAME}.dtb - ln -sf ${DTB_NAME}.dtb ${DEPLOYDIR}/${DTB_SYMLINK_NAME}.dtb + DTB_EXT=${DTB##*.} + DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"` + for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do + base_name=${type}"-"${KERNEL_IMAGE_BASE_NAME} + symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME} + DTB_NAME=`echo ${base_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` + DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` + DTB_PATH=`get_real_dtb_path_in_kernel "${DTB}"` + install -d ${DEPLOYDIR} + install -m 0644 ${DTB_PATH} ${DEPLOYDIR}/${DTB_NAME}.${DTB_EXT} + ln -sf ${DTB_NAME}.${DTB_EXT} ${DEPLOYDIR}/${DTB_SYMLINK_NAME}.${DTB_EXT} + done done } pkg_postinst_kernel-devicetree () { cd /${KERNEL_IMAGEDEST} - for DTB in ${KERNEL_DEVICETREE} - do - DTB_BASE_NAME=`basename ${DTB} | awk -F "." '{print $1}'` - DTB_SYMLINK_NAME=`echo ${KERNEL_IMAGE_SYMLINK_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` - update-alternatives --install /${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.dtb ${DTB_BASE_NAME}.dtb /boot/devicetree-${DTB_SYMLINK_NAME}.dtb ${KERNEL_PRIORITY} || true + for DTB in ${KERNEL_DEVICETREE}; do + for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do + symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME} + DTB_EXT=${DTB##*.} + DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"` + DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` + update-alternatives --install /${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.${DTB_EXT} ${DTB_BASE_NAME}.${DTB_EXT} devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true + done done } pkg_postrm_kernel-devicetree () { cd /${KERNEL_IMAGEDEST} - for DTB in ${KERNEL_DEVICETREE} - do - DTB_BASE_NAME=`basename ${DTB} | awk -F "." '{print $1}'` - DTB_SYMLINK_NAME=`echo ${KERNEL_IMAGE_SYMLINK_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` - update-alternatives --remove ${DTB_BASE_NAME}.dtb /boot/devicetree-${DTB_SYMLINK_NAME}.dtb ${KERNEL_PRIORITY} || true + for DTB in ${KERNEL_DEVICETREE}; do + for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do + symlink_name=${type}"-"${KERNEL_IMAGE_SYMLINK_NAME} + DTB_EXT=${DTB##*.} + DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"` + DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` + update-alternatives --remove ${DTB_BASE_NAME}.${DTB_EXT} devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true + done done } diff --git a/meta/recipes-kernel/linux/linux-dummy.bb b/meta/recipes-kernel/linux/linux-dummy.bb index cc0e4e64a9..994ac7459f 100644 --- a/meta/recipes-kernel/linux/linux-dummy.bb +++ b/meta/recipes-kernel/linux/linux-dummy.bb @@ -18,6 +18,8 @@ FILES_kernel-modules = "" ALLOW_EMPTY_kernel-modules = "1" DESCRIPTION_kernel-modules = "Kernel modules meta package" +INHIBIT_DEFAULT_DEPS = "1" + #COMPATIBLE_MACHINE = "your_machine" PR = "r1" diff --git a/meta/recipes-kernel/linux/linux-yocto-dev.bb b/meta/recipes-kernel/linux/linux-yocto-dev.bb index 694e6bde95..bf67f81f07 100644 --- a/meta/recipes-kernel/linux/linux-yocto-dev.bb +++ b/meta/recipes-kernel/linux/linux-yocto-dev.bb @@ -14,14 +14,6 @@ require recipes-kernel/linux/linux-yocto.inc # provide this .inc to set specific revisions include recipes-kernel/linux/linux-yocto-dev-revisions.inc -# Skip processing of this recipe if it is not explicitly specified as the -# PREFERRED_PROVIDER for virtual/kernel. This avoids network access required -# by the use of AUTOREV SRCREVs, which are the default for this recipe. -python () { - if d.getVar("PREFERRED_PROVIDER_virtual/kernel", True) != "linux-yocto-dev": - raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-dev to enable it") -} - KBRANCH = "standard/base" KMETA = "kernel-meta" @@ -36,16 +28,20 @@ SRC_URI = "git://git.yoctoproject.org/linux-yocto-dev.git;branch=${KBRANCH};name SRCREV_machine ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}' SRCREV_meta ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}' -LINUX_VERSION ?= "4.4-rc+" +LINUX_VERSION ?= "4.11-rc+" LINUX_VERSION_EXTENSION ?= "-yoctodev-${LINUX_KERNEL_TYPE}" PV = "${LINUX_VERSION}+git${SRCPV}" COMPATIBLE_MACHINE = "(qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64)" +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" + # Functionality flags KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc" KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}" +KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc" KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}" +KERNEL_VERSION_SANITY_SKIP = "1" diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_4.1.bb b/meta/recipes-kernel/linux/linux-yocto-rt_4.1.bb index 4a6928a7d1..21cc635bf4 100644 --- a/meta/recipes-kernel/linux/linux-yocto-rt_4.1.bb +++ b/meta/recipes-kernel/linux/linux-yocto-rt_4.1.bb @@ -2,13 +2,22 @@ KBRANCH ?= "standard/preempt-rt/base" require recipes-kernel/linux/linux-yocto.inc -SRCREV_machine ?= "2a4c22b03d434f7695e607b6ad30f77671985a6d" -SRCREV_meta ?= "56dcb623ebf5e83d65fdb4eb270f23676bb000a5" +# Skip processing of this recipe if it is not explicitly specified as the +# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying +# to build multiple virtual/kernel providers, e.g. as dependency of +# core-image-rt-sdk, core-image-rt. +python () { + if d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt": + raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") +} + +SRCREV_machine ?= "f793c71d51277bdb14d6854c8cbcc09b4f5936b4" +SRCREV_meta ?= "7140ddb86e4b01529185e6d4a606001ad152b8f3" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.1.git;branch=${KBRANCH};name=machine \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.1;destsuffix=${KMETA}" -LINUX_VERSION ?= "4.1.18" +LINUX_VERSION ?= "4.1.38" PV = "${LINUX_VERSION}+git${SRCPV}" diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_4.10.bb b/meta/recipes-kernel/linux/linux-yocto-rt_4.10.bb new file mode 100644 index 0000000000..ed811fb21e --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto-rt_4.10.bb @@ -0,0 +1,38 @@ +KBRANCH ?= "standard/preempt-rt/base" + +require recipes-kernel/linux/linux-yocto.inc + +# Skip processing of this recipe if it is not explicitly specified as the +# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying +# to build multiple virtual/kernel providers, e.g. as dependency of +# core-image-rt-sdk, core-image-rt. +python () { + if d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt": + raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") +} + +SRCREV_machine ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_meta ?= "ad2e885015c5bf8adeef5cb789b535fc3c0dd396" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.10.git;branch=${KBRANCH};name=machine \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.10;destsuffix=${KMETA}" + +LINUX_VERSION ?= "4.10.9" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +LINUX_KERNEL_TYPE = "preempt-rt" + +COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" + +# Functionality flags +KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc" +KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}" +KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" +KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc" diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_4.4.bb b/meta/recipes-kernel/linux/linux-yocto-rt_4.4.bb index 7251c07fce..660ad8a07e 100644 --- a/meta/recipes-kernel/linux/linux-yocto-rt_4.4.bb +++ b/meta/recipes-kernel/linux/linux-yocto-rt_4.4.bb @@ -1,14 +1,23 @@ -KBRANCH ?= "standard/preempt-rt" +KBRANCH ?= "standard/preempt-rt/base" require recipes-kernel/linux/linux-yocto.inc -SRCREV_machine ?= "853991833cc5140ca25450e81bf6b822d537a6ac" -SRCREV_meta ?= "8b6a7d80344837fd64163008521a31a6f891313e" +# Skip processing of this recipe if it is not explicitly specified as the +# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying +# to build multiple virtual/kernel providers, e.g. as dependency of +# core-image-rt-sdk, core-image-rt. +python () { + if d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt": + raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") +} + +SRCREV_machine ?= "1af95315c6ab3672c8c7191873ef041a6c29ad70" +SRCREV_meta ?= "d6733af2080f8c0775569adc0826eb0c8954fc5e" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.4.git;branch=${KBRANCH};name=machine \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.4;destsuffix=${KMETA}" -LINUX_VERSION ?= "4.4.3" +LINUX_VERSION ?= "4.4.60" PV = "${LINUX_VERSION}+git${SRCPV}" diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_4.9.bb b/meta/recipes-kernel/linux/linux-yocto-rt_4.9.bb new file mode 100644 index 0000000000..4ca7883122 --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto-rt_4.9.bb @@ -0,0 +1,38 @@ +KBRANCH ?= "standard/preempt-rt/base" + +require recipes-kernel/linux/linux-yocto.inc + +# Skip processing of this recipe if it is not explicitly specified as the +# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying +# to build multiple virtual/kernel providers, e.g. as dependency of +# core-image-rt-sdk, core-image-rt. +python () { + if d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt": + raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") +} + +SRCREV_machine ?= "b6f5c933ce66e4a00412bb5c5691a2ab4187c979" +SRCREV_meta ?= "803b8d600e45afa0375459bf599fe365571a3866" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.9.git;branch=${KBRANCH};name=machine \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.9;destsuffix=${KMETA}" + +LINUX_VERSION ?= "4.9.21" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +LINUX_KERNEL_TYPE = "preempt-rt" + +COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" + +# Functionality flags +KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc" +KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}" +KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" +KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc" diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_4.1.bb b/meta/recipes-kernel/linux/linux-yocto-tiny_4.1.bb index 41a79f17b7..ce8aea628b 100644 --- a/meta/recipes-kernel/linux/linux-yocto-tiny_4.1.bb +++ b/meta/recipes-kernel/linux/linux-yocto-tiny_4.1.bb @@ -1,23 +1,23 @@ -KBRANCH ?= "standard/tiny/base" +KBRANCH ?= "standard/tiny/common-pc" LINUX_KERNEL_TYPE = "tiny" KCONFIG_MODE = "--allnoconfig" require recipes-kernel/linux/linux-yocto.inc -LINUX_VERSION ?= "4.1.18" +LINUX_VERSION ?= "4.1.38" KMETA = "kernel-meta" KCONF_BSP_AUDIT_LEVEL = "2" -SRCREV_machine ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_meta ?= "56dcb623ebf5e83d65fdb4eb270f23676bb000a5" +SRCREV_machine ?= "2ce56d130ddff67f43ec857cc51cd347666a0078" +SRCREV_meta ?= "7140ddb86e4b01529185e6d4a606001ad152b8f3" PV = "${LINUX_VERSION}+git${SRCPV}" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.1.git;branch=${KBRANCH};name=machine \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.1;destsuffix=${KMETA}" -COMPATIBLE_MACHINE = "(qemux86)" +COMPATIBLE_MACHINE = "(qemux86$)" # Functionality flags KERNEL_FEATURES = "" diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_4.10.bb b/meta/recipes-kernel/linux/linux-yocto-tiny_4.10.bb new file mode 100644 index 0000000000..61e680a111 --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto-tiny_4.10.bb @@ -0,0 +1,25 @@ +KBRANCH ?= "standard/tiny/common-pc" +LINUX_KERNEL_TYPE = "tiny" +KCONFIG_MODE = "--allnoconfig" + +require recipes-kernel/linux/linux-yocto.inc + +LINUX_VERSION ?= "4.10.9" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +SRCREV_machine ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_meta ?= "ad2e885015c5bf8adeef5cb789b535fc3c0dd396" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.10.git;branch=${KBRANCH};name=machine \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.10;destsuffix=${KMETA}" + +COMPATIBLE_MACHINE = "(qemux86$)" + +# Functionality flags +KERNEL_FEATURES = "" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_4.4.bb b/meta/recipes-kernel/linux/linux-yocto-tiny_4.4.bb index 0d35bc3ce8..04f719c5d0 100644 --- a/meta/recipes-kernel/linux/linux-yocto-tiny_4.4.bb +++ b/meta/recipes-kernel/linux/linux-yocto-tiny_4.4.bb @@ -1,23 +1,23 @@ -KBRANCH ?= "standard/tiny/base" +KBRANCH ?= "standard/tiny/common-pc" LINUX_KERNEL_TYPE = "tiny" KCONFIG_MODE = "--allnoconfig" require recipes-kernel/linux/linux-yocto.inc -LINUX_VERSION ?= "4.4.3" +LINUX_VERSION ?= "4.4.60" KMETA = "kernel-meta" KCONF_BSP_AUDIT_LEVEL = "2" -SRCREV_machine ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_meta ?= "8b6a7d80344837fd64163008521a31a6f891313e" +SRCREV_machine ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_meta ?= "d6733af2080f8c0775569adc0826eb0c8954fc5e" PV = "${LINUX_VERSION}+git${SRCPV}" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.4.git;branch=${KBRANCH};name=machine \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.4;destsuffix=${KMETA}" -COMPATIBLE_MACHINE = "(qemux86)" +COMPATIBLE_MACHINE = "(qemux86$)" # Functionality flags KERNEL_FEATURES = "" diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_4.9.bb b/meta/recipes-kernel/linux/linux-yocto-tiny_4.9.bb new file mode 100644 index 0000000000..62aedb37de --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto-tiny_4.9.bb @@ -0,0 +1,25 @@ +KBRANCH ?= "standard/tiny/common-pc" +LINUX_KERNEL_TYPE = "tiny" +KCONFIG_MODE = "--allnoconfig" + +require recipes-kernel/linux/linux-yocto.inc + +LINUX_VERSION ?= "4.9.21" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +SRCREV_machine ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_meta ?= "803b8d600e45afa0375459bf599fe365571a3866" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.9.git;branch=${KBRANCH};name=machine \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.9;destsuffix=${KMETA}" + +COMPATIBLE_MACHINE = "(qemux86$)" + +# Functionality flags +KERNEL_FEATURES = "" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" diff --git a/meta/recipes-kernel/linux/linux-yocto.inc b/meta/recipes-kernel/linux/linux-yocto.inc index 6b161fc064..637506a2a8 100644 --- a/meta/recipes-kernel/linux/linux-yocto.inc +++ b/meta/recipes-kernel/linux/linux-yocto.inc @@ -8,6 +8,15 @@ UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)" INC_PR = "r4" +# Skip processing of this recipe if it is not explicitly specified as the +# PREFERRED_PROVIDER for virtual/kernel. This avoids network access required +# by the use of AUTOREV SRCREVs, which are the default for this recipe. +python () { + if d.getVar("PREFERRED_PROVIDER_virtual/kernel") != d.getVar("PN"): + d.delVar("BB_DONT_CACHE") + raise bb.parse.SkipPackage("Set PREFERRED_PROVIDER_virtual/kernel to %s to enable it" % (d.getVar("PN"))) +} + DEPENDS += "xz-native bc-native" DEPENDS_append_aarch64 = " libgcc" KERNEL_CC_append_aarch64 = " ${TOOLCHAIN_OPTIONS}" @@ -17,6 +26,8 @@ DEPENDS_append_nios2 = " libgcc" KERNEL_CC_append_nios2 = " ${TOOLCHAIN_OPTIONS}" KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}" +KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc" + # A KMACHINE is the mapping of a yocto $MACHINE to what is built # by the kernel. This is typically the branch that should be built, # and it can be specific to the machine or shared @@ -35,6 +46,7 @@ SRCREV_FORMAT ?= "meta_machine" # 2: report options that are not hardware related, but set by a BSP KCONF_AUDIT_LEVEL ?= "1" KCONF_BSP_AUDIT_LEVEL ?= "0" +KMETA_AUDIT ?= "yes" LINUX_VERSION_EXTENSION ?= "-yocto-${LINUX_KERNEL_TYPE}" @@ -52,6 +64,6 @@ do_install_append(){ } # extra tasks -addtask kernel_link_vmlinux after do_compile before do_install +addtask kernel_version_sanity_check after do_kernel_metadata do_kernel_checkout before do_compile addtask validate_branches before do_patch after do_kernel_checkout addtask kernel_configcheck after do_configure before do_compile diff --git a/meta/recipes-kernel/linux/linux-yocto/0001-Fix-qemux86-pat-issue.patch b/meta/recipes-kernel/linux/linux-yocto/0001-Fix-qemux86-pat-issue.patch deleted file mode 100644 index 367d9b4ace..0000000000 --- a/meta/recipes-kernel/linux/linux-yocto/0001-Fix-qemux86-pat-issue.patch +++ /dev/null @@ -1,100 +0,0 @@ -From 9bfb2c711f66fc8eb6482f5ca6ea33c2ec1d792f Mon Sep 17 00:00:00 2001 -From: Richard Purdie <richard.purdie@linuxfoundation.org> -Date: Sat, 13 Feb 2016 17:36:23 +0000 -Subject: [PATCH] Fix qemux86 pat issue - -on qemux86, X doesn't start and there is -a backtrace in the logs: - -x86/PAT: Xorg:705 map pfn expected mapping type uncached-minus for [mem 0xfd000000-0xfdffffff], got write-combining -------------[ cut here ]------------ -WARNING: CPU: 0 PID: 705 at /media/build1/poky/build/tmp/work-shared/qemux86/kernel-source/arch/x86/mm/pat.c:985 untrack_pfn+0xaf/0xc0() -Modules linked in: uvesafb -CPU: 0 PID: 705 Comm: Xorg Not tainted 4.4.1-yocto-standard #1 -Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.8.2-0-g33fbe13 by qemu-project.org 04/01/2014 - 00000000 00000000 cf14dd78 c1397ab2 00000000 cf14dda8 c1051477 c1aa4f6c - 00000000 000002c1 c1a9fa4c 000003d9 c104b98f c104b98f cf244000 b6355000 - 00000000 cf14ddb8 c1051552 00000009 00000000 cf14dde0 c104b98f cf14ddd0 -Call Trace: - [<c1397ab2>] dump_stack+0x4b/0x79 - [<c1051477>] warn_slowpath_common+0x87/0xc0 - [<c104b98f>] ? untrack_pfn+0xaf/0xc0 - [<c104b98f>] ? untrack_pfn+0xaf/0xc0 - [<c1051552>] warn_slowpath_null+0x22/0x30 - [<c104b98f>] untrack_pfn+0xaf/0xc0 - [<c104d54c>] ? kmap_atomic_prot+0x3c/0xf0 - [<c114e17f>] unmap_single_vma+0x4ef/0x500 - [<c114f007>] unmap_vmas+0x37/0x50 - [<c1154f8f>] exit_mmap+0x5f/0xf0 - [<c104eedd>] mmput+0x2d/0xb0 - [<c105009c>] copy_process+0xd2c/0x13c0 - [<c1050892>] _do_fork+0x82/0x340 - [<c105f2d1>] ? SyS_rt_sigaction+0x51/0xa0 - [<c1050c3c>] SyS_clone+0x2c/0x30 - [<c1001a03>] do_syscall_32_irqs_on+0x53/0xb0 - [<c189a94a>] entry_INT80_32+0x2a/0x2a ----[ end trace be3e0a61097feddc ]--- -x86/PAT: Xorg:705 map pfn expected mapping type uncached-minus for [mem 0xfd000000-0xfdffffff], got write-combining - -The entry in question is setup by uvesafb which in its -uvesafb_ioremap() function calls ioremap_wc(). - -It appears that Xorg mmaps this from userspace, then later does a -fork() to execute a utility. At this point, when creating the vmas for -the new process, the pat code says "eeek!" as the protection mode for -the new vmas don't match the old one, returns -EINVAL, the process dies -and X goes with it. - -There are a few hammers we can hit this with, we can boot with "nopat" -option which makes the problem go away, or turn off CONFIG_X86_PAT. No -surprises there. Changing uvesafb to use mtrr=0 doesn't help since the -ioremap_wc call still happens. - -The real issue is the "expected mapping type uncached-minus for got -write-combining" message, it all goes wrong from there. - -Upon looking at the code and scratching my head for a long while, I -notice that there are two ways of representing the protection mode -data, "enum page_cache_mode" and "pgprot_t & _PAGE_CACHE_MASK". - -The exact meaning of pgprot_t depends on which CPU you're running, -older CPUs have errata meaning only a small number of bits can be used. -The exact mapping table is determined by __cachemode2pte_tbl and is -updated at boot by calls from update_cache_mode_entry(). - -The result of this if you map enum -> pgprot_t, then try to do pgprot_t --> enum, you can get different values since its not a 1:1 mapping. - -This means the comparison in reserve_pfn_range() where it does "pcm != -want_pcm" isn't correct and can trigger even in cases where there isn't -a problem. - -This can be "fixed" by doing cachemode2protval(pcm) != -cachemode2protval(want_pcm) and checking whether the protection bits -match, rather than the enum values, since in reality this is what we -really care about. With that change, X boots up just fine. - -We don't see this on qemux86-64 since that has more PAT bits working -and hence the values map correctly. - -Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> ---- - arch/x86/mm/pat.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/arch/x86/mm/pat.c b/arch/x86/mm/pat.c -index 031782e..11064fb 100644 ---- a/arch/x86/mm/pat.c -+++ b/arch/x86/mm/pat.c -@@ -833,7 +833,7 @@ static int reserve_pfn_range(u64 paddr, unsigned long size, pgprot_t *vma_prot, - if (ret) - return ret; - -- if (pcm != want_pcm) { -+ if (cachemode2protval(pcm) != cachemode2protval(want_pcm)) { - if (strict_prot || - !is_new_memtype_allowed(paddr, size, want_pcm, pcm)) { - free_memtype(paddr, paddr + size); --- -2.5.0 - diff --git a/meta/recipes-kernel/linux/linux-yocto_4.1.bb b/meta/recipes-kernel/linux/linux-yocto_4.1.bb index 9663966d8e..bf7f266ee6 100644 --- a/meta/recipes-kernel/linux/linux-yocto_4.1.bb +++ b/meta/recipes-kernel/linux/linux-yocto_4.1.bb @@ -11,20 +11,20 @@ KBRANCH_qemux86 ?= "standard/base" KBRANCH_qemux86-64 ?= "standard/base" KBRANCH_qemumips64 ?= "standard/mti-malta64" -SRCREV_machine_qemuarm ?= "96b21aab2adf2c9396f8cf579420a2e497923eae" -SRCREV_machine_qemuarm64 ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_machine_qemumips ?= "e0a6ffb62a4d28659e0e1be7b1a42a8ef499aa3b" -SRCREV_machine_qemuppc ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_machine_qemux86 ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_machine_qemux86-64 ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_machine_qemumips64 ?= "1b1349ca5a642086d4b92347fb9d1de1c6eab742" -SRCREV_machine ?= "ec18b0b3bd6befd416078e81d775dab37b3f9124" -SRCREV_meta ?= "56dcb623ebf5e83d65fdb4eb270f23676bb000a5" +SRCREV_machine_qemuarm ?= "4d2c95e78cdc7d312b7ab231ce90dce317f45df9" +SRCREV_machine_qemuarm64 ?= "2ce56d130ddff67f43ec857cc51cd347666a0078" +SRCREV_machine_qemumips ?= "81454f95166056a253c8950980e025ee243d8074" +SRCREV_machine_qemuppc ?= "42c41e606b70fd73a202f4146c0480f5624b0a0e" +SRCREV_machine_qemux86 ?= "2ce56d130ddff67f43ec857cc51cd347666a0078" +SRCREV_machine_qemux86-64 ?= "2ce56d130ddff67f43ec857cc51cd347666a0078" +SRCREV_machine_qemumips64 ?= "8a481005da41f82d2a40bf8cb40334547160ab5b" +SRCREV_machine ?= "2ce56d130ddff67f43ec857cc51cd347666a0078" +SRCREV_meta ?= "7140ddb86e4b01529185e6d4a606001ad152b8f3" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.1.git;name=machine;branch=${KBRANCH}; \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.1;destsuffix=${KMETA}" -LINUX_VERSION ?= "4.1.18" +LINUX_VERSION ?= "4.1.38" PV = "${LINUX_VERSION}+git${SRCPV}" diff --git a/meta/recipes-kernel/linux/linux-yocto_4.10.bb b/meta/recipes-kernel/linux/linux-yocto_4.10.bb new file mode 100644 index 0000000000..2ef6a317cb --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto_4.10.bb @@ -0,0 +1,44 @@ +KBRANCH ?= "standard/base" + +require recipes-kernel/linux/linux-yocto.inc + +# board specific branches +KBRANCH_qemuarm ?= "standard/arm-versatile-926ejs" +KBRANCH_qemuarm64 ?= "standard/qemuarm64" +KBRANCH_qemumips ?= "standard/mti-malta32" +KBRANCH_qemuppc ?= "standard/qemuppc" +KBRANCH_qemux86 ?= "standard/base" +KBRANCH_qemux86-64 ?= "standard/base" +KBRANCH_qemumips64 ?= "standard/mti-malta64" + +SRCREV_machine_qemuarm ?= "718b0a546417a51a186179d5277713f301e1d7c9" +SRCREV_machine_qemuarm64 ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_machine_qemumips ?= "a803c18e328080eb9acc71510df3b7567bd87578" +SRCREV_machine_qemuppc ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_machine_qemux86 ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_machine_qemux86-64 ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_machine_qemumips64 ?= "97b912becdd8322f4e7f45dfe79e37fc5ea35f88" +SRCREV_machine ?= "fe0fb8da3d633d802776081e7ff2df73ff2983f2" +SRCREV_meta ?= "ad2e885015c5bf8adeef5cb789b535fc3c0dd396" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.10.git;name=machine;branch=${KBRANCH}; \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.10;destsuffix=${KMETA}" + +LINUX_VERSION ?= "4.10.9" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" + +COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64" + +# Functionality flags +KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc" +KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}" +KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" +KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}" diff --git a/meta/recipes-kernel/linux/linux-yocto_4.4.bb b/meta/recipes-kernel/linux/linux-yocto_4.4.bb index c5f160d786..d0eed65594 100644 --- a/meta/recipes-kernel/linux/linux-yocto_4.4.bb +++ b/meta/recipes-kernel/linux/linux-yocto_4.4.bb @@ -11,20 +11,20 @@ KBRANCH_qemux86 ?= "standard/base" KBRANCH_qemux86-64 ?= "standard/base" KBRANCH_qemumips64 ?= "standard/mti-malta64" -SRCREV_machine_qemuarm ?= "fa6a2f888d8adfe03b24ef32654be470960aed41" -SRCREV_machine_qemuarm64 ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_machine_qemumips ?= "a23b6eb1c5bca3bde2a9f94d9059274fff7da281" -SRCREV_machine_qemuppc ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_machine_qemux86 ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_machine_qemux86-64 ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_machine_qemumips64 ?= "8bbcb369cf605d1ada384f4b950da2abc5d1f4cc" -SRCREV_machine ?= "ff4c4ef15b51f45b9106d71bf1f62fe7c02e63c2" -SRCREV_meta ?= "8b6a7d80344837fd64163008521a31a6f891313e" +SRCREV_machine_qemuarm ?= "7d2a3c70d62f1e7f4eba571c49ff299db2bb3829" +SRCREV_machine_qemuarm64 ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_machine_qemumips ?= "6100965a51cf6b99f57cf8234aa982beb79455c9" +SRCREV_machine_qemuppc ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_machine_qemux86 ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_machine_qemux86-64 ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_machine_qemumips64 ?= "522e709fd7088e1a55e7a4708b1a07caa2ca4336" +SRCREV_machine ?= "0298d3765a5c474ff5776284d49111276510d4b4" +SRCREV_meta ?= "d6733af2080f8c0775569adc0826eb0c8954fc5e" SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.4.git;name=machine;branch=${KBRANCH}; \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.4;destsuffix=${KMETA}" -LINUX_VERSION ?= "4.4.3" +LINUX_VERSION ?= "4.4.60" PV = "${LINUX_VERSION}+git${SRCPV}" @@ -40,5 +40,3 @@ KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc" KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}" - -SRC_URI_append = " file://0001-Fix-qemux86-pat-issue.patch" diff --git a/meta/recipes-kernel/linux/linux-yocto_4.9.bb b/meta/recipes-kernel/linux/linux-yocto_4.9.bb new file mode 100644 index 0000000000..d6b96ed873 --- /dev/null +++ b/meta/recipes-kernel/linux/linux-yocto_4.9.bb @@ -0,0 +1,44 @@ +KBRANCH ?= "standard/base" + +require recipes-kernel/linux/linux-yocto.inc + +# board specific branches +KBRANCH_qemuarm ?= "standard/arm-versatile-926ejs" +KBRANCH_qemuarm64 ?= "standard/qemuarm64" +KBRANCH_qemumips ?= "standard/mti-malta32" +KBRANCH_qemuppc ?= "standard/qemuppc" +KBRANCH_qemux86 ?= "standard/base" +KBRANCH_qemux86-64 ?= "standard/base" +KBRANCH_qemumips64 ?= "standard/mti-malta64" + +SRCREV_machine_qemuarm ?= "bb5856d9b25d13c63a757a408cc8793d6f6302fa" +SRCREV_machine_qemuarm64 ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_machine_qemumips ?= "4b150e5ceca8b2c4fb01f74b1f7a57cdeae63762" +SRCREV_machine_qemuppc ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_machine_qemux86 ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_machine_qemux86-64 ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_machine_qemumips64 ?= "b300b94b77ed9fbb1c80a2d2441403ad2b7694a9" +SRCREV_machine ?= "81055b89bd32414ecaf95156ce9a5fa6643e530a" +SRCREV_meta ?= "803b8d600e45afa0375459bf599fe365571a3866" + +SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.9.git;name=machine;branch=${KBRANCH}; \ + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.9;destsuffix=${KMETA}" + +LINUX_VERSION ?= "4.9.21" + +PV = "${LINUX_VERSION}+git${SRCPV}" + +KMETA = "kernel-meta" +KCONF_BSP_AUDIT_LEVEL = "2" + +KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb" + +COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64" + +# Functionality flags +KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc" +KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}" +KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc" +KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc" +KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}" |
