diff options
author | Andrea Adami <andrea.adami@gmail.com> | 2010-09-29 01:46:19 +0200 |
---|---|---|
committer | Andrea Adami <andrea.adami@gmail.com> | 2010-09-29 01:51:43 +0200 |
commit | da451d4d552488e6ce6dad0a7fa4815a9c29459d (patch) | |
tree | 3de0c7690e001a75eb505c525a0369168f8c6bf0 /recipes/linux/linux-kexecboot.inc | |
parent | ee4a70a8d3832f0c4bae3c002692136e9ff6587f (diff) | |
download | openembedded-da451d4d552488e6ce6dad0a7fa4815a9c29459d.tar.gz |
linux-kexecboot: move recipes in /linux
* some old version might hopefully be pruned
Diffstat (limited to 'recipes/linux/linux-kexecboot.inc')
-rw-r--r-- | recipes/linux/linux-kexecboot.inc | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/recipes/linux/linux-kexecboot.inc b/recipes/linux/linux-kexecboot.inc new file mode 100644 index 0000000000..6356aeaaa2 --- /dev/null +++ b/recipes/linux/linux-kexecboot.inc @@ -0,0 +1,94 @@ +# We set INC_PR here, since a change in the kexecboot recipe will need to get picked up by *all* the kernels: +INC_PR = "r20" + +LOGO_SIZE = '${@base_conditional("GUI_MACHINE_CLASS", "bigscreen", "vga", "qvga", d)}' +SRC_URI = "file://${LOGO_SIZE}/logo_linux_clut224.ppm.bz2" + +require linux.inc + +INITRAMFS_IMAGE = "initramfs-kexecboot-image" + +# here we set master console on serial +CMDLINE = "console=tty1 console=ttyS0,115200n8" +CMDLINE_poodle = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1" +CMDLINE_akita = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1" +CMDLINE_collie = "console=tty1 console=ttySA0,115200n8 fbcon=rotate:1 mem=64M" +CMDLINE_spitz = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1" +CMDLINE_hx4700 = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1" + +PACKAGES = "" +PROVIDES = "" + +DOSRC = "http://www.do13.de/openzaurus/patches" +JLSRC = "http://www.cs.wisc.edu/~lenz/zaurus/files" +BASRC = "http://www.orca.cx/zaurus/patches" +CHSRC = "http://oz.drigon.com/patches" +TKSRC = "http://www.informatik.hu-berlin.de/~tkunze/zaurus/patches" + +# Zaurus machines need kernel size-check +KERNEL_IMAGE_MAXSIZE_akita = "1294336" +KERNEL_IMAGE_MAXSIZE_c7x0 = "1294336" +KERNEL_IMAGE_MAXSIZE_collie = "1048576" +KERNEL_IMAGE_MAXSIZE_poodle = "1294336" +KERNEL_IMAGE_MAXSIZE_tosa = "1294336" +KERNEL_IMAGE_MAXSIZE_spitz = "1294336" + +KERNEL_IMAGE_BASE_NAME = "${KERNEL_IMAGETYPE}-kexecboot-${PV}-${PR}-${MACHINE}" +KERNEL_IMAGE_SYMLINK_NAME = "${KERNEL_IMAGETYPE}-kexecboot-${MACHINE}" + +# use custom function until base_version_less_or_equal is fixed +# +def kernel_version_less_or_equal(variable, checkvalue, truevalue, falsevalue, d): + from bb import utils + result = bb.utils.vercmp_part(bb.data.getVar(variable,d,True), checkvalue) + if result <= 0: + return truevalue + else: + return falsevalue + +# force lzma compression for kernel (linux-kexecboot >= 2.6.32) +# force lzma compression for initramfs (linux-kexecboot >= 2.6.30) + +KERNEL_COMPRESSION = '${@kernel_version_less_or_equal("PV", "2.6.31", "", "CONFIG_KERNEL_LZMA=y", d)}' + +INITRAMFS_COMPRESSION = '${@kernel_version_less_or_equal("PV", "2.6.29", "", "CONFIG_INITRAMFS_COMPRESSION_LZMA=y", d)}' +INITRAMFS_COMPRESSION_SUFFIX = '${@kernel_version_less_or_equal("PV", "2.6.29", "gz", "lzma", d)}' +RD_COMPRESSION = '${@kernel_version_less_or_equal("PV", "2.6.29", "", "CONFIG_RD_LZMA=y", d)}' + +do_configure_append() { +sed -i -e /CONFIG_BLK_DEV_INITRD/d \ + -e /CONFIG_KEXEC/d \ + -e /CONFIG_KERNEL/d \ + -e /CONFIG_INITRAMFS_SOURCE/d \ + -e /CONFIG_INITRAMFS_COMPRESSION/d \ + -e /CONFIG_RD/d \ + -e /=m/d \ + -e /CONFIG_MODULES/d \ + -e /CONFIG_DEBUG_ERRORS/d \ + -e /CONFIG_DEBUG_BUGVERBOSE/d \ + -e /CONFIG_DEBUG_KERNEL/d \ + ${S}/.config + +# Remove last tag appended by linux.inc (output messes screen) +sed -i -e /CONFIG_CMDLINE/s/quiet/loglevel=3/1 ${S}/.config +sed -i -e /CONFIG_CMDLINE/s/debug/loglevel=3/1 ${S}/.config + +echo 'CONFIG_BLK_DEV_INITRD=y +CONFIG_KEXEC=y +${KERNEL_COMPRESSION} +${INITRAMFS_COMPRESSION} +CONFIG_INITRAMFS_SOURCE="initramfs.cpio.${INITRAMFS_COMPRESSION_SUFFIX}" +${RD_COMPRESSION} +CONFIG_MODULES=n' >> ${S}/.config + + yes '' | oe_runmake oldconfig +} + +do_populate_sysroot() { +} + +do_install() { +} + +python do_package() { +} |