17168da16SMasahiro YamadaU-Boot for UniPhier SoC family 27168da16SMasahiro Yamada============================== 37168da16SMasahiro Yamada 47168da16SMasahiro Yamada 57168da16SMasahiro YamadaTested toolchains 67168da16SMasahiro Yamada----------------- 77168da16SMasahiro Yamada 87168da16SMasahiro Yamada (a) Ubuntu packages (CROSS_COMPILE=arm-linux-gnueabi-) 97168da16SMasahiro Yamada 107168da16SMasahiro Yamada If you are building U-Boot on Ubuntu, its standard package is recommended. 117168da16SMasahiro Yamada You can install it as follows: 127168da16SMasahiro Yamada 137168da16SMasahiro Yamada $ sudo apt-get install gcc-arm-linux-gnueabi- 147168da16SMasahiro Yamada 157168da16SMasahiro Yamada (b) Linaro compilers (CROSS_COMPILE=arm-linux-gnueabihf-) 167168da16SMasahiro Yamada 177168da16SMasahiro Yamada You can download pre-built toolchains from: 187168da16SMasahiro Yamada 197168da16SMasahiro Yamada http://www.linaro.org/downloads/ 207168da16SMasahiro Yamada 217168da16SMasahiro Yamada (c) kernel.org compilers (CROSS_COMPILE=arm-unknown-linux-gnueabi-) 227168da16SMasahiro Yamada 237168da16SMasahiro Yamada You can download pre-built toolchains from: 247168da16SMasahiro Yamada 257168da16SMasahiro Yamada ftp://www.kernel.org/pub/tools/crosstool/files/bin/ 267168da16SMasahiro Yamada 277168da16SMasahiro Yamada 287168da16SMasahiro YamadaCompile the source 297168da16SMasahiro Yamada------------------ 307168da16SMasahiro Yamada 31e90b3686SMasahiro YamadaPH1-sLD3 reference board: 32e90b3686SMasahiro Yamada $ make uniphier_sld3_defconfig 337168da16SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- 347168da16SMasahiro Yamada 355fd3f434SMasahiro YamadaPH1-LD4 reference board: 365fd3f434SMasahiro Yamada $ make uniphier_ld4_sld8_defconfig 377168da16SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- 387168da16SMasahiro Yamada 395fd3f434SMasahiro YamadaPH1-sLD8 reference board: 405fd3f434SMasahiro Yamada $ make uniphier_ld4_sld8_defconfig 415fd3f434SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- DEVICE_TREE=uniphier-ph1-sld8-ref 425fd3f434SMasahiro Yamada 43e90b3686SMasahiro YamadaPH1-Pro4 reference board: 44e90b3686SMasahiro Yamada $ make uniphier_pro4_defconfig 453365b4ebSMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- 463365b4ebSMasahiro Yamada 47e90b3686SMasahiro YamadaPH1-Pro5 4KBOX Board: 48e90b3686SMasahiro Yamada $ make uniphier_pro5_defconfig 4928f40d4aSMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- 5028f40d4aSMasahiro Yamada 511a264534SMasahiro YamadaProXstream2 Gentil board: 521a264534SMasahiro Yamada $ make uniphier_pxs2_ld6b_defconfig 531a264534SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- DEVICE_TREE=uniphier-proxstream2-gentil 541a264534SMasahiro Yamada 551a264534SMasahiro YamadaProXstream2 Vodka board: 561a264534SMasahiro Yamada $ make uniphier_pxs2_ld6b_defconfig 57019df879SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- 58019df879SMasahiro Yamada 591a264534SMasahiro YamadaPH1-LD6b reference board: 601a264534SMasahiro Yamada $ make uniphier_pxs2_ld6b_defconfig 611a264534SMasahiro Yamada $ make CROSS_COMPILE=arm-linux-gnueabi- DEVICE_TREE=uniphier-ph1-ld6b-ref 62019df879SMasahiro Yamada 637168da16SMasahiro YamadaYou may wish to change the "CROSS_COMPILE=arm-linux-gnueabi-" 647168da16SMasahiro Yamadato use your favorite compiler. 657168da16SMasahiro Yamada 667168da16SMasahiro Yamada 677168da16SMasahiro YamadaBurn U-Boot images to NAND 687168da16SMasahiro Yamada-------------------------- 697168da16SMasahiro Yamada 707168da16SMasahiro YamadaWrite two files to the NAND device as follows: 713cb9abc9SMasahiro Yamada - spl/u-boot-spl.bin at the offset address 0x00000000 723cb9abc9SMasahiro Yamada - u-boot.img at the offset address 0x00010000 737168da16SMasahiro Yamada 747168da16SMasahiro YamadaIf a TFTP server is available, the images can be easily updated. 75f4e190e3SMasahiro YamadaJust copy the u-boot-spl-dtb.bin and u-boot-dtb.img to the TFTP public 76f4e190e3SMasahiro Yamadadirectory, and then run the following command at the U-Boot command line: 777168da16SMasahiro Yamada 787168da16SMasahiro Yamada => run nandupdate 797168da16SMasahiro Yamada 807168da16SMasahiro Yamada 81*c231c436SMasahiro YamadaBurn U-Boot images to eMMC 82*c231c436SMasahiro Yamada-------------------------- 83*c231c436SMasahiro Yamada 84*c231c436SMasahiro YamadaWrite two files to the Boot partition 1 of the eMMC device as follows: 85*c231c436SMasahiro Yamada - spl/u-boot-spl.bin at the offset address 0x00000000 86*c231c436SMasahiro Yamada - u-boot.img at the offset address 0x00010000 87*c231c436SMasahiro Yamada 88*c231c436SMasahiro YamadaIf a TFTP server is available, the images can be easily updated. 89*c231c436SMasahiro YamadaJust copy the u-boot-spl-dtb.bin and u-boot-dtb.img to the TFTP public 90*c231c436SMasahiro Yamadadirectory, and then run the following command at the U-Boot command line: 91*c231c436SMasahiro Yamada 92*c231c436SMasahiro Yamada => run emmcupdate 93*c231c436SMasahiro Yamada 94*c231c436SMasahiro Yamada 957168da16SMasahiro YamadaUniPhier specific commands 967168da16SMasahiro Yamada-------------------------- 977168da16SMasahiro Yamada 987168da16SMasahiro Yamada - pinmon (enabled by CONFIG_CMD_PINMON) 997168da16SMasahiro Yamada shows the boot mode pins that has been latched at the power-on reset 1007168da16SMasahiro Yamada 1017168da16SMasahiro Yamada - ddrphy (enabled by CONFIG_CMD_DDRPHY_DUMP) 1027168da16SMasahiro Yamada shows the DDR PHY parameters set by the PHY training 1037168da16SMasahiro Yamada 1047168da16SMasahiro Yamada 1057168da16SMasahiro YamadaSupported devices 1067168da16SMasahiro Yamada----------------- 1077168da16SMasahiro Yamada 1087168da16SMasahiro Yamada - UART (on-chip) 1097168da16SMasahiro Yamada - NAND 110a111bfbfSMasahiro Yamada - SD/eMMC 1111e7df7c4SMasahiro Yamada - USB 2.0 (EHCI) 1121e7df7c4SMasahiro Yamada - USB 3.0 (xHCI) 113b9a66b63SMasahiro Yamada - GPIO 1147168da16SMasahiro Yamada - LAN (on-board SMSC9118) 1157168da16SMasahiro Yamada - I2C 1167168da16SMasahiro Yamada - EEPROM (connected to the on-board I2C bus) 1177168da16SMasahiro Yamada - Support card (SRAM, NOR flash, some peripherals) 1187168da16SMasahiro Yamada 1197168da16SMasahiro Yamada 12062102beeSMasahiro YamadaMicro Support Card 12162102beeSMasahiro Yamada------------------ 12262102beeSMasahiro Yamada 12362102beeSMasahiro YamadaThe recommended bit switch settings are as follows: 12462102beeSMasahiro Yamada 12562102beeSMasahiro Yamada SW2 OFF(1)/ON(0) Description 12662102beeSMasahiro Yamada ------------------------------------------ 12762102beeSMasahiro Yamada bit 1 <---- BKSZ[0] 12862102beeSMasahiro Yamada bit 2 ----> BKSZ[1] 12962102beeSMasahiro Yamada bit 3 <---- SoC Bus Width 16/32 13062102beeSMasahiro Yamada bit 4 <---- SERIAL_SEL[0] 13162102beeSMasahiro Yamada bit 5 ----> SERIAL_SEL[1] 13262102beeSMasahiro Yamada bit 6 ----> BOOTSWAP_EN 13362102beeSMasahiro Yamada bit 7 <---- CS1/CS5 13462102beeSMasahiro Yamada bit 8 <---- SOC_SERIAL_DISABLE 13562102beeSMasahiro Yamada 13662102beeSMasahiro Yamada SW8 OFF(1)/ON(0) Description 13762102beeSMasahiro Yamada ------------------------------------------ 138e69514ccSMasahiro Yamada bit 1 <---- CS1_SPLIT 13962102beeSMasahiro Yamada bit 2 <---- CASE9_ON 14062102beeSMasahiro Yamada bit 3 <---- CASE10_ON 14162102beeSMasahiro Yamada bit 4 Don't Care Reserve 14262102beeSMasahiro Yamada bit 5 Don't Care Reserve 14362102beeSMasahiro Yamada bit 6 Don't Care Reserve 14462102beeSMasahiro Yamada bit 7 ----> BURST_EN 14562102beeSMasahiro Yamada bit 8 ----> FLASHBUS32_16 14662102beeSMasahiro Yamada 14762102beeSMasahiro YamadaThe BKSZ[1:0] specifies the address range of memory slot and peripherals 14862102beeSMasahiro Yamadaas follows: 14962102beeSMasahiro Yamada 15062102beeSMasahiro Yamada BKSZ Description RAM slot Peripherals 15162102beeSMasahiro Yamada -------------------------------------------------------------------- 152c57a9a63SMasahiro Yamada 0b00 15MB RAM / 1MB Peri 00000000-00efffff 00f00000-00ffffff 153c57a9a63SMasahiro Yamada 0b01 31MB RAM / 1MB Peri 00000000-01efffff 01f00000-01ffffff 154c57a9a63SMasahiro Yamada 0b10 64MB RAM / 1MB Peri 00000000-03efffff 03f00000-03ffffff 155c57a9a63SMasahiro Yamada 0b11 127MB RAM / 1MB Peri 00000000-07efffff 07f00000-07ffffff 15662102beeSMasahiro Yamada 15762102beeSMasahiro YamadaSet BSKZ[1:0] to 0b01 for U-Boot. 15862102beeSMasahiro YamadaThis mode is the most handy because EA[24] is always supported by the save pin 15962102beeSMasahiro Yamadamode of the system bus. On the other hand, EA[25] is not supported for some 16062102beeSMasahiro Yamadanewer SoCs. Even if it is, EA[25] is not connected on most of the boards. 16162102beeSMasahiro Yamada 1627168da16SMasahiro Yamada-- 16362102beeSMasahiro YamadaMasahiro Yamada <yamada.masahiro@socionext.com> 1643cb9abc9SMasahiro YamadaFeb. 2016 165