1,381
edits
Changes
From IGEP - ISEE Wiki
→Download from git repository
= Summary<br><br> =X-Loader, an initial program loader for Embedded boards based on OMAP processors.
= Features =Security==This is one of the most important reasons why we develop this new IGEP X-loader. you will Probably know that flash devices get new bad memory blocks with normal usage that can make unusable or can damange the software residing inside the flash (ex: upgrading the software, copying a new kernel ... ), in these cases your board won't be usable anymore if you don't use a right nand filesystem that insures data integrity. Using the old schema we've 4 important partitions on flash without any protection, x-loader, u-boot, u-boot enviroment and Limitations<br> =kernel.
== Limitations<br> Easy to use==With this new approach use the software it's more easy to use, if you've the boot information stored inside a jffs2 partition you can use the linux kernel to access it directly without the use of any flash tool to modify the software (ex: using nandwrite it's to risky due to its inability to guarantee data integrity over the Nand Flash memory).
=Features and Limitations= TODO<br> ==Improvements & Modifications==* Added malloc/free functionality.* Added mtd framework and onenand support, removed the old onenand drivers.* Added fs jffs2 support using mtd & onenand support (Read Only).* Added crc32 and zlib.* Jffs2 zlib compression support (Read Only).* Dual boot mmc & onenand with mmc highest priority.* Added Linux kernel boot directly (Support for 2.6.22 and highest version kernels)* Linux kernel supported images: vmlinuz, bzImage and zImage.* Support for loading Linux Ram disk (EXPERIMENTAL)* Added "ini" files parser.* The configuration resides in a plain txt (ini format file).* Support Windows & Linux formating ini files.* boot from mmc, onenand, or mix with mmc highest priority.* Added codeblocks project and compilation rules.* Added support for vfat32 extra names.* Configure TPS65950 voltage to 1.35V if it's used a DM3730 processor.* Added new parameter MachineID in kernel tag file, with it you can* - configure the kernel board ID setup* Added new parameter buddy for kernels 2.6.35.y and 2.6.37.y* Optimize some LPDDR Memory configuration values* Removed some OneNand Debug information* Removed some FAT incorrect warnings* Added Support Initial Ram disk* Reconfigure Makefile options* Support Kernels 2.6.35, 2.6.37, 3.6.4* Added support for boot ARM binary files (such u-boot or QNX kernel)* Support for Numonyx, Micron and hynix POP Memories.* Memory autodetection.* Added GPTimer functionality.* Support Numonyx, Micron and hynix memories.* DMA Copy support* Omtimized memcpy and memset functions.* DSS Video driver.* Support ISEE toolchain yocto 1.2 based.
==Limitations==* The ini configuration file it's limited to max size: 16 KiB* Kernel Command line parameters it's limited to: 4 KiB* Malloc it's hardcode limited to 32 MiB.*Remove compilation warningsVideo is limited to 1024 x 768 x 16 bits.<br> *System RescueVideo Memory is limited to 1280 x 720 x 32 bits.
== STATUS<br> TODO==* Remove compilation warnings.* System Rescue.* Improve boot selection and priority.* Remove unused code.
==STATUS==*Support all :** IGEPv2 DM3730** IGEPv2 OMAP3530** IGEP COM MODULE DM3730** IGEP COM PROTON DM3730** IGEP boards.COM MODULE AM3703
== VERSION CHANGES<br> ==[2.1.0-1] This version only can be build with gcc linaro 4.5.2 other compilers be not supported.
[2.1.0-1] This version only can be build Removed some uncontrolled "printf" with gcc linaro 4incorrect information.5.2 other compilers be not supported.<br>
[2.1.0-1] Removed Modified some uncontrolled "printf" with incorrect informationcode under __DEBUG__ option.<br>
[2.1.0-1] Modified some code under __DEBUG__ optionAdded Support for TPS65950-A3 initialization at 1.<br> 35V
[2.1.0-1] Added Support support for TPS65950-A3 initialization at 1.35V<br> IGEP Module 0030
----
[2.1.0-2] ARM Compilation bug resolved<br>
----
[2.1.0-3] Update SDRAM structure initialization<br>
[2.1.0-3] Added support for Initial RAM disk<br>
[2.1.0-3] Updated Initial RAM disk destination address
----
[2.2.0-1] Update Makefile structure
[2.2.0-1] Downgrade the boot processor speed<br>
----
[2.3.0-1] Add NAND flash devices and Micron MT29CXGXXMAXX memories support
[2.3.0-2] Add Hynix NAND memorie and IGEP0032 support
[2.3.0-2] Added lzo compression schema.
----
[2.3.0-3] Add Support for execute ARM binaries [2.3.0-3] Bug Fixes related to I and D Cache
----
[2.4.0-1] Added Memory test feature
[2.4.0-1] Added some boot information
[2.4.0-1] New read_nand_cache function optimized for load from NAND
[2.4.0-1] BUG resolved: Refresh Setup in Micron & Hynix Memories
[2.4.0-1] BUG resolved: Reset Memory controller after initialize Malloc function
[2.4.0-1] BUG resolved: Resolve problems updating the flash content under jffs2
----
[2.4.0-2] Resolved Memory Autodetection
[2.4.0-2] Better hang board led control
[2.4.0-2] New read_nand_cache function optimized for load from OneNand
[2.4.0-2] Added Hw GPtimer functionality
---- [2.6.0-2] DMA: disable dma_memcpy function due random kernel memory corruption =Pre-Compiled Binaries={| border="1" width="905" cellspacing="1" cellpadding="1" border|-! scope="1col" width|Release! scope="905col" style|Download link! scope="col"|Support|-||2.6.0-2||[http://downloads.isee.biz/pub/releases/IGEP_xloader/igep-x-loader-2.6.0-2.tar.bz2 igep-x-loader-2.6.0-2.tar.bz2]||[[The_IGEP_X-loader#STATUS | DM3730 Boards]]
|-
|-
|| 2.14.0-2 || [http://downloads.igepisee.esbiz/pub/filesreleases/IGEP_xloader/igep-x-loader-2.14.0-2.tar.bz2 igep-x-loader-2.14.0-2.tar.bz2] ||[[The_IGEP_X-loader#STATUS | All OMAP3 Boards]] except IGEP COM MODULE AM3703
|-
|| 2.1.0-3<br> 2|| [http://downloads.igepisee.esbiz/pub/filesreleases/IGEP_xloader/igep-x-loader-2.1.0-32.tar.bz2 igep-x-loader-2.1.0-32.tar.bz2] ||[[The_IGEP_X-loader#STATUS | All OMAP3 Boards<br>]] except IGEP COM MODULE AM3703
|-
|| 2.1.0-3||[http://downloads.isee.biz/pub/releases/IGEP_xloader/igep-x-loader-2.1.0-3.tar.bz2 igep-x-loader-2.1<br> .0-3.tar.bz2]||[[The_IGEP_X-loader#STATUS | All OMAP3 Boards]] except IGEP COM MODULE AM3703|-||2.2.0-1|| [http://downloads.igepisee.esbiz/filespub/releases/IGEP_xloader/igep-x-loader-2.2.0-1.tar.bz2 igep-x-loader-2.2.0-1.tar.bz2] ||[[The_IGEP_X-loader#STATUS | All OMAP3 Boards<br>]] except IGEP COM MODULE AM3703
|}
= Build Procedure<br> ===Build with ISEE SDK Yocto Toolchain 1.2=====Download and Install the cross compiler if you not do it before.===Download the toolchain from this [https://www.isee.biz/support/downloads/item/igep-sdk-yocto-toolchain-1-2-2-3 link] and uncompress it as root in your / directory.
=== Configure Setup the board settings<br> build setup===<pre>make igep00x0_config</pre><pre>Edit the variable CFLAGS and add the option: -fno-stack-protectorCFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -fno-stack-protector</pre> === Build<br> the software===<pre>make CROSS_COMPILE=arm-none-linux-gnueabi-</pre> === Sign the binary x-loader (Only versions prior to 2.5.0-x)===''You should execute contrib/signGP for sign the xloader.''
<pre>contrib/signGP x-load.bin
The signed x-loader it's named: x-load.bin.ift
</pre> = BOOT<br> =
<pre style== MMC Boot =="font-weight: normal;"> git checkout release-2.5.0-2 -b release-2.5.0-2-local</pre>
=== Prepare Configure the microsd card board settings===<pre>make igep00x0_config</pre><pre>Edit the variable CFLAGS and add the option: -fno-stack-protectorCFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -fno-stack-protector</pre>===Build===<pre>make CROSS_COMPILE=arm-none-linux-gnueabi-</pre>===Sign the binary x-loader===''You should execute contrib/signGP for sign the xloader.'' <pre>contrib/signGP x-load.binThe signed x-loader it's named: x-load.bin.ift</pre>=BOOT=The IGEP X-Loader must reside in the microSD card or in the Nand Memory.
==MMC Boot=====Prepare the microsd card===You can follow this howto about how [http://code.google.com/p/beagleboard/wiki/LinuxBootDiskFormat prepare the microsd card] or [[How to boot from MicroSD Card]]<br>
Get a new microsd card and create two partitions, the first one must be fat16/32 and the second one can be formated in any format type supported by linux kernel.<br>
=== Copy the files in the first (FAT) partition ===In the first partition you must copy in this order:
<pre> 48 /* Linux Images */
49 const char* LinuxImageNames [] = {
or you can set the name for your kernel in the configuration file using the tag: kImageName
</pre> Don't use a uImage kernel format (from uboot), only standard kernel formats be supported.
'''kernel build command example''': <pre>$make ARCH=arm CROSS_COMPILE=arm-poky-linux-gnueabi- zImage modules
</pre>
=== Second Partition ===Copy all your rootfs in this second partition.
==Nand Boot===== Nand Partitions<br> ===We've defined 3 partitions on the Nand Memory.
<pre>MTD partitions on "omap2-onenand":
(a) 0x000000000000-0x000000080000 : "X-Loader"
(b) 0x000000080000-0x000000c80000 : "Boot"
(c) 0x000000c80000-0x000020000000 : "File System"
</pre> ==== X-Loader Partition ====* Not fs formated (onenand raw)* Size: 0x80000 (512 KiB)* The xloader must be signed before copy it into the flash memory.
<pre>Suggested procedure:
Erase and copy the x-loader into the first flash partition (mtd0):
</pre>
====<span id="1299156619608S" style="display: none;"> </span>Boot Partition====
* filesystem used jffs2 zlib/lzo compressed filesystem.
* Suggested size: 0xC00000 (12 MiB).
<pre>Suggested procedure:
Erase all mtd1 content:
Create your partition:
<u></u>You can mount the partition over your boot directory in the rootfs <pre>$mount -t jffs2 /dev/mtdblock1 /boot</pre> You can use the cp command for copy your kernel and igep.ini configuration file. <pre>$cp igep.ini /boot$cp zImage /boot</pre>
<pre>cp igep.ini /bootcp zImage /boot</pre>====Rootfs Partition====*fs (your prefered fs supported by linux, maybe a good choice it should be ubifs) *Size, all or you can create more partitions if you wish ... :)
== Boot Priority ==XLoader first try load from mmc and if it fails then try from OneNand.
'''MLO (x-loader)in MMC, igep.ini, and zImage from MMCin Onenand.'''<br/>If all only MLO it's present in the mmc it don't provided this one try to boot load the other information from the Onenand.<br>
Inside the sources/scripts directory you can found a [http://git.isee.biz/?p=pub/scm/igep-x-loader.git;a= Configuration file: blob;f=scripts/igep.ini ;h=ce093fe80c81d8888bf79464f847059b312bba83;hb=refs/heads/master igep.ini] example file.
<pre> 1 [kernel]
2 kaddress=0x80008000
7 kImageName=zImage-test
8 kRdImageName=rdImage-test
9 MachineID=xxxx Where Machine ID = 2344 for IGEPv2 and , ID = 2717 for IGEP COM Module, ID = 3203 for IGEP COM PROTON 10 Mode=<kernel> or <binary> 11 dss=<0 or 1> Enable or Disable Video Output 12 dss_color=<0x00FF8000> Write your desired color in hex value 13 dss_bitmap=<filename> Raw display image</pre> {| border="1" width="800" bordercellspacing="1" cellpadding="1" cellspacing="1"|-||Parameter Name||Description||Default Value||Comments|-||kaddress||Kernel copy address||0x80008000||hex memory address|-||rdaddress||Ram Disk location address||0x81600000||hex memory address
|-
| Parameter Name |serial.low| Description |Serial number (low part)| Default Value |0 - 99999999| Comments|numeric
|-
| kaddress |serial.high| Kernel copy address |Serial number (high part)| 0x80008000 |0 - 99999999| hex memory address|numeric
|-
| rdaddress |revision| Ram Disk location address |Revision ID| 0x81600000 |0 - 9999| hex memory address|numeric
|-
| serial.low|kImageName| Serial number (low part)|Kernel, binary image name| 0 - 99999999|N/A| numeric|Kernel or binary image name
|-
| serial.high|kRdImageName| Serial number (high part)|Ramdisk| 0 - 99999999|N/A| numeric|Ram Disk image name
|-
| revision|MachineID| Revision |Machine ID (kernel ID)| 0 - 9999|2717| numeric|2717 (IGEP COM Module) | 2344 IGEPv2 | 3203 (IGEP COM PROTON)
|-
| kImageName|Mode| Kernel, binary image name|Boot Mode| N/A|kernel| Kernel or |kernel=linux kernel / binary=boot binary image name
|-
| kRdImageName|dss| Ramdisk|Enable Video| N/A|0| Ram Disk image name|0 = Disable, 1 Enable Video Output
|-
| MachineID|dss_color| Machine ID (kernel ID)|Video Color| 2717|0x00FF8000| 2717 (Module) | 2344 IGEPv2|Solid Color
|-
| Mode|dss_bitmap| Boot Mode|Video Bitmap Image| kernel|string| kernel=linux kernel / binary=boot binary |filename with desired image
|}
=== TAG: [kparams] ===In this tag you can add all kernel parameters that you need, this is only an example:
<pre> 10 [kparams]
11 console=ttyS2,115200n8
</pre>
= FAQ ===How I can boot from NFS?==Yes, you should add below parameters in the kparams tag:
<pre>#smsc911x.mac fix your mac address
smsc911x.mac=0xb2,0xb0,0x14,0xb5,0xcd,0xde
root=/dev/nfs
# Set your NFS root path as <server_ip>:<rootfs_path>
nfsroot=192.168.2.105:/srv/nfs/linaro_minimal</pre>==How I can change the assigned kernel memory?==You can use the mem kernel variable as assign your desired kernel memory as: <pre>[kparams]mem=430M</pre>==How I can add more kernel variables?==You can add more variables creating a new variable - value pair under kparams tag as: <pre>boot_delay=0</pre>==How I can modify my MAC address?==You can assign your desired mac address using the variable smsc911x.mac as: <pre>smsc911x.mac=0xb2,0xb0,0x14,0xb5,0xcd,0xde</pre>==How I can boot my board using ubi root filesystem?==You should use these parameters: <pre>ubi.mtd=2 root=ubi0:igep0020-rootfs rootfstype=ubifs</pre>==How I can boot my board using a RAM disk?==Use a RAMdisk it's fully supported. <pre>[kernel]rdaddress=0x81600000kRdImageName=ramdisk.bin [kparams]root=/dev/ram0 rw </pre>==Can I change the Processor frecuency?==Yes you can, IGEP X-loader configures the processor to boot at 600 Mhz you can select a different boot speed using the variable mpurate as: <pre>mpurate=800</pre>If you don't force any frequency the linux kernel will put your processor at the maximum speed (ex: DM3730 will run at 1 Ghz) ==How I can boot downloading the kernel using wget?==The way for do that it's using one minimal kernel and RAMdisk (ex: using image-core-minimal from poky), the procedure can be more or less: a) Copy your minimal kernel and your Ramdisk inside the boot partition. b) Boot Normally from this kernel and Ramdisk, create one script your your desired command such wget http://192.168.15.22/mykernel.bin c) Execute the script when boot (you can do that adding the script to the init enviroment) d) if the downloading it's ok then execute the kexec call, first load the kernel and then pass to it your desired parameters. e) finally boot the new kernel with kexec. ==My board not boot and I don't know what to do ...==When you test your IGEP X-loader, igep.ini file and kernel we suggest use a microsd card in front of use directly the flash nand, if your flash not boot copy all files in one microsd card and boot from there. You can check what happens removing some files from your microsd card for example if you wish test if your flashed kernel it's loaded in a right way then remove the kernel from your microsd card (note: use the same kernel name), IGEP X-loader first try load the file from your microsd card but if it's not found then it try to find the file in the flash. ==How I can upgrade my old kernel?==Just copy the new one, the most secure way it's copy the new one and at end replace the igep.ini file with your new one. <pre> mount -t jffs2 /dev/mtdblock1 /boot cp newkernel.bin /boot cp igep.ini /boot</pre>Use a different kernel name and you always can boot from your old one.
[[Category:Boot_loaders|X_Loader]]