I decided to put my version of u-boot [[bootloader]] here, along with a short FAQ and list of known bugs. Please feel free to add your bugs or questions here.

+

{{Bootloader}}

+

I decided to put '''U-boot-gena2x''' - my version of [[U-Boot]] [[bootloader]] here, along with a short FAQ and list of known bugs. Please feel free to add your bugs or questions here.

−

The current version of u-boot fully supports uploading and downloading via dfu, booting any known distro, is fully configurable, and has no known grave bugs.

+

The current version of U-Boot ([[U-Boot]] or U-boot-gena2x?) fully supports uploading and downloading via dfu, booting any known distro, is fully configurable, and has no known grave bugs.

== List of changes ==

== List of changes ==

−

This version of u-boot is based on openmoko's stable branch of u-boot. Git can be viewed [http://www.bsdmn.com/cgit/cgit/u-boot/ here].

+

This version of U-Boot is based on openmoko's stable branch of U-Boot. Git can be viewed [http://www.bsdmn.com/cgit/cgit/u-boot/ here].

Significant patches are:

Significant patches are:

Version 2:

Version 2:

−

*GPS is not powered up on boot

+

* + (Solved problem?: ) [[GPS]] is not powered up on boot

−

*Leave all serial ports setup to kernel

+

* + Leave all serial ports setup to kernel

Version 1:

Version 1:

−

*2-4-2 timings

+

* + [[Smedia_Glamo_3362#Timing_settings|2-4-2 timings]]

−

*GPS should work after resume

+

* + GPS should work after resume

== Binaries ==

== Binaries ==

Public freerunners should have the same bootloader (board v5 and later).

Public freerunners should have the same bootloader (board v5 and later).

−

Latest binary version is here [http://www.bsdmn.com/openmoko/uboot/binary/].

+

Latest binary version is here:

+

* http://www.bsdmn.com/openmoko/uboot/binary/

−

to use u-boot as NAND bootloader, you should flash the binary to the special partition:

+

to use U-Boot as NAND bootloader, you should flash the binary to the special partition:

sudo dfu-util -a u-boot -D u-boot_g2x_2.udfu

sudo dfu-util -a u-boot -D u-boot_g2x_2.udfu

== How to setup ==

== How to setup ==

−

NAND uboot occupies 2 partitions on NAND, one partition for u-boot itself and one for it's configuration.

+

NAND U-Boot occupies 2 partitions on NAND, one partition for U-Boot itself and one for it's configuration.

−

To setup u-boot, the easiest way is to edit the simple text file on your computer and then upload it to your phone with dfu-util.

+

To setup U-Boot, the easiest way is to edit the simple text file on your computer and then upload it to your phone with dfu-util.

Sample text config may be found [http://www.bsdmn.com/openmoko/uboot/config/environment.in here]. This version supports various kinds of boot options in the menu. You may use it as a sample for your config.

Sample text config may be found [http://www.bsdmn.com/openmoko/uboot/config/environment.in here]. This version supports various kinds of boot options in the menu. You may use it as a sample for your config.

−

If you are switching from qi, just boot your distro with Qi, then do <code>cat /proc/cmdline</code> and compare/update the parameters in your config file.

+

If you are switching from bootloader [[Qi]], just boot your distro with Qi, then do <code>cat /proc/cmdline</code> and compare/update the parameters in your config file.

Then you can edit the config file to fit your needs, you should prepare it (this adds crc):

Then you can edit the config file to fit your needs, you should prepare it (this adds crc):

use hardware ecc support for NAND, this is not default option use only if your rootfs NAND is flashed not with dfu-util, but with direct copy from sd. this speeds up NAND read on zlib-compressed ubi by 8%.

rootfstype=XX

needed if your rootfs is ext2 to force kernel to use ext2 driver not ext3. use if kernel can't detect partition type

use hardware ecc support for NAND, this is not default option use only if your rootfs NAND is flashed not with dfu-util, but with direct copy from sd. this speeds up NAND read on zlib-compressed ubi by 8%.

rootfstype=XX

needed if your rootfs is ext2 to force kernel to use ext2 driver not ext3. use if kernel can't detect partition type

ubi.mtd=6,2048

claim 6th mtd partition as ubi layer with 2048 page align

rootflags=compr=zlib,no_chk_data_crc

mount options of rootfs, use no_chk_data_crc to speed up ubifs by 8%

mem=127M

reserve 1Mb if you using lindi's ramcomsole patch

How to use

By default, if you press the 'power' button, the "bootcmd" from your config is executed, so set it up accordingly for your default distribution.

To see the boot menu and select desired boot method, hold 'power', wait 1 second and then hold 'aux', wait 1 more second and release both.