summaryrefslogtreecommitdiffstats
path: root/documentation/kernel-dev/kernel-dev-advanced.xml
diff options
context:
space:
mode:
authorScott Rifenbark <scott.m.rifenbark@intel.com>2015-03-02 14:59:09 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-03-06 10:44:34 +0000
commite7e533028bea299ca85b4fc503ccca61c35ae60c (patch)
tree11e0e8ac9efe27604a25fc417935f61f8a24ea62 /documentation/kernel-dev/kernel-dev-advanced.xml
parent043e02c5d89b60432d8c790779b6f9493a205985 (diff)
downloadpoky-e7e533028bea299ca85b4fc503ccca61c35ae60c.tar.gz
kernel-dev: Scrubbed out the 3.4 kernel references.
This kernel is not supported and is ancient. Many of the examples were referencing this kernel. I switched to use the 3.19 version. Reported-by: Robert P. J. Day <rpjday@crashcourse.ca> (From yocto-docs rev: ba04c4f11a02b4562994d5d79838cd2cf90efc7e) Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation/kernel-dev/kernel-dev-advanced.xml')
-rw-r--r--documentation/kernel-dev/kernel-dev-advanced.xml128
1 files changed, 67 insertions, 61 deletions
diff --git a/documentation/kernel-dev/kernel-dev-advanced.xml b/documentation/kernel-dev/kernel-dev-advanced.xml
index 9b35a422db..c3bda983b2 100644
--- a/documentation/kernel-dev/kernel-dev-advanced.xml
+++ b/documentation/kernel-dev/kernel-dev-advanced.xml
@@ -145,9 +145,9 @@
145 </literallayout> 145 </literallayout>
146 The value of the entries in <filename>KERNEL_FEATURES</filename> 146 The value of the entries in <filename>KERNEL_FEATURES</filename>
147 are dependent on their location within the kernel Metadata itself. 147 are dependent on their location within the kernel Metadata itself.
148 The examples here are taken from the 148 The examples here are taken from the <filename>meta</filename>
149 <filename>linux-yocto-3.4</filename> repository where "features" 149 branch of the <filename>linux-yocto-3.19</filename> repository.
150 and "cfg" are subdirectories within the 150 Within that branch, "features" and "cfg" are subdirectories of the
151 <filename>meta/cfg/kernel-cache</filename> directory. 151 <filename>meta/cfg/kernel-cache</filename> directory.
152 For more information, see the 152 For more information, see the
153 "<link linkend='kernel-metadata-syntax'>Kernel Metadata Syntax</link>" section. 153 "<link linkend='kernel-metadata-syntax'>Kernel Metadata Syntax</link>" section.
@@ -442,22 +442,27 @@
442 feature. 442 feature.
443 This feature consists of one or more Linux kernel configuration 443 This feature consists of one or more Linux kernel configuration
444 parameters in a configuration fragment file 444 parameters in a configuration fragment file
445 (<filename>.cfg</filename>) and an <filename>.scc</filename> file 445 (<filename>.cfg</filename>) and a <filename>.scc</filename> file
446 that describes the fragment. 446 that describes the fragment.
447 </para> 447 </para>
448 448
449 <para> 449 <para>
450 The Symmetric Multi-Processing (SMP) fragment included in the 450 The Symmetric Multi-Processing (SMP) fragment included in the
451 <filename>linux-yocto-3.4</filename> Git repository 451 <filename>linux-yocto-3.19</filename> Git repository
452 consists of the following two files: 452 consists of the following two files:
453 <literallayout class='monospaced'> 453 <literallayout class='monospaced'>
454 cfg/smp.scc: 454 cfg/smp.scc:
455 define KFEATURE_DESCRIPTION "Enable SMP" 455 define KFEATURE_DESCRIPTION "Enable SMP"
456 define KFEATURE_COMPATIBILITY all
457
456 kconf hardware smp.cfg 458 kconf hardware smp.cfg
457 459
458 cfg/smp.cfg: 460 cfg/smp.cfg:
459 CONFIG_SMP=y 461 CONFIG_SMP=y
460 CONFIG_SCHED_SMT=y 462 CONFIG_SCHED_SMT=y
463 # Increase default NR_CPUS from 8 to 64 so that platform with
464 # more than 8 processors can be all activated at boot time
465 CONFIG_NR_CPUS=64
461 </literallayout> 466 </literallayout>
462 You can find information on configuration fragment files in the 467 You can find information on configuration fragment files in the
463 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-config-fragments'>Creating Configuration Fragments</ulink>" 468 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-config-fragments'>Creating Configuration Fragments</ulink>"
@@ -584,7 +589,7 @@
584 </para> 589 </para>
585 590
586 <para> 591 <para>
587 As an example, the <filename>linux-yocto-3.4</filename> 592 As an example, the <filename>linux-yocto-3.19</filename>
588 tree defines three kernel types: "standard", 593 tree defines three kernel types: "standard",
589 "tiny", and "preempt-rt": 594 "tiny", and "preempt-rt":
590 <itemizedlist> 595 <itemizedlist>
@@ -671,15 +676,15 @@
671 The hardware-specific portion is typically defined 676 The hardware-specific portion is typically defined
672 independently, and then aggregated with each supported kernel 677 independently, and then aggregated with each supported kernel
673 type. 678 type.
674 Consider this simple BSP description that supports the "mybsp" 679 Consider this simple BSP description that supports the
675 machine: 680 <replaceable>mybsp</replaceable> machine:
676 <literallayout class='monospaced'> 681 <literallayout class='monospaced'>
677 mybsp.scc: 682 <replaceable>mybsp</replaceable>.scc:
678 define KMACHINE mybsp 683 define KMACHINE <replaceable>mybsp</replaceable>
679 define KTYPE standard 684 define KTYPE standard
680 define KARCH i386 685 define KARCH i386
681 686
682 kconf mybsp.cfg 687 kconf <replaceable>mybsp</replaceable>.cfg
683 </literallayout> 688 </literallayout>
684 Every BSP description should define the 689 Every BSP description should define the
685 <ulink url='&YOCTO_DOCS_REF_URL;#var-KMACHINE'><filename>KMACHINE</filename></ulink>, 690 <ulink url='&YOCTO_DOCS_REF_URL;#var-KMACHINE'><filename>KMACHINE</filename></ulink>,
@@ -724,13 +729,13 @@
724 a single <filename>.cfg</filename> file. 729 a single <filename>.cfg</filename> file.
725 Consider the following: 730 Consider the following:
726 <literallayout class='monospaced'> 731 <literallayout class='monospaced'>
727 mybsp.scc: 732 <replaceable>mybsp</replaceable>.scc:
728 define KMACHINE mybsp 733 define KMACHINE mybsp
729 define KTYPE standard 734 define KTYPE standard
730 define KARCH i386 735 define KARCH i386
731 736
732 include standard.scc 737 include standard.scc
733 include mybsp-hw.scc 738 include <replaceable>mybsp</replaceable>-hw.scc
734 </literallayout> 739 </literallayout>
735 </para> 740 </para>
736 741
@@ -738,8 +743,10 @@
738 In the above example, <filename>standard.scc</filename> 743 In the above example, <filename>standard.scc</filename>
739 aggregates all the configuration fragments, patches, and 744 aggregates all the configuration fragments, patches, and
740 features that make up your standard kernel policy whereas 745 features that make up your standard kernel policy whereas
741 <filename>mybsp-hw.scc</filename> aggregates all those necessary 746 <replaceable>mybsp</replaceable><filename>-hw.scc</filename>
742 to support the hardware available on the "mybsp" machine. 747 aggregates all those necessary
748 to support the hardware available on the
749 <replaceable>mybsp</replaceable> machine.
743 For information on how to break a complete 750 For information on how to break a complete
744 <filename>.config</filename> file into the various 751 <filename>.config</filename> file into the various
745 configuration fragments, see the 752 configuration fragments, see the
@@ -751,99 +758,98 @@
751 Many real-world examples are more complex. 758 Many real-world examples are more complex.
752 Like any other <filename>.scc</filename> file, BSP 759 Like any other <filename>.scc</filename> file, BSP
753 descriptions can aggregate features. 760 descriptions can aggregate features.
754 Consider the Fish River Island 2 (fri2) 761 Consider the Minnow BSP definition from the
755 BSP definition from the <filename>linux-yocto-3.4</filename> 762 <filename>linux-yocto-3.19</filename>
756 Git repository: 763 Git repository:
757 <literallayout class='monospaced'> 764 <literallayout class='monospaced'>
758 fri2.scc: 765 minnow.scc:
759 kconf hardware fri2.cfg
760
761 include cfg/x86.scc 766 include cfg/x86.scc
762 include features/eg20t/eg20t.scc 767 include features/eg20t/eg20t.scc
763 include cfg/dmaengine.scc 768 include cfg/dmaengine.scc
764 include features/ericsson-3g/f5521gw.scc
765 include features/power/intel.scc 769 include features/power/intel.scc
766 include cfg/efi.scc 770 include cfg/efi.scc
767 include features/usb/ehci-hcd.scc 771 include features/usb/ehci-hcd.scc
768 include features/usb/ohci-hcd.scc 772 include features/usb/ohci-hcd.scc
769 include features/iwlwifi/iwlwifi.scc 773 include features/usb/usb-gadgets.scc
774 include features/usb/touchscreen-composite.scc
775 include cfg/timer/hpet.scc
776 include cfg/timer/rtc.scc
777 include features/leds/leds.scc
778 include features/spi/spidev.scc
779 include features/i2c/i2cdev.scc
780
781 # Earlyprintk and port debug requires 8250
782 kconf hardware cfg/8250.cfg
783
784 kconf hardware minnow.cfg
785 kconf hardware minnow-dev.cfg
770 </literallayout> 786 </literallayout>
771 </para> 787 </para>
772 788
773 <para> 789 <para>
774 The <filename>fri2.scc</filename> description file includes 790 The <filename>minnow.scc</filename> description file includes
775 a hardware configuration fragment 791 a hardware configuration fragment
776 (<filename>fri2.cfg</filename>) specific to the Fish River 792 (<filename>minnow.cfg</filename>) specific to the Minnow
777 Island 2 BSP as well as several more general configuration 793 BSP as well as several more general configuration
778 fragments and features enabling hardware found on the 794 fragments and features enabling hardware found on the
779 machine. 795 machine.
780 This description file is then included in each of the three 796 This description file is then included in each of the three
781 "fri2" description files for the supported kernel types 797 "minnow" description files for the supported kernel types
782 (i.e. "standard", "preempt-rt", and "tiny"). 798 (i.e. "standard", "preempt-rt", and "tiny").
783 Consider the "fri2" description for the "standard" kernel 799 Consider the "minnow" description for the "standard" kernel
784 type: 800 type:
785 <literallayout class='monospaced'> 801 <literallayout class='monospaced'>
786 fri2-standard.scc: 802 minnow-standard.scc:
787 define KMACHINE fri2 803 define KMACHINE minnow
788 define KTYPE standard 804 define KTYPE standard
789 define KARCH i386 805 define KARCH i386
790 806
791 include ktypes/standard/standard.scc 807 include ktypes/standard
792 branch fri2
793
794 git merge emgd-1.14
795 808
796 include fri2.scc 809 include minnow.scc
797 810
798 # Extra fri2 configs above the minimal defined in fri2.scc 811 # Extra minnow configs above the minimal defined in minnow.scc
799 include cfg/efi-ext.scc 812 include cfg/efi-ext.scc
800 include features/drm-emgd/drm-emgd.scc 813 include features/media/media-all.scc
801 include cfg/vesafb.scc 814 include features/sound/snd_hda_intel.scc
802 815
803 # default policy for standard kernels 816 # The following should really be in standard.scc
817 # USB live-image support
804 include cfg/usb-mass-storage.scc 818 include cfg/usb-mass-storage.scc
819 include cfg/boot-live.scc
820
821 # Basic profiling
822 include features/latencytop/latencytop.scc
823 include features/profiling/profiling.scc
824
825 # Requested drivers that don't have an existing scc
826 kconf hardware minnow-drivers-extra.cfg
805 </literallayout> 827 </literallayout>
806 The <filename>include</filename> command midway through the file 828 The <filename>include</filename> command midway through the file
807 includes the <filename>fri2.scc</filename> description that 829 includes the <filename>minnow.scc</filename> description that
808 defines all hardware enablements for the BSP that is common to all 830 defines all hardware enablements for the BSP that is common to all
809 kernel types. 831 kernel types.
810 Using this command significantly reduces duplication. 832 Using this command significantly reduces duplication.
811 </para> 833 </para>
812 834
813 <para> 835 <para>
814 This "fri2" standard description introduces a few more variables 836 Now consider the "minnow" description for the "tiny" kernel type:
815 and commands that are worth further discussion.
816 Notice the <filename>branch fri2</filename> command, which creates
817 a machine-specific branch into which source changes are applied.
818 With this branch set up, the <filename>git merge</filename> command
819 uses Git to merge in a feature branch named "emgd-1.14".
820 You could also handle this with the <filename>patch</filename>
821 command.
822 However, for commonly used features such as this, feature branches
823 are a convenient mechanism.
824 See the "<link linkend='feature-branches'>Feature Branches</link>"
825 section for more information.
826 </para>
827
828 <para>
829 Now consider the "fri2" description for the "tiny" kernel type:
830 <literallayout class='monospaced'> 837 <literallayout class='monospaced'>
831 fri2-tiny.scc: 838 minnow-tiny.scc:
832 define KMACHINE fri2 839 define KMACHINE minnow
833 define KTYPE tiny 840 define KTYPE tiny
834 define KARCH i386 841 define KARCH i386
835 842
836 include ktypes/tiny/tiny.scc 843 include ktypes/tiny
837 branch fri2
838 844
839 include fri2.scc 845 include minnow.scc
840 </literallayout> 846 </literallayout>
841 As you might expect, the "tiny" description includes quite a 847 As you might expect, the "tiny" description includes quite a
842 bit less. 848 bit less.
843 In fact, it includes only the minimal policy defined by the 849 In fact, it includes only the minimal policy defined by the
844 "tiny" kernel type and the hardware-specific configuration required 850 "tiny" kernel type and the hardware-specific configuration required
845 for booting the machine along with the most basic functionality of 851 for booting the machine along with the most basic functionality of
846 the system as defined in the base "fri2" description file. 852 the system as defined in the base "minnow" description file.
847 </para> 853 </para>
848 854
849 <para> 855 <para>