kernel-dev: General edits during re-write.

(From yocto-docs rev: 7fc9b1bdeb63c32252a243ab21e31ba25779bb1b)

Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Scott Rifenbark 2013-01-07 09:12:13 -06:00 committed by Richard Purdie
parent 467cb3d32e
commit f9a8256553
1 changed files with 33 additions and 20 deletions

View File

@ -3,9 +3,11 @@
[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] > [<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
<chapter id='kernel-dev-advanced'> <chapter id='kernel-dev-advanced'>
<title>Working with Advanced Metadata</title> <title>Working with Advanced Metadata</title>
<section id='kernel-dev-advanced-overview'>
<title>Overview</title>
<para> <para>
In addition to supporting configuration fragments and patches, the In addition to supporting configuration fragments and patches, the
Yocto Project kernel tools also support rich Yocto Project kernel tools also support rich
@ -60,37 +62,48 @@ together as needed, but maintain them in only one place. Similar logic applies
to source changes. to source changes.
</literallayout> </literallayout>
</para> </para>
</section>
<section id='using-metadata-in-a-recipe'> <section id='using-kernel-metadata-in-a-recipe'>
<title>Using Metadata in a Recipe</title> <title>Using Kernel Metadata in a Recipe</title>
<para> <para>
The metadata provided with any linux-yocto style Linux kernel sources The kernel sources in the Yocto Project contain kernel Metadata, which is
must define a BSP that corresponds to the definition laid out in the located in the <filename>meta</filename> branches of the kernel source
recipe. Git repositories.
A BSP consists of an aggregation of kernel policy and hardware specific This Metadata defines Board Support Packages (BSPs) that
correspond to definitions in linux-yocto recipes for the same BSPs.
A BSP consists of an aggregation of kernel policy and hardware-specific
feature enablement. feature enablement.
This can be influenced from within the recipe. The BSP can be influenced from within the linux-yocto recipe.
<note>
Linux kernel source that contains this Metadata is said to be
"linux-yocto style" kernel source.
A Linux kernel recipe that inherits from the
<filename>linux-yocto.inc</filename> include file is said to be a
"linux-yocto style" recipe.
</note>
</para> </para>
<para> <para>
Every linux-yocto style recipe must define the following variable: Every linux-yocto style recipe must define the
<literallayout class='monospaced'> <ulink url='&YOCTO_DOCS_REF_URL;#var-KMACHINE'><filename>KMACHINE</filename></ulink>
KMACHINE variable.
</literallayout> This variable is typically set to the same value as the
<filename>KMACHINE</filename> is typically set to the same value as <ulink url='&YOCTO_DOCS_REF_URL;#var-MACHINE'><filename>MACHINE</filename></ulink>
used within the recipe-space BSP definition, such as "routerstationpro" variable used by BitBake (e.g. "routerstationpro" or "fri2").
or "fri2".
However, multiple BSPs can reuse the same <filename>KMACHINE</filename> However, multiple BSPs can reuse the same <filename>KMACHINE</filename>
name if they are built using the same BSP description. name if they are built using the same BSP description.
See section 3.3.5 for more information. See the <link linkend='bsp-descriptions'>BSP Descriptions</link> section
for more information.
The <filename>meta-intel</filename> "fri2" and "fri2-noemgd" are good The <filename>meta-intel</filename> "fri2" and "fri2-noemgd" are good
examples of such a situation where each specifies examples of such a situation where each specifies
<filename>KMACHINE</filename> as "fri2". <filename>KMACHINE</filename> as "fri2".
</para> </para>
<para> <para>
They may optionally define the following variables: The linux-yocto style recipes can optionally define the following
variables:
<literallayout class='monospaced'> <literallayout class='monospaced'>
KBRANCH KBRANCH
KERNEL_FEATURES KERNEL_FEATURES
@ -839,7 +852,7 @@ The description file can include multiple patch statements, one per patch.
and patches to be the types of things you will want to specify and patches to be the types of things you will want to specify
in the <filename>KERNEL_FEATURES</filename> variable of the in the <filename>KERNEL_FEATURES</filename> variable of the
Linux kernel recipe. Linux kernel recipe.
See the "<link linkend='using-metadata-in-a-recipe'>Using Metadata in a Recipe</link>" See the "<link linkend='using-kernel-metadata-in-a-recipe'>Using Kernel Metadata in a Recipe</link>"
section earlier in the manual. section earlier in the manual.
</para> </para>
@ -885,7 +898,7 @@ will want to specify in the KERNEL_FEATURES variable of the Linux kernel recipe
as described in the previous section. as described in the previous section.
The <filename>ktype</filename> is selected by the The <filename>ktype</filename> is selected by the
<filename>LINUX_KERNEL_TYPE</filename> variable in the recipe. <filename>LINUX_KERNEL_TYPE</filename> variable in the recipe.
See the "<link linkend='using-metadata-in-a-recipe'>Using Metadata in a Recipe</link>" See the "<link linkend='using-kernel-metadata-in-a-recipe'>Using Kernel Metadata in a Recipe</link>"
section for more information. section for more information.
</para> </para>
@ -1315,7 +1328,7 @@ the KTYPE has changed, now set to "tiny".
<title>Machine Branches</title> <title>Machine Branches</title>
<para> <para>
The "<link linkend='using-metadata-in-a-recipe'>Using Metadata in a Recipe</link>" The "<link linkend='using-kernel-metadata-in-a-recipe'>Using Kernel Metadata in a Recipe</link>"
section introduced the <filename>KBRANCH</filename> variable, which section introduced the <filename>KBRANCH</filename> variable, which
defines the source branch to use from the Linux kernel Git repository defines the source branch to use from the Linux kernel Git repository
you are using. you are using.