Difference between revisions of "U-Boot"
Line 88: | Line 88: | ||
<pre>sudo apt-get install gcc-aarch64-linux-gnu | <pre>sudo apt-get install gcc-aarch64-linux-gnu | ||
</pre> | </pre> | ||
+ | |||
== Build == | == Build == | ||
Line 96: | Line 97: | ||
or for ARM64: | or for ARM64: | ||
<pre>make ARCH=arm CROSS_COMPILE=aarch64-linux-gnu-</pre> | <pre>make ARCH=arm CROSS_COMPILE=aarch64-linux-gnu-</pre> | ||
+ | |||
+ | In order to support debug in ARM DS-5, you may need option in make | ||
+ | |||
+ | CFLAGS='-gdwarf-3' | ||
= U-Boot functions = | = U-Boot functions = | ||
= Istall U-Boot = | = Istall U-Boot = |
Revision as of 11:54, 8 March 2017
U-Boot Guide
Contents
Download U-Boot
Upstream U-Boot
You can clone the u-boot repository by running:
git clone git://git.denx.de/u-boot.git
Alternatively you can use u-boot-rockchip instead which may with some patches not get in mainline:
git clone git://git.denx.de/u-boot-rockchip.git
Rockchp U-Boot
You can clone the u-boot repository by running:
git clone https://github.com/rockchip-linux/u-boot.git
Supported Devices
Upstream U-Boot support Rockchip SoCs:
RK3036, RK3188, RK3288, RK3328, RK3399
- RK3036 boards supported:
- EVB RK3036 - use evb-rk3036 configuration
- Kylin - use kylin_rk3036 configuration
- RK3288 boards supported:
- EVB RK3288 - use evb-rk3288 configuration
- Fennec RK3288 - use fennec-rk3288 configuration
- Firefly RK3288 - use firefly-rk3288 configuration
- Hisense Chromebook - use chromebook_jerry configuration
- Miniarm RK3288 - use miniarm-rk3288 configuration
- PopMetal RK3288 - use popmetal-rk3288 configuration
- Radxa Rock 2 - use rock2 configuration
- ASUS Tinker
- RK3188 boards supported:
- Radxa Rock - use rock configuration
- RK3328 boards supported:
- EVB RK3328 - use evb-rk3328 configuration
- RK3399 boards supported:
- EVB RK3399 - use evb-rk3399 configuration
Configure U-Boot
First you need to chose a correct defconfig for your board;
When you have determined what <board_name> you want to build, configure:
make CROSS_COMPILE=arm-linux-gnueabi- <board_name>_defconfig
You may need to change the U-Boot function/feature support by modify the defconfig file or,
there is also menuconfig to play with settings if you feel like it:
make CROSS_COMPILE=arm-linux-gnueabi- menuconfig
Build U-Boot
Get a toolchain
If you haven't done so before, get a suitable toolchain installed and added to your PATH.
In Ubuntu 14.04, you can use below command to install cross compiler for armv7:
sudo apt-get install gcc-arm-linux-gnueabi
Or for ARM64
sudo apt-get install gcc-aarch64-linux-gnu
Build
For armv7:
make CROSS_COMPILE=arm-linux-gnueabi-
or for ARM64:
make ARCH=arm CROSS_COMPILE=aarch64-linux-gnu-
In order to support debug in ARM DS-5, you may need option in make
CFLAGS='-gdwarf-3'