ARM – Rock2 – Kernel 4.5-rc7 Boot Success
After a lot of testing, and some more confusion, I have managed to get the Rock2 to boot using the latest (2016.03-rc3) version of U-Boot, and the latest kernel (4.5-rc7)
As previously, there was a lot of conflicting information…….
I started by booting into the semi-proprietary 3.10-based kernel on the SDcard, and then erasing the eMMC (dd if=/dev/zero… etc..).
I managed to get U-Boot to load and run, but the kernel stubbornly refused to load.. I did find some ‘successful’ boot examples using the 4.5-rc kernel, but these all booted onto a ramdisk image (/dev/ram0). (See https://kernelci.org/boot/rk3288-rock2-square/ )
I modified the kernel config and commandline parameters from these examples, and the combination booted into the SDcard successfully:
U-Boot SPL 2016.03-rc3 (Mar 05 2016 - 17:11:08) Trying to boot from MMC U-Boot 2016.03-rc3 (Mar 05 2016 - 17:11:08 -0800) Model: Radxa Rock 2 Square DRAM: 2 GiB MMC: dwmmc@ff0f0000: 0, dwmmc@ff0c0000: 1 stdio_add_devices: Video device failed (ret=-1) In: serial Out: serial Err: serial Net: Net Initialization Skipped No ethernet found. Hit any key to stop autoboot: 0 => boot 6721600 bytes read in 594 ms (10.8 MiB/s) 31421 bytes read in 36 ms (851.6 KiB/s) Kernel image @ 0x2000000 [ 0x000000 - 0x669040 ] ## Flattened Device Tree blob at 01f00000 Booting using the fdt blob at 0x1f00000 Loading Device Tree to 1fff5000, end 1ffffabc ... OK Starting kernel ... [ 0.000000] Booting Linux on physical CPU 0x500 [ 0.000000] Linux version 4.5.0-rc7 (root@rgrock2) (gcc version 5.3.1 20151207 (Red Hat 5.3.1-2) (GCC) ) #1 SMP Sun Mar 13 13:32:42 EDT 2016 [ 0.000000] CPU: ARMv7 Processor [410fc0d1] revision 1 (ARMv7), cr=10c5387d [ 0.000000] CPU: div instructions available: patching division code [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache [ 0.000000] Machine model: Radxa Rock 2 Square [ 0.000000] debug: ignoring loglevel setting. [ 0.000000] cma: Reserved 64 MiB at 0x7c000000 [ 0.000000] Memory policy: Data cache writealloc [ 0.000000] On node 0 totalpages: 524288 [ 0.000000] free_area_init_node: node 0, pgdat c108d640, node_mem_map eeff9000 [ 0.000000] DMA zone: 1536 pages used for memmap [ 0.000000] DMA zone: 0 pages reserved [ 0.000000] DMA zone: 196608 pages, LIFO batch:31 [ 0.000000] HighMem zone: 327680 pages, LIFO batch:31 [ 0.000000] PERCPU: Embedded 12 pages/cpu @eefa5000 s18880 r8192 d22080 u49152 [ 0.000000] pcpu-alloc: s18880 r8192 d22080 u49152 alloc=12*4096 [ 0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3 [ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 522752 [ 0.000000] Kernel command line: console=ttyS2,115200n8 root=/dev/mmcblk1p1 earlyprintk ignore_loglevel [ 0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes) [ 0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes) [ 0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes) [ 0.000000] Memory: 1998816K/2097152K available (8591K kernel code, 1053K rwdata, 4124K rodata, 1104K init, 343K bss, 32800K reserved, 65536K cma-reserved, 1245184K highmem) .................................. ........................................................ ................................ 16.210447] rk_gmac-dwmac ff290000.ethernet eth0: Link is Up - 1Gbps/Full - flow control rx/tx [ 16.219077] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready [ OK ] Started LSB: Bring up/down networking. [ OK ] Started /etc/rc.d/rc.local Compatibility. Starting Wait for Plymouth Boot Screen to Quit... Starting Terminate Plymouth Boot Screen... Fedora 23 (Twenty Three) Kernel 4.5.0-rc7 on an armv7l (ttyS2) ............. # uname -a Linux rgrock2 4.5.0-rc7 #1 SMP Sun Mar 13 13:32:42 EDT 2016 armv7l armv7l armv7l GNU/Linux
If you do not have an hdmi monitor attached, the u-boot sequence will wait for several seconds, before continuing…
The U-Boot parameters I used were as follows:
setenv autoload no setenv bootdelay 10 setenv fdt_high 0x1fffffff setenv bootargs "console=ttyS2,115200n8 root=/dev/mmcblk1p1 earlyprintk ignore_loglevel" setenv bootcmd "ext4load mmc 1:1 ${kernel_addr_r} boot/uboot/zImage; ext4load mmc 1:1 ${fdt_addr_r} boot/uboot/rk3288-rock2-square.dtb; bootz ${kernel_addr_r} - ${fdt_addr_r}"
One further important thing to mention… The cpu/soc runs _hot_ when under load, so you will need a heatsink! When I first attempted to compile the kernel on the rock2, using the usual multi-cpu make command (make -j5 zImage...) the system shut down and rebooted, and the chipset was _very_ hot.. Until I can make up a suitable heatsink – and maybe even a fan? – I compile in single-processor mode (leave out the -j5..), and this is OK..
Robert Gadsdon. March 13, 2016.
Comments
ARM – Rock2 – Kernel 4.5-rc7 Boot Success — No Comments