Personal tools

Log in

Changes

From IGEP - ISEE Wiki

Jump to: navigation, search

Linux Kernel 4.9.y

94 bytes added, 10:11, 7 May 2018
no edit summary
=<span id="Introduction" class="mw-headline" style="color: #808080;">Introduction</span>=
<span style="color: #808080;">This article is for specific 2.6.37.y Linux kernel branch series. All the steps has been tested with [http://releases.ubuntu.com/12.04/ubuntu-12.04.5-desktop-amd64.iso Ubuntu 12.04 64b] and [http://labs.isee.biz/index.php/How_to_setup_a_cross_compiler#IGEP_OMAP3 IGEP SDK Yocto Toolchain 1.2.2-3].</span>
<span style="color: #808080;">Depending the Kernel configuration used, 2.6.37.y series support the following IGEP OMAP3 Processor Boards:</span>
==<span id="igep00x0_defconfig" class="mw-headline" style="color: #808080;">igep00x0_defconfig</span>==
* <span style="color: #808080;">IGEP v2 '''(WIFI/no WIFI)''' (IGEP0020'''RC''')</span>
* <span style="color: #808080;">IGEP COM MODULE / ELECTRON '''(WIFI/no WIFI)''' (IGEP0030'''RE''')</span>
* <span style="color: #808080;">IGEP COM MODULE / ELECTRON '''(no WIFI)'''</span>
=<span id="Setup_IGEP_SDK_Yocto_Toolchain_1.2.2-3" class="mw-headline">Setup IGEP SDK</span><span id="Setup_IGEP_SDK_Yocto_Toolchain_1.2.2-3" class="mw-headline" style="color: #808080;">Setup IGEP SDK Yocto Toolchain 1.2.2-3</span>===<span id="Install" class="mw-headline" style="color: #808080;">Install</span>==<span style="color: #808080000000;">Download - [http://www.isee.biz/support/downloads/item/igep-sdk-yocto-toolchain-1-2-2-3 isee.biz]</span>
<span style="color: #808080000000;">follow the next steps:</span>
* <span style="color: #808080000000;">Open a terminal</span>* <span style="color: #808080000000;">Located your downloaded file, in my case is inside /home/jdoe/Downloads:</span>
<pre><span style="color: #808080000000;">jdoe@ubuntu ~ $ cd Downloads/</span></pre>* <span style="color: #808080000000;">Extract binaries in root directory with root privileges</span>
<pre><span style="color: #808080000000;">jdoe@ubuntu ~/Downloads $ sudo tar jxf igep-sdk-yocto-toolchain-*.tar.bz2 -C /</span></pre>* <span style="color: #808080000000;">Make sure that binaries are installed correctly.</span>
<pre><span style="color: #808080;"><span style="color: #000000;">jdoe@ubuntu ~/Downloads $ ls /opt/poky/1.2 1.2.1 </span> </span></pre>==<span id="Configure" class="mw-headline" style="color: #808080000000;">Configure</span>==<span style="color: #808080000000;">Open a terminal and type:</span>
<pre><span style="color: #808080000000;"> export PATH=/opt/poky/1.2/sysroots/i686-pokysdk-linux/usr/bin/armv7a-vfp-neon-poky-linux-gnueabi:$PATH </span></pre>=<span id="Compiled_binaries" class="mw-headline" style="color: #808080000000;">Compiled binaries</span>=
<span class="mw-headline" style="color: #808080;">Binaries: latest stable kernel version IGEP OMAP3 devices is: '''2.6.37-12 (20161206)'''</span>
||<span style="color: #808080;">[http://downloads.isee.biz/pub/releases/linux_kernel/v2.6.37-12/ti-connectivity-wilink8-0.tar.gz ti-connectivity-wilink8-0]([http://downloads.isee.biz/pub/releases/linux_kernel/v2.6.37-12/ti-connectivity-wilink8-0.tar.gz.md5 md5sum)]</span>
|}
=<span id="Build_kernel_from_sources" class="mw-headline" style="color: #808080000000;">Build kernel from sources</span>=<span style="color: #808080000000;">'''Download''' the latest stable version sources and follow next steps:</span>
<pre><span style="color: #808080;">wget <a class="external free" href="http://downloads.isee.biz/pub/releases/linux_kernel/v2.6.37-12/linux-omap-2.6.37-12.tar.gz" target="_blank" rel="nofollow noreferrer noopener">http://downloads.isee.biz/pub/releases/linux_kernel/v2.6.37-12/linux-omap-2.6.37-12.tar.gz</a>
cd linux-omap-2.6.37-12
</span></pre>
<span style="color: #808080000000;">Also, it could download from GIT Repositories ([http://git.isee.biz/ http://git.isee.biz/]) and test the last unstable version at your own risk (see "''Linux mainline tree (development)''" chapter in [index.php/The_Linux_kernel The Linux kernel])</span>
==<span id="Important_procedures" class="mw-headline" style="color: #808080000000;">Important procedures</span>==
* <span style="color: #808080;">Remove rootfs modules binaries from any previous Kernel</span>
* <span style="color: #808080;">If you switch to another configuration, clean kernel sources with command: make mrproper</span>
==<span id="igep00x0_defconfig_2" class="mw-headline" style="color: #808080;">igep00x0_defconfigigep00x0_<span style="color: #000000;">defconfig</span></span>==<span style="color: #808080;"><span style="color: #000000;">'''Configure''' Linux kernel </span> for IGEP OMAP3 old Marvell WIFI:</span>
<pre><span style="color: #808080;">make ARCH=arm igep00x0_defconfig
</span></pre>
<span style="color: #808080;"><span style="color: #000000;">Then '''build''' the kernel and kernel modules. </span> The result will be an ''zImage'' file in arch/arm/boot directory. Execute:</span>
<pre><span style="color: #808080;">make ARCH=arm CROSS_COMPILE=[your cross compiler] zImage modules
</span></pre>
<span style="color: #808080000000;">For example, if you are using IGEP SDK Yocto Toolchain then you should execute following cmdline:</span>
<pre><span style="color: #808080;">make ARCH=arm CROSS_COMPILE=arm-poky-linux-gnueabi- zImage modules
</span></pre>
<span style="color: #808080000000;">You can '''install''' the kernel image to your target boot</span>
<pre><span style="color: #808080;">cp arch/arm/boot/zImage /media/boot/zImage
</span></pre>
<span style="color: #808080000000;">You can '''install''' the kernel modules to your target rootfs</span>
<pre><span style="color: #808080;">make ARCH=arm modules_install INSTALL_MOD_PATH=[path to your target rootfs]</span></pre>
=<span id="Kernel_Parameters" class="mw-headline" style="color: #808080000000;">Kernel Parameters</span>=<span style="color: #808080000000;">This chapter describes some [index.php/How_do_I_edit_my_kernel_command_line kernel command line] parameters you can pass to the kernel during system startup. They also depend on the presence of the hardware with which they are associated.</span>
<span style="color: #808080000000;">The '''board.ei485''' parameter allows to use UART1 as RS232 port instead of EI485</span>
<pre><span style="color: #808080000000;"> board.ei485= [yes, no] Format: <string>
no: disable ei485, use UART1 as RS232, supported by igep0020
default: yes
</span></pre>
<span style="color: #808080000000;">The '''buddy''' parameter allows enable or disable expansion boards</span>
<pre><span style="color: #808080000000;"> buddy= [igep0022, base0010] Format: <string>
igep0022: enable expansion board, supported by igep0020
board
default: none
</span></pre>
<span style="color: #808080000000;">The '''buddy.revision''' parameter allows to pass hardware revision for buddy boards</span>
<pre><span style="color: #808080000000;"> buddy.revision= [A, B] Format: <string>
A: enable hardware buddy revision A, only available for base0010
B: enable hardware buddy revision B, only available for base0010
default: A
</span></pre>
<span style="color: #808080000000;">The '''buddy.modem''' parameter allows enable or disable modem</span>
<pre><span style="color: #808080000000;"> buddy.modem= [yes] Format: <string>
yes: enable modem on buddy board, supported by igep0022 expansion board.
default: none
</span></pre>
==<span id="Scenarios" class="mw-headline" style="color: #808080000000;">Scenarios</span>==<span style="color: #808080000000;">Consider the following situations:</span>
<span style="color: #808080000000;">'''Scenario A.''' You have and IGEP0020 board plus IGEP0022 expansion board, then you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=igep0022
</span></pre>
<span style="color: #808080000000;">Optionally, to enable the IGEP0022 modem which is disabled by default you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=igep0022 buddy.modem=yes
</span></pre>
<span style="color: #808080000000;">NOTE: UART2 can be used for bluetooth OR modem in expansion board but NOT at same time. They are INCOMPATIBLE.</span>
<span style="color: #808080000000;">'''Scenario B.''' You have and IGEP0030 board plus BASE0010 expansion board, then you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=base0010
</span></pre>
<span style="color: #808080000000;">'''Scenario C.''' You have and IGEP0030 board plus BASE0010 Rev. B expansion board, then you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=base0010 buddy.revision=B
</span></pre>
<span style="color: #808080000000;">'''Scenario D.''' You have and IGEP0032 board plus BASE0010 Rev. B expansion board, then you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=base0010 buddy.revision=B
</span></pre>
<span style="color: #808080000000;">'''Scenario E.''' You have and IGEP0030 board plus ILMS0015 expansion board, then you should add in your [index.php/How_do_I_edit_my_kernel_command_line kernel command line]</span>
<pre><span style="color: #808080000000;">buddy=ilms0015
</span></pre>
=<span id="Layout" class="mw-headline" style="color: #808080000000;">Layout</span>=
<span style="color: #808080;">Machine specific files are located in '''arch/arm/mach-omap2/''' directory with name '''board-igep*.c''' :</span>
* <span style="color: #808080;">'''exp-ilms0015.c''': For ILMS0015 expansion board</span>
=<span id="Adding_New_Expansion_Boards" class="mw-headline" style="color: #808080000000;">Adding New Expansion Boards</span>=
<span style="color: #808080;">This chapter is meant to be a starting point for people to learn how to add your own expansion board in three steps.</span>
==<span id="Step_1:_Add_new_expansion_board_file" class="mw-headline" style="color: #808080;">Step 1: Add new expansion board file</span>==
<span style="color: #808080;">As you can see in Layout chapter, an expansion board is called exp-<your board name>.c and should be located in arch/arm/mach-omap2 directory, so the first step will be add a new file for your new expansion board. Following example creates a new expansion board file called exp-dummy.c (arch/arm/mach-omap2/exp-dummy.c)</span>
<pre><span style="color: #808080;"> #include <linux/kernel.h>
<span style="color: #808080;">Try to change rootfs owner from root to your username.</span>
<pre><span style="color: #808080;"> sudo chown <username> -R /media/rootfs</span></pre>
==<span id="wlcore:_Unknown_symbol" class="mw-headline" style="color: #808080;">wlcore: Unknown symbol</span>==
<span style="color: #808080;">Probably, you didn't erase old module binaries from rootfs. Open IGEP terminal and type:</span>
560
edits