Patchwork [meta-handheld,v2] linux-kexecboot: use kernel_conf_variable like linux.inc does and respect CMDLINE_DEBUG

login
register
mail settings
Submitter Martin Jansa
Date Nov. 20, 2011, 11:26 a.m.
Message ID <1321788386-31278-1-git-send-email-Martin.Jansa@gmail.com>
Download mbox | patch
Permalink /patch/15153/
State Accepted
Headers show

Comments

Martin Jansa - Nov. 20, 2011, 11:26 a.m.
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
 recipes-kernel/linux/linux-kexecboot.inc |  104 ++++++++++++++---------------
 1 files changed, 50 insertions(+), 54 deletions(-)
Andrea Adami - Nov. 21, 2011, 10:43 a.m.
On Sun, Nov 20, 2011 at 12:26 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
> ---
>  recipes-kernel/linux/linux-kexecboot.inc |  104 ++++++++++++++---------------
>  1 files changed, 50 insertions(+), 54 deletions(-)
>
> diff --git a/recipes-kernel/linux/linux-kexecboot.inc b/recipes-kernel/linux/linux-kexecboot.inc
> index ea0bbd6..c7b29f3 100644
> --- a/recipes-kernel/linux/linux-kexecboot.inc
> +++ b/recipes-kernel/linux/linux-kexecboot.inc
> @@ -11,7 +11,6 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
>  # only as fallback for patches available only in linux-PV dir and ie defconfigs needs to go from linux-kexecboot-PV
>  FILESPATH_append = ":${FILE_DIRNAME}/linux-${PV}"
>
> -
>  DEPENDS += "xz-native"
>
>  # Kernel bootlogo is distro-specific (default is OE logo).
> @@ -19,13 +18,17 @@ DEPENDS += "xz-native"
>  LOGO_SIZE ?= "."
>  SRC_URI = "file://${LOGO_SIZE}/logo_linux_clut224.ppm.bz2"
>
> +# Set the verbosity of kernel messages during runtime
> +# You can define CMDLINE_DEBUG in your local.conf or distro.conf to override this behaviour
> +CMDLINE_DEBUG ?= '${@base_contains("IMAGE_FEATURES", "debug-tweaks", "debug", "loglevel=3", d)}'
> +
>  # Note how we set loglevel=3 and master console on serial to protect bootlogo.
> -CMDLINE_c7x0 = "console=tty1 console=ttyS0,115200n8 loglevel=3"
> -CMDLINE_tosa = "console=tty1 console=ttyS0,115200n8 loglevel=3"
> -CMDLINE_poodle = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
> -CMDLINE_akita = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
> -CMDLINE_collie = "console=tty1 console=ttySA0,115200n8 fbcon=rotate:1 mem=64M loglevel=3"
> -CMDLINE_spitz = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
> +CMDLINE_c7x0 = "console=tty1 console=ttyS0,115200n8"
> +CMDLINE_tosa = "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"
>
>  PACKAGES = ""
>  PROVIDES = ""
> @@ -46,28 +49,39 @@ LOCALVERSION ?= ""
>  # we want the smallest size
>  INITRAMFS_IMAGE = "initramfs-kexecboot-klibc-image"
>
> +kernel_conf_variable() {
> +        CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_$1[ =]/d;"
> +        if test "$2" = "n"
> +        then
> +                echo "# CONFIG_$1 is not set" >> ${S}/.config
> +        else
> +                echo "CONFIG_$1=$2" >> ${S}/.config
> +        fi
> +}
> +
>  do_configure_prepend() {
>
>         echo "" > ${S}/.config
> +        CONF_SED_SCRIPT=""
>
>         #
>         # CONFIG_CMDLINE mangling
>         #
> -        echo "CONFIG_CMDLINE_BOOL=y" >> ${S}/.config
> -        echo "CONFIG_CMDLINE=\"${CMDLINE}\"" >> ${S}/.config
> +        kernel_conf_variable CMDLINE_BOOL y
> +        kernel_conf_variable CMDLINE "\"${CMDLINE} ${CMDLINE_DEBUG}\""
>
>         # mips and x86
> -        echo "CONFIG_CMDLINE_OVERRIDE=y" >> ${S}/.config
> +        kernel_conf_variable CMDLINE_OVERRIDE y
>
>         # sh only
> -        echo "CONFIG_CMDLINE_OVERWRITE=y" >> ${S}/.config
> -        echo "# CONFIG_CMDLINE_EXTEND is not set" >> ${S}/.config
> +        kernel_conf_variable CMDLINE_OVERWRITE y
> +        kernel_conf_variable CMDLINE_EXTEND n
>
>         #
>         # endian support
>         #
>         if [ "${SITEINFO_ENDIANNESS}" = "be" ]; then
> -                echo "CONFIG_CPU_BIG_ENDIAN=y"          >> ${S}/.config
> +                kernel_conf_variable CPU_BIG_ENDIAN y
>         fi
>
>         #
> @@ -75,60 +89,42 @@ do_configure_prepend() {
>         #
>         if [ -e ${WORKDIR}/logo_linux_clut224.ppm ]; then
>                 install -m 0644 ${WORKDIR}/logo_linux_clut224.ppm drivers/video/logo/logo_linux_clut224.ppm
> -                echo "CONFIG_LOGO=y"                    >> ${S}/.config
> -                echo "CONFIG_LOGO_LINUX_CLUT224=y"      >> ${S}/.config
> +                kernel_conf_variable LOGO y
> +                kernel_conf_variable LOGO_LINUX_CLUT224 y
>         fi
>
>         # When enabling thumb for userspace we also need thumb support in the kernel
>         if [ "${ARM_INSTRUCTION_SET}" = "thumb" ] ; then
> -            sed -i -e /CONFIG_ARM_THUMB/d ${WORKDIR}/defconfig
> -            echo "CONFIG_ARM_THUMB=y" >> ${S}/.config
> +                kernel_conf_variable ARM_THUMB y
>         fi
>
> -        sed -e '/CONFIG_CMDLINE=/d' \
> -            -e '/CONFIG_CMDLINE_BOOL/d' \
> -            -e '/CONFIG_CMDLINE_OVERRIDE/d' \
> -            -e '/CONFIG_CMDLINE_OVERWRITE/d' \
> -            -e '/CONFIG_CMDLINE_EXTEND/d' \
> -            -e '/CONFIG_CPU_BIG_ENDIAN/d' \
> -            -e '/CONFIG_LOGO=/d' \
> -            -e '/CONFIG_LOGO_LINUX_CLUT224=/d' \
> -            -e '/CONFIG_LOCALVERSION/d' \
> -            -e '/CONFIG_LOCALVERSION_AUTO/d' \
> -            < '${WORKDIR}/defconfig' >>'${S}/.config'
> -
> -        echo 'CONFIG_LOCALVERSION="${LOCALVERSION}"' >>${S}/.config
> -        echo '# CONFIG_LOCALVERSION_AUTO is not set' >>${S}/.config
> +        kernel_conf_variable LOCALVERSION "\"${LOCALVERSION}\""
> +        kernel_conf_variable LOCALVERSION_AUTO n
>
>         # Force sane defaults for kexec-enabled kernels and keep size small
> -        sed -i -e /CONFIG_BLK_DEV_INITRD/d \
> -               -e /CONFIG_KEXEC/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
> -
> -               echo 'CONFIG_BLK_DEV_INITRD=y' >>${S}/.config
> -               echo 'CONFIG_KEXEC=y' >>${S}/.config
> -               echo '# CONFIG_MODULES is not set' >> ${S}/.config
> +        kernel_conf_variable BLK_DEV_INITRD y
> +        kernel_conf_variable KEXEC y
> +        CONF_SED_SCRIPT="$CONF_SED_SCRIPT /=m/d;"
> +        kernel_conf_variable MODULES n
> +        kernel_conf_variable DEBUG_ERRORS n
> +        kernel_conf_variable DEBUG_BUGVERBOSE n
> +        kernel_conf_variable DEBUG_KERNEL n
>
>         # Force lzma for arm kernels only
>         if [ "${ARCH}" = "arm" ] ; then
> -
> -            sed -i -e /CONFIG_KERNEL/d \
> -               -e /CONFIG_INITRAMFS_COMPRESSION/d \
> -               -e /CONFIG_INITRAMFS_SOURCE/d \
> -               -e /CONFIG_RD/d \
> -               ${S}/.config
> -
> -               echo 'CONFIG_KERNEL_LZMA=y' >>${S}/.config
> -               echo 'CONFIG_INITRAMFS_COMPRESSION_LZMA=y' >>${S}/.config
> -               echo 'CONFIG_INITRAMFS_SOURCE="initramfs.cpio.lzma"' >>${S}/.config
> -               echo 'CONFIG_RD_LZMA=y' >>${S}/.config
> +                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_KERNEL/d;"
> +                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_RD/d;"
> +                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_INITRAMFS_COMPRESSION/d;"
> +                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_INITRAMFS_SOURCE/d;"
> +                kernel_conf_variable KERNEL_LZMA y
> +                kernel_conf_variable RD_LZMA y
> +                kernel_conf_variable INITRAMFS_COMPRESSION_LZMA y
> +                kernel_conf_variable INITRAMFS_SOURCE "\"initramfs.cpio.lzma\""
>         fi
>
> +        sed -e "${CONF_SED_SCRIPT}" \
> +                        < '${WORKDIR}/defconfig' >>'${S}/.config'
> +
>         yes '' | oe_runmake oldconfig
>  }
>
> --
> 1.7.8.rc3
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>

Martin,

I agree for the use kernel_conf_variable but I'm unsure about CMDLINE_DEBUG.
In fact, I hardcoded it purposedly with commit 8929166 with the
following reasons:

* Being a second-stage bootloader we don't expect any output on screen.
* Adding 'debug' as commandline arg is pointless because
* linux-kexecboot is compiled without debug and printk in order
* to minimize the size.
* Full debug implies not only editing the commandline (e.g. earlyprintk)
* but re-enabling full debug options in the defconfigs

Regards

Andrea
Martin Jansa - Nov. 21, 2011, 11:52 a.m.
On Mon, Nov 21, 2011 at 11:43:46AM +0100, Andrea Adami wrote:
> On Sun, Nov 20, 2011 at 12:26 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
> Martin,
> 
> I agree for the use kernel_conf_variable but I'm unsure about CMDLINE_DEBUG.
> In fact, I hardcoded it purposedly with commit 8929166 with the
> following reasons:
> 
> * Being a second-stage bootloader we don't expect any output on screen.
> * Adding 'debug' as commandline arg is pointless because
> * linux-kexecboot is compiled without debug and printk in order
> * to minimize the size.
> * Full debug implies not only editing the commandline (e.g. earlyprintk)
> * but re-enabling full debug options in the defconfigs

I had some issues with 3.2.0-rc2 when used as linux-kexecboot, that's
why I've added this, but later found out that it's really a bit
incomplete, that's why I have followup patch for this:
https://gitorious.org/shr/meta-handheld/commit/6bc710615b587fc0bfd8fc4372cad0de5599dd82?format=patch

But with latest SRCREV it works again, so in theory I don't need it, but
still it would be usefull to have easy way to debug even this stage
(maybe you still remember older kernel version where it worked fine 
as 3rd stage and failed to boot as 2nd stage..).

BTW: here is upgrade to 3.2.0-rc2 with those changes to
linux-kexecboot.inc applied
https://gitorious.org/shr/meta-handheld/commit/27ca3d24353a5473f4f1aade00ba7a52b667e28c?format=patch

(be aware that I do rebase that branch sometimes so if those commits are
not valid anymore just look at last few commits in that branch).

Regards,
Paul Eggleton - Nov. 25, 2011, 12:34 p.m.
On Monday 21 November 2011 12:52:13 Martin Jansa wrote:
> On Mon, Nov 21, 2011 at 11:43:46AM +0100, Andrea Adami wrote:
> > On Sun, Nov 20, 2011 at 12:26 PM, Martin Jansa <martin.jansa@gmail.com>
> > wrote: Martin,
> > 
> > I agree for the use kernel_conf_variable but I'm unsure about
> > CMDLINE_DEBUG. In fact, I hardcoded it purposedly with commit 8929166
> > with the
> > following reasons:
> > 
> > * Being a second-stage bootloader we don't expect any output on screen.
> > * Adding 'debug' as commandline arg is pointless because
> > * linux-kexecboot is compiled without debug and printk in order
> > * to minimize the size.
> > * Full debug implies not only editing the commandline (e.g. earlyprintk)
> > * but re-enabling full debug options in the defconfigs
> 
> I had some issues with 3.2.0-rc2 when used as linux-kexecboot, that's
> why I've added this, but later found out that it's really a bit
> incomplete, that's why I have followup patch for this:
> https://gitorious.org/shr/meta-handheld/commit/6bc710615b587fc0bfd8fc4372cad
> 0de5599dd82?format=patch
> 
> But with latest SRCREV it works again, so in theory I don't need it, but
> still it would be usefull to have easy way to debug even this stage
> (maybe you still remember older kernel version where it worked fine
> as 3rd stage and failed to boot as 2nd stage..).
> 
> BTW: here is upgrade to 3.2.0-rc2 with those changes to
> linux-kexecboot.inc applied
> https://gitorious.org/shr/meta-handheld/commit/27ca3d24353a5473f4f1aade00ba7
> a52b667e28c?format=patch
> 
> (be aware that I do rebase that branch sometimes so if those commits are
> not valid anymore just look at last few commits in that branch).

As discussed on IRC I've merged the latest version of this branch to meta-
handheld master now, thanks.

Cheers,
Paul

Patch

diff --git a/recipes-kernel/linux/linux-kexecboot.inc b/recipes-kernel/linux/linux-kexecboot.inc
index ea0bbd6..c7b29f3 100644
--- a/recipes-kernel/linux/linux-kexecboot.inc
+++ b/recipes-kernel/linux/linux-kexecboot.inc
@@ -11,7 +11,6 @@  LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
 # only as fallback for patches available only in linux-PV dir and ie defconfigs needs to go from linux-kexecboot-PV
 FILESPATH_append = ":${FILE_DIRNAME}/linux-${PV}"
 
-
 DEPENDS += "xz-native"
 
 # Kernel bootlogo is distro-specific (default is OE logo).
@@ -19,13 +18,17 @@  DEPENDS += "xz-native"
 LOGO_SIZE ?= "."
 SRC_URI = "file://${LOGO_SIZE}/logo_linux_clut224.ppm.bz2"
 
+# Set the verbosity of kernel messages during runtime
+# You can define CMDLINE_DEBUG in your local.conf or distro.conf to override this behaviour
+CMDLINE_DEBUG ?= '${@base_contains("IMAGE_FEATURES", "debug-tweaks", "debug", "loglevel=3", d)}'
+
 # Note how we set loglevel=3 and master console on serial to protect bootlogo.
-CMDLINE_c7x0 = "console=tty1 console=ttyS0,115200n8 loglevel=3"
-CMDLINE_tosa = "console=tty1 console=ttyS0,115200n8 loglevel=3"
-CMDLINE_poodle = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
-CMDLINE_akita = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
-CMDLINE_collie = "console=tty1 console=ttySA0,115200n8 fbcon=rotate:1 mem=64M loglevel=3"
-CMDLINE_spitz = "console=tty1 console=ttyS0,115200n8 fbcon=rotate:1 loglevel=3"
+CMDLINE_c7x0 = "console=tty1 console=ttyS0,115200n8"
+CMDLINE_tosa = "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"
 
 PACKAGES = ""
 PROVIDES = ""
@@ -46,28 +49,39 @@  LOCALVERSION ?= ""
 # we want the smallest size
 INITRAMFS_IMAGE = "initramfs-kexecboot-klibc-image"
 
+kernel_conf_variable() {
+        CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_$1[ =]/d;"
+        if test "$2" = "n"
+        then
+                echo "# CONFIG_$1 is not set" >> ${S}/.config
+        else
+                echo "CONFIG_$1=$2" >> ${S}/.config
+        fi
+}
+
 do_configure_prepend() {
 
         echo "" > ${S}/.config
+        CONF_SED_SCRIPT=""
 
         #
         # CONFIG_CMDLINE mangling
         #
-        echo "CONFIG_CMDLINE_BOOL=y" >> ${S}/.config
-        echo "CONFIG_CMDLINE=\"${CMDLINE}\"" >> ${S}/.config
+        kernel_conf_variable CMDLINE_BOOL y
+        kernel_conf_variable CMDLINE "\"${CMDLINE} ${CMDLINE_DEBUG}\""
 
         # mips and x86
-        echo "CONFIG_CMDLINE_OVERRIDE=y" >> ${S}/.config
+        kernel_conf_variable CMDLINE_OVERRIDE y
 
         # sh only
-        echo "CONFIG_CMDLINE_OVERWRITE=y" >> ${S}/.config
-        echo "# CONFIG_CMDLINE_EXTEND is not set" >> ${S}/.config
+        kernel_conf_variable CMDLINE_OVERWRITE y
+        kernel_conf_variable CMDLINE_EXTEND n
 
         #
         # endian support
         #
         if [ "${SITEINFO_ENDIANNESS}" = "be" ]; then
-                echo "CONFIG_CPU_BIG_ENDIAN=y"          >> ${S}/.config
+                kernel_conf_variable CPU_BIG_ENDIAN y
         fi
 
         #
@@ -75,60 +89,42 @@  do_configure_prepend() {
         #
         if [ -e ${WORKDIR}/logo_linux_clut224.ppm ]; then
                 install -m 0644 ${WORKDIR}/logo_linux_clut224.ppm drivers/video/logo/logo_linux_clut224.ppm
-                echo "CONFIG_LOGO=y"                    >> ${S}/.config
-                echo "CONFIG_LOGO_LINUX_CLUT224=y"      >> ${S}/.config
+                kernel_conf_variable LOGO y
+                kernel_conf_variable LOGO_LINUX_CLUT224 y
         fi
 
         # When enabling thumb for userspace we also need thumb support in the kernel
         if [ "${ARM_INSTRUCTION_SET}" = "thumb" ] ; then
-            sed -i -e /CONFIG_ARM_THUMB/d ${WORKDIR}/defconfig 
-            echo "CONFIG_ARM_THUMB=y" >> ${S}/.config
+                kernel_conf_variable ARM_THUMB y
         fi
 
-        sed -e '/CONFIG_CMDLINE=/d' \
-            -e '/CONFIG_CMDLINE_BOOL/d' \
-            -e '/CONFIG_CMDLINE_OVERRIDE/d' \
-            -e '/CONFIG_CMDLINE_OVERWRITE/d' \
-            -e '/CONFIG_CMDLINE_EXTEND/d' \
-            -e '/CONFIG_CPU_BIG_ENDIAN/d' \
-            -e '/CONFIG_LOGO=/d' \
-            -e '/CONFIG_LOGO_LINUX_CLUT224=/d' \
-            -e '/CONFIG_LOCALVERSION/d' \
-            -e '/CONFIG_LOCALVERSION_AUTO/d' \
-            < '${WORKDIR}/defconfig' >>'${S}/.config'
-
-        echo 'CONFIG_LOCALVERSION="${LOCALVERSION}"' >>${S}/.config
-        echo '# CONFIG_LOCALVERSION_AUTO is not set' >>${S}/.config
+        kernel_conf_variable LOCALVERSION "\"${LOCALVERSION}\""
+        kernel_conf_variable LOCALVERSION_AUTO n
 
         # Force sane defaults for kexec-enabled kernels and keep size small
-        sed -i -e /CONFIG_BLK_DEV_INITRD/d \
-               -e /CONFIG_KEXEC/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
-
-               echo 'CONFIG_BLK_DEV_INITRD=y' >>${S}/.config
-               echo 'CONFIG_KEXEC=y' >>${S}/.config
-               echo '# CONFIG_MODULES is not set' >> ${S}/.config
+        kernel_conf_variable BLK_DEV_INITRD y
+        kernel_conf_variable KEXEC y
+        CONF_SED_SCRIPT="$CONF_SED_SCRIPT /=m/d;"
+        kernel_conf_variable MODULES n
+        kernel_conf_variable DEBUG_ERRORS n
+        kernel_conf_variable DEBUG_BUGVERBOSE n
+        kernel_conf_variable DEBUG_KERNEL n
 
         # Force lzma for arm kernels only
         if [ "${ARCH}" = "arm" ] ; then
-
-            sed -i -e /CONFIG_KERNEL/d \
-               -e /CONFIG_INITRAMFS_COMPRESSION/d \
-               -e /CONFIG_INITRAMFS_SOURCE/d \
-               -e /CONFIG_RD/d \
-               ${S}/.config
-
-               echo 'CONFIG_KERNEL_LZMA=y' >>${S}/.config
-               echo 'CONFIG_INITRAMFS_COMPRESSION_LZMA=y' >>${S}/.config
-               echo 'CONFIG_INITRAMFS_SOURCE="initramfs.cpio.lzma"' >>${S}/.config
-               echo 'CONFIG_RD_LZMA=y' >>${S}/.config
+                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_KERNEL/d;"
+                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_RD/d;"
+                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_INITRAMFS_COMPRESSION/d;"
+                CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_INITRAMFS_SOURCE/d;"
+                kernel_conf_variable KERNEL_LZMA y
+                kernel_conf_variable RD_LZMA y
+                kernel_conf_variable INITRAMFS_COMPRESSION_LZMA y
+                kernel_conf_variable INITRAMFS_SOURCE "\"initramfs.cpio.lzma\""
         fi
 
+        sed -e "${CONF_SED_SCRIPT}" \
+                        < '${WORKDIR}/defconfig' >>'${S}/.config'
+
         yes '' | oe_runmake oldconfig
 }