<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://wiki.radxa.com/mw/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.radxa.com/mw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Kevin</id>
		<title>Radxa Wiki - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.radxa.com/mw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Kevin"/>
		<link rel="alternate" type="text/html" href="https://wiki.radxa.com/Special:Contributions/Kevin"/>
		<updated>2026-06-13T09:19:04Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.23.3</generator>

	<entry>
		<id>https://wiki.radxa.com/Rock/Linux_Mainline</id>
		<title>Rock/Linux Mainline</title>
		<link rel="alternate" type="text/html" href="https://wiki.radxa.com/Rock/Linux_Mainline"/>
				<updated>2015-07-17T09:22:53Z</updated>
		
		<summary type="html">&lt;p&gt;Kevin: /* Linux Kernel 3.18-rc5 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{rock_header}}&lt;br /&gt;
{{Languages | rock/Linux_Mainline}}&lt;br /&gt;
&lt;br /&gt;
= Linux Kernel 3.18-rc5 =&lt;br /&gt;
&lt;br /&gt;
== Status ==&lt;br /&gt;
&lt;br /&gt;
What currently works in Linux mainline:&lt;br /&gt;
* UART&lt;br /&gt;
* SPI&lt;br /&gt;
* I2C&lt;br /&gt;
* GPIOs / LEDs / IR&lt;br /&gt;
* PWM&lt;br /&gt;
* USB&lt;br /&gt;
* SD/MMC&lt;br /&gt;
* Ethernet&lt;br /&gt;
* Wifi&lt;br /&gt;
* Bluetooth&lt;br /&gt;
&lt;br /&gt;
What remains to be done:&lt;br /&gt;
* DRM Display driver / LCD controller&lt;br /&gt;
* HDMI drivers (ITE66121 / RK616)&lt;br /&gt;
* TV OUT drivers (RK1000)&lt;br /&gt;
* NAND flash support&lt;br /&gt;
&lt;br /&gt;
== Requirements ==&lt;br /&gt;
&lt;br /&gt;
Ubuntu 14.10 / GCC 4.9+ (GCC 4.8 is not supported)&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install git build-essential gcc-arm-linux-gnueabihf lzop libncurses5-dev libssl-dev bc&lt;br /&gt;
&lt;br /&gt;
== Get the source code ==&lt;br /&gt;
&lt;br /&gt;
Get '''linux-next''' kernel tree (stable branch), default config and updated device-tree.&lt;br /&gt;
&lt;br /&gt;
 git clone -b stable --depth 1 git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git&lt;br /&gt;
 cd linux-next&lt;br /&gt;
&lt;br /&gt;
 wget http://rockchip.fr/radxa/linux/rockchip_defconfig -O arch/arm/configs/rockchip_defconfig&lt;br /&gt;
 wget http://rockchip.fr/radxa/linux/rk3188-radxarock.dts -O arch/arm/boot/dts/rk3188-radxarock.dts&lt;br /&gt;
&lt;br /&gt;
== Build kernel ==&lt;br /&gt;
&lt;br /&gt;
We have to build two files:&lt;br /&gt;
* '''zImage''' (the kernel)&lt;br /&gt;
* '''rk3188-radxarock.dtb''' (the device tree blob)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 export ARCH=arm&lt;br /&gt;
 export CROSS_COMPILE=arm-linux-gnueabihf-&lt;br /&gt;
&lt;br /&gt;
 make rockchip_defconfig&lt;br /&gt;
 make -j8 zImage dtbs&lt;br /&gt;
&lt;br /&gt;
== Create boot image ==&lt;br /&gt;
&lt;br /&gt;
Install mkbootimg if you don't have it on your system.&lt;br /&gt;
&lt;br /&gt;
    git clone https://github.com/neo-technologies/rockchip-mkbootimg.git&lt;br /&gt;
    cd rockchip-mkbootimg&lt;br /&gt;
    make&lt;br /&gt;
    sudo make install&lt;br /&gt;
    cd ..&lt;br /&gt;
&lt;br /&gt;
We need to append the device tree blob to zImage (CONFIG_ARM_APPENDED_DTB option) until we can use U-Boot device tree support.&lt;br /&gt;
&lt;br /&gt;
 cat arch/arm/boot/zImage arch/arm/boot/dts/rk3188-radxarock.dtb &amp;gt; zImage-dtb&lt;br /&gt;
&lt;br /&gt;
==get ramdisk==&lt;br /&gt;
&lt;br /&gt;
    git clone https://github.com/radxa/initrd.git&lt;br /&gt;
    find . ! -path &amp;quot;./.git*&amp;quot;  | cpio -H newc  -ov &amp;gt; initrd.img&lt;br /&gt;
&lt;br /&gt;
Create the '''boot.img''' using mkbootimg (Rockchip version).&lt;br /&gt;
&lt;br /&gt;
 mkbootimg --kernel zImage-dtb --ramdisk initrd.img -o boot.img&lt;br /&gt;
&lt;br /&gt;
== Flash parameter and boot image ==&lt;br /&gt;
&lt;br /&gt;
Get a parameter file from http://dl.radxa.com/rock/images/parameter&lt;br /&gt;
&lt;br /&gt;
 wget http://dl.radxa.com/rock/images/parameter/parameter_linux_sd&lt;br /&gt;
&lt;br /&gt;
Flash parameter and boot.img using [https://github.com/linux-rockchip/rkflashtool '''rkflashtool''']&lt;br /&gt;
&lt;br /&gt;
 rkflashtool P &amp;lt; parameter_linux_sd&lt;br /&gt;
 rkflashtool w boot &amp;lt; boot.img&lt;br /&gt;
 rkflashtool b&lt;br /&gt;
&lt;br /&gt;
= Notes =&lt;br /&gt;
&lt;br /&gt;
== Install Rootfs in first partition of SD card ==&lt;br /&gt;
&lt;br /&gt;
Your rootfs should be in ext4 format. It will be loaded from '''/dev/mmcblk0p1''' by default.&lt;br /&gt;
&lt;br /&gt;
== Wireless ==&lt;br /&gt;
&lt;br /&gt;
The Realtek wifi chipsets require firmwares to be installed in '''/lib/firmware/rtlwifi'''&lt;br /&gt;
&lt;br /&gt;
You can get them by installing the '''linux-firmware''' package from your Linux distribution&lt;br /&gt;
 sudo apt-get install linux-firmware&lt;br /&gt;
&lt;br /&gt;
or download them from here: http://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/tree/rtlwifi&lt;br /&gt;
&lt;br /&gt;
== Bluetooth ==&lt;br /&gt;
&lt;br /&gt;
The '''rtl8723au_bt''' driver is not in the mainline kernel yet, but you can build it this way:&lt;br /&gt;
&lt;br /&gt;
 git clone -b new https://github.com/lwfinger/rtl8723au_bt.git&lt;br /&gt;
 cd rtl8723au_bt/Linux_BT_USB_2.11.20140423_8723BE/&lt;br /&gt;
 wget http://rockchip.fr/radxa/linux/patches/rtl8723au_bt/0001-Add-hci_recv_fragment-function.patch&lt;br /&gt;
 git am 0001-Add-hci_recv_fragment-function.patch&lt;br /&gt;
 make KDIR=../..&lt;br /&gt;
&lt;br /&gt;
Copy the firmware files and '''rtk_btusb.ko''' into your rootfs:&lt;br /&gt;
 8723A/rtl8723a_fw -&amp;gt; /lib/firmware/rtl8723a_fw&lt;br /&gt;
 8723B/rtl8723b_fw -&amp;gt; /lib/firmware/rtl8723b_fw&lt;/div&gt;</summary>
		<author><name>Kevin</name></author>	</entry>

	<entry>
		<id>https://wiki.radxa.com/Rock/Booting_Linux/zh_cn</id>
		<title>Rock/Booting Linux/zh cn</title>
		<link rel="alternate" type="text/html" href="https://wiki.radxa.com/Rock/Booting_Linux/zh_cn"/>
				<updated>2015-07-17T09:19:44Z</updated>
		
		<summary type="html">&lt;p&gt;Kevin: /* 生成 ramdisk */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=== 开发要求 ===&lt;br /&gt;
* radxa rock (全版或者简版)&lt;br /&gt;
* 64bit Linux (e.g. Ubuntu) 开发环境&lt;br /&gt;
* micro USB 数据线&lt;br /&gt;
* 5V/2A的电源&lt;br /&gt;
&lt;br /&gt;
=== Install the toolchain ===&lt;br /&gt;
&lt;br /&gt;
下载交叉编译工具链&lt;br /&gt;
&lt;br /&gt;
64bit 主机&lt;br /&gt;
&lt;br /&gt;
    git clone -b kitkat-release --depth 1 https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6&lt;br /&gt;
&lt;br /&gt;
或者从这里下载&lt;br /&gt;
   &lt;br /&gt;
    [http://dl.radxa.com/rock/source/x86_64_arm-eabi-4.6.zip  http://dl.radxa.com/rock/source/x86_64_arm-eabi-4.6.zip ]&lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
32bit主机&lt;br /&gt;
&lt;br /&gt;
    git clone -b jb-release --depth 1 https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6&lt;br /&gt;
&lt;br /&gt;
或者在这里下载&lt;br /&gt;
   &lt;br /&gt;
     [http://dl.radxa.com/rock/source/x86_32_arm-eabi-4.6.zip http://dl.radxa.com/rock/source/x86_32_arm-eabi-4.6.zip]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
设置环境变量&lt;br /&gt;
&lt;br /&gt;
    export ARCH=arm&lt;br /&gt;
    export CROSS_COMPILE=`pwd`/arm-eabi-4.6/bin/arm-eabi-&lt;br /&gt;
&lt;br /&gt;
请确保这些交叉工具链能够正常工作,如有问题请参考错误提示信息清除问题&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Get the source code ===&lt;br /&gt;
&lt;br /&gt;
    git clone -b radxa-stable-3.0 https://github.com/radxa/linux-rockchip.git&lt;br /&gt;
&lt;br /&gt;
   or download here&lt;br /&gt;
    http://pan.baidu.com/s/1jfOTo  (china)&lt;br /&gt;
&lt;br /&gt;
=== 编译内核 ===&lt;br /&gt;
&lt;br /&gt;
    cd linux-rockchip&lt;br /&gt;
&lt;br /&gt;
if your Rock is pro(Mid 2014) or the new lite(Mid 2014), use radxa_rock_pro_linux_defconfig, check out [[Rock/hardware_revision| hardware revision]]&lt;br /&gt;
    make radxa_rock_pro_linux_defconfig&lt;br /&gt;
&lt;br /&gt;
if your rock is full version(2013) or the old lite(2013), use radxa_rock_linux_defconfig, check out [[Rock/hardware_revision| hardware revision]]&lt;br /&gt;
    make radxa_rock_linux_defconfig&lt;br /&gt;
&lt;br /&gt;
    make -j8&lt;br /&gt;
&lt;br /&gt;
生成的内核文件位置是在 '''arch/arm/boot/Image'''。&lt;br /&gt;
&lt;br /&gt;
=== 编译内核模块 ===&lt;br /&gt;
    mkdir modules&lt;br /&gt;
    export INSTALL_MOD_PATH=./modules&lt;br /&gt;
    make modules &amp;amp;&amp;amp; make modules_install&lt;br /&gt;
    cd ..&lt;br /&gt;
现在所以的内核模块都在 '''modules/lib/modules/3.0.36+/'''文件夹中。&lt;br /&gt;
&lt;br /&gt;
=== 生成 ramdisk ===&lt;br /&gt;
&lt;br /&gt;
    git clone https://github.com/radxa/initrd.git&lt;br /&gt;
    find . ! -path &amp;quot;./.git*&amp;quot;  | cpio -H newc  -ov &amp;gt; initrd.img&lt;br /&gt;
&lt;br /&gt;
=== 生成 boot.img ===&lt;br /&gt;
    wget http://dl.radxa.com/rock/tools/linux/mkbootimg&lt;br /&gt;
    sudo apt-get install lib32stdc++6&lt;br /&gt;
    chmod +x mkbootimg&lt;br /&gt;
    ./mkbootimg --kernel linux-rockchip/arch/arm/boot/Image --ramdisk initrd.img -o boot.img&lt;br /&gt;
&lt;br /&gt;
完成。现在已经生成了RR的“boot.img”文件了。&lt;br /&gt;
&lt;br /&gt;
=== 修改 parameter 文件===&lt;br /&gt;
linux的根文件系统（rootfs）可能处于不同的分区或者媒介中（比如nand、SD卡或者U盘 ），所以你需要告诉内核应该加载哪一个根文件系统。修改你的parameter文件的“root= ”这一行，指向你想加载的那个根文件系统所存放的分区。比如：&lt;br /&gt;
    root=/dev/block/mtd/by-name/linuxroot        # rootfs 在名叫“linuxroot”的nand分区中&lt;br /&gt;
    root=/dev/mmcblk0p1          # rootfs 在SD卡第一分区中&lt;br /&gt;
    root=/dev/sda1                # rootfs 在U盘或者移动硬盘第一分区&lt;br /&gt;
    root=LABEL=linuxroot         # rootfs在标签为“linuxroot”分区，这个分区可能是SD卡、U盘或者移动硬盘。&lt;/div&gt;</summary>
		<author><name>Kevin</name></author>	</entry>

	</feed>