summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaupin, Chase <chase.maupin@ti.com>2014-05-23 02:08:32 +0000
committerDenys Dmytriyenko <denys@ti.com>2014-05-23 15:01:21 -0400
commit901b6c2b244ad5dd1c60d3fcbb0631577c051fcd (patch)
tree0704be1e896e6f257ef08bec6bd9bab65c68ed7e
parent803c7f96b710f57935f51c31f4e0a6ede0f69fe5 (diff)
downloadmeta-ti-901b6c2b244ad5dd1c60d3fcbb0631577c051fcd.tar.gz
setup-defconfig: allow use of in-kernel config fragments
* Allow the use of in-kernel config fragments instead of only pulling config fragments from the OE meta data. * The absolute path to the config fragment is used to allow pointing to different fragment locations. * Update the linux-ti-staging_3.12 recipe which uses config fragments to specify the absolute path Signed-off-by: Chase Maupin <Chase.Maupin@ti.com> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
-rw-r--r--recipes-kernel/linux/linux-ti-staging_3.12.bb3
-rw-r--r--recipes-kernel/linux/setup-defconfig.inc24
2 files changed, 25 insertions, 2 deletions
diff --git a/recipes-kernel/linux/linux-ti-staging_3.12.bb b/recipes-kernel/linux/linux-ti-staging_3.12.bb
index dbb49b37..cb289c4e 100644
--- a/recipes-kernel/linux/linux-ti-staging_3.12.bb
+++ b/recipes-kernel/linux/linux-ti-staging_3.12.bb
@@ -46,7 +46,8 @@ PV = "3.12.20"
46MACHINE_KERNEL_PR_append = "a+gitr${SRCPV}" 46MACHINE_KERNEL_PR_append = "a+gitr${SRCPV}"
47PR = "${MACHINE_KERNEL_PR}" 47PR = "${MACHINE_KERNEL_PR}"
48 48
49KERNEL_CONFIG_FRAGMENTS = "baseport.cfg connectivity.cfg ipc.cfg" 49KERNEL_CONFIG_FRAGMENTS = "${WORKDIR}/baseport.cfg ${WORKDIR}/connectivity.cfg \
50 ${WORKDIR}/ipc.cfg"
50 51
51SRC_URI = "git://git.ti.com/ti-linux-kernel/ti-linux-kernel.git;protocol=git;branch=${BRANCH} \ 52SRC_URI = "git://git.ti.com/ti-linux-kernel/ti-linux-kernel.git;protocol=git;branch=${BRANCH} \
52 file://defconfig \ 53 file://defconfig \
diff --git a/recipes-kernel/linux/setup-defconfig.inc b/recipes-kernel/linux/setup-defconfig.inc
index 4277f26e..dbfd0d4a 100644
--- a/recipes-kernel/linux/setup-defconfig.inc
+++ b/recipes-kernel/linux/setup-defconfig.inc
@@ -27,9 +27,31 @@ do_configure() {
27 yes '' | oe_runmake oldconfig 27 yes '' | oe_runmake oldconfig
28 fi 28 fi
29 29
30 # check for fragments 30 # Check for kernel config fragments. The assumption is that the config
31 # fragment will be specified with the absolute path. For example:
32 # * ${WORKDIR}/config1.cfg
33 # * ${S}/config2.cfg
34 # Iterate through the list of configs and make sure that you can find
35 # each one. If not then error out.
36 # NOTE: If you want to override a configuration that is kept in the kernel
37 # with one from the OE meta data then you should make sure that the
38 # OE meta data version (i.e. ${WORKDIR}/config1.cfg) is listed
39 # after the in kernel configuration fragment.
40 # Check if any config fragments are specified.
31 if [ ! -z "${KERNEL_CONFIG_FRAGMENTS}" ] 41 if [ ! -z "${KERNEL_CONFIG_FRAGMENTS}" ]
32 then 42 then
43 for f in ${KERNEL_CONFIG_FRAGMENTS}
44 do
45 # Check if the config fragment was copied into the WORKDIR from
46 # the OE meta data
47 if [ ! -e "$f" ]
48 then
49 echo "Could not find kernel config fragment $f"
50 exit 1
51 fi
52 done
53
54 # Now that all the fragments are located merge them.
33 ( cd ${WORKDIR} && ${S}/scripts/kconfig/merge_config.sh -m -r -O ${S} ${S}/.config ${KERNEL_CONFIG_FRAGMENTS} 1>&2 ) 55 ( cd ${WORKDIR} && ${S}/scripts/kconfig/merge_config.sh -m -r -O ${S} ${S}/.config ${KERNEL_CONFIG_FRAGMENTS} 1>&2 )
34 yes '' | oe_runmake oldconfig 56 yes '' | oe_runmake oldconfig
35 fi 57 fi