From 97c48dbc6c78c8f4cee9ccd276be6926560bf504 Mon Sep 17 00:00:00 2001 From: Scott Rifenbark Date: Mon, 13 May 2013 09:32:25 +0300 Subject: kernel-dev: Updated changing the configuration section. Robert P. J. Day pointed out some implied meanings in this section that indicate configurations from .config are exclusive somehow from configurations applied through config fragments. That is not the case. I have inserted a note to clear up that implied meaning. Reported-by: Robert P. J. Day (From yocto-docs rev: 5ac27e8a2aea662a8e70dda0e852b5ea401b8b00) Signed-off-by: Scott Rifenbark Signed-off-by: Richard Purdie --- documentation/kernel-dev/kernel-dev-common.xml | 42 +++++++++++++++++--------- 1 file changed, 27 insertions(+), 15 deletions(-) (limited to 'documentation/kernel-dev') diff --git a/documentation/kernel-dev/kernel-dev-common.xml b/documentation/kernel-dev/kernel-dev-common.xml index f0e95aca07..6f39a70dff 100644 --- a/documentation/kernel-dev/kernel-dev-common.xml +++ b/documentation/kernel-dev/kernel-dev-common.xml @@ -148,16 +148,16 @@ You can make wholesale or incremental changes to the Linux kernel .config file by including a - defconfig or by specifying - configuration fragments in the + defconfig and by specifying + configuration fragments in the SRC_URI. - If you have a complete Linux kernel .config - file you want to use, copy it to a directory named - files, which must be in - your layer's recipes-kernel/linux + If you have a final Linux kernel .config + file you want to use, copy it to a directory named + files, which must be in + your layer's recipes-kernel/linux directory, and name the file "defconfig". Then, add the following lines to your linux-yocto .bbappend file in your layer: @@ -165,24 +165,36 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/files:" SRC_URI += "file://defconfig" - The - SRC_URI tells the build system how to - search for the file, while the + The SRC_URI tells the build system how to + search for the file, while the FILESEXTRAPATHS - extends the + extends the FILESPATH - variable (search directories) to include the + variable (search directories) to include the files directory you created for the configuration changes. + + The build system applies the configurations from the + .config file before applying any + subsequent configuration fragments. + The final kernel configuration is a combination of the + configurations in the .config file and + any configuration fragments you provide. + You need to realize that if you have any configuration + fragments, the build system applies these on top of and + after applying the existing .config + file configurations. + + Generally speaking, the preferred approach is to determine the incremental change you want to make and add that as a configuration fragment. For example, if you want to add support for a basic serial - console, create a file named 8250.cfg in the - files directory with the following + console, create a file named 8250.cfg in + the files directory with the following content (without indentation): CONFIG_SERIAL_8250=y @@ -193,8 +205,8 @@ CONFIG_SERIAL_CORE=y CONFIG_SERIAL_CORE_CONSOLE=y - Next, include this configuration fragment and extend the - FILESPATH variable in your + Next, include this configuration fragment and extend the + FILESPATH variable in your .bbappend file: FILESEXTRAPATHS_prepend := "${THISDIR}/files:" -- cgit v1.2.3-54-g00ecf