xref: /OK3568_Linux_fs/u-boot/board/rockchip/kylin_rk3036/README (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1Get the Source and prebuild binary
2==================================
3
4  > mkdir ~/kylin_rk3036
5  > cd ~/kylin_rk3036
6  > git clone git://git.denx.de/u-boot.git
7  > git clone https://github.com/rockchip-linux/rkbin.git
8  > git clone https://github.com/rockchip-linux/rkdeveloptool.git
9
10Get the OP-TEE
11===============
12
13  Get tee.bin in this step, copy it to U-Boot root dir:
14  > cp rkbin/rk30/rk3036_tee_v1.00.bin ../u-boot/tee.bin
15
16Compile the U-Boot
17==================
18
19  > cd ../u-boot
20  > export CROSS_COMPILE=arm-linux-gnueabihf-
21  > export ARCH=arm
22  > make kylin-rk3036_defconfig
23  > make
24  > make u-boot.itb
25
26  Get tpl/u-boot-tpl.bin, spl/u-boot-spl.bin and u-boot.itb in this step.
27
28Compile the rkdeveloptool
29=======================
30  Follow instructions in latest README
31  > cd ../rkflashtool
32  > autoreconf -i
33  > ./configure
34  > make
35  > sudo make install
36
37  Get rkdeveloptool in you Host in this step.
38
39Both origin binaries and Tool are ready now, choose either option 1 or
40option 2 to deploy U-Boot.
41
42Package the image
43=================
44
45  > cd ../u-boot
46  > tools/mkimage -n rk3036 -T rksd -d tpl/u-boot-tpl.bin idbloader.img
47  > cat spl/u-boot-spl.bin >> idbloader.img
48
49  Get idbloader.img in this step.
50
51Flash the image to eMMC
52=======================
53Power on(or reset with RESET KEY) with MASKROM KEY preesed, and then:
54  > cd ..
55  > rkdeveloptool db rkbin/rk30/rk3036_loader_v1.07.237.bin
56  > rkdeveloptool wl 64 u-boot/idbloader.img
57  > rkdeveloptool wl 0x4000 u-boot/u-boot.itb
58  > rkdeveloptool rd
59
60Flash the image to SD card
61==========================
62  > dd if=u-boot/idbloader.img of=/dev/sdb seek=64
63  > dd if=u-boot/u-boot.itb of=/dev/sdb seek=16384
64
65You should be able to get U-Boot log message with OP-TEE boot info.
66
67For more detail, please reference to:
68http://opensource.rock-chips.com/wiki_Boot_option
69