Boot Loader: Difference between revisions

From Linux/Xtensa
Jump to navigation Jump to search
No edit summary
No edit summary
Line 3: Line 3:
The [http://en.wikipedia.org/wiki/Bootloader bootstrap loader or boot loader] is a small program running on a computer or device after power-on to load the operating system. Most boot loaders today provide additional features that allow to upgrade the firmware and access the system for troubleshooting.
The [http://en.wikipedia.org/wiki/Bootloader bootstrap loader or boot loader] is a small program running on a computer or device after power-on to load the operating system. Most boot loaders today provide additional features that allow to upgrade the firmware and access the system for troubleshooting.


== RedBoot ==
== U-Boot <small>([[U-Boot|build instructions for Xtensa]])</small> ==


Tensilica has done a port of [http://sourceware.org/redboot/ RedBoot] for the Xtensa architecture. A RedBoot binary targeting the XTAV60 (LX60) or XTAV200 (LX200) emulation board is usually provided after generating an FPGA bitstream for one of these boards.  See the relevant board documentation from Tensilica for more details such as usage and supported features.  For more information and to request sources, please contact [http://www.tensilica.com/ Tensilica] directly.  For an example of how to boot the Linux kernel using RedBoot on the LX60 or LX200 boards, see [[RedBoot Example]].
U-Boot is one of the most popular boot loaders for Linux. It has a very complete [http://www.denx.de/wiki/U-Boot Project Page] as well as an nice introduction available [http://www.linuxfordevices.com/c/a/Linux-For-Devices-Articles/Introduction-to-Das-UBoot-the-universal-open-source-bootloader/ here]. A very complete U-Boot manual is also available [http://www.denx.de/wiki/DULG/Manual here].


A source tarball for RedBoot with support for the Xtensa architecture is available [http://linux-xtensa.org/pub/redboot/redboot1.3.1-RB2007.2.tgz here].  For more details, see the tarball's [http://linux-xtensa.org/pub/redboot/redboot1.3.1-RB2007.2/README.txt README.txt] file.
A development tree for supporting Xtensa in the latest version of U-Boot has been set up [http://git.linux-xtensa.org/cgi-bin/git.cgi?p=dev/u-boot.git;a=summary here]


== U-Boot ==
An older port to the Xtensa architecture is also available for the LX60 and LX200 FPGA development boards in the git repository [http://git.linux-xtensa.org/cgi-bin/git.cgi?p=discont/u-boot-xtensa.git;a=summary here] with instructions for [[Setting up U-Boot]] for the LX60 or LX200 FPGA development boards.


U-Boot is another popular boot loader which has a very complete [http://www.denx.de/wiki/U-Boot Project Page] as well as an nice introduction availale [http://www.linuxfordevices.com/c/a/Linux-For-Devices-Articles/Introduction-to-Das-UBoot-the-universal-open-source-bootloader/ here] and a very complete U-Boot manual is available [http://www.denx.de/wiki/DULG/Manual here]. A preliminary port to the Xtensa architecture is now available for the LX60 and LX200 FPGA development boards.  We have an up to date git repository available [http://git.linux-xtensa.org/cgi-bin/git.cgi?p=u-boot/u-boot-xtensa.git;a=summary here].    <tt>board/avnet/xtav60/README</tt>).
== RedBoot ==


To use U-Boot on the LX60 or LX200 FPGA development boards first follow the instructions [[Setting up U-Boot]]. Now that U-Boot is running on the board you likely want to taylor it to you environment. For example to boot your linux kernel and mount your root filesystem that you built with buildroot. We have an example available for the HiFi-2 Codec development board available here.
Tensilica has also ported [http://sourceware.org/redboot/ RedBoot] for the Xtensa architecture. A RedBoot binary targeting the XTAV60 (LX60) or XTAV200 (LX200) emulation board is usually provided after generating an FPGA bitstream for one of these boards. See the relevant board documentation from Tensilica for more details such as usage and supported features.  For more information and to request sources, please contact [http://www.tensilica.com/ Tensilica] directly. For an example of how to boot the Linux kernel using RedBoot on the LX60 or LX200 boards, see [[RedBoot Example]].
 
A source tarball for RedBoot with support for the Xtensa architecture is available [http://linux-xtensa.org/pub/redboot/redboot1.3.1-RB2007.2.tgz here].  For more details, see the tarball's [http://linux-xtensa.org/pub/redboot/redboot1.3.1-RB2007.2/README.txt README.txt] file.


== Host-Side Loading via OCD ==
== Host-Side Loading via OCD ==

Revision as of 21:13, 14 June 2013

Boot Loaders

The bootstrap loader or boot loader is a small program running on a computer or device after power-on to load the operating system. Most boot loaders today provide additional features that allow to upgrade the firmware and access the system for troubleshooting.

U-Boot (build instructions for Xtensa)

U-Boot is one of the most popular boot loaders for Linux. It has a very complete Project Page as well as an nice introduction available here. A very complete U-Boot manual is also available here.

A development tree for supporting Xtensa in the latest version of U-Boot has been set up here

An older port to the Xtensa architecture is also available for the LX60 and LX200 FPGA development boards in the git repository here with instructions for Setting up U-Boot for the LX60 or LX200 FPGA development boards.

RedBoot

Tensilica has also ported RedBoot for the Xtensa architecture. A RedBoot binary targeting the XTAV60 (LX60) or XTAV200 (LX200) emulation board is usually provided after generating an FPGA bitstream for one of these boards. See the relevant board documentation from Tensilica for more details such as usage and supported features. For more information and to request sources, please contact Tensilica directly. For an example of how to boot the Linux kernel using RedBoot on the LX60 or LX200 boards, see RedBoot Example.

A source tarball for RedBoot with support for the Xtensa architecture is available here. For more details, see the tarball's README.txt file.

Host-Side Loading via OCD

An alternative to boot loaders is an external (e.g. "host-side") loading mechanism.

One common way to load a Linux kernel is to use debugging interfaces such as On-Chip Debug (OCD). For example, Tensilica Tools GDB (xt-gdb) can connect to a target Xtensa processor using OCD via the Xtensa OCD Daemon. It can then load and execute a Linux RAM image (Image.elf or vmlinux) onto the target using standard GDB commands. See Download and Run the Kernel for an example.

Linux Kernel Self-Boot Image

It is possible to adapt the kernel build scripts for the Xtensa architecture to create a self-booting image. That is, a Linux kernel image that includes a Reset handler and can be either burned in ROM or Flash or downloaded to the target using another mechanism such as OCD. Note: This has not yet been implemented.