ARM – Raspberry Pi ‘Classic’ – Device Tree Kernel Compile..
After my tests compiling the new armv7 Pi 2 Kernel – with ‘device tree’ – I decided to try the same with the ‘classic’ armv6 Pi (B+)..
You will need the latest version of the Pi /boot files, including the latest config.txt with the necessary parameters for device tree boot, sound config, etc..
For cross-compilation, I created a pi directory on my x66 system, and used git to download a Pi 3.19.0 kernel tree there:
git clone -b rpi-3.19.y --single-branch https://github.com/raspberrypi/linux
Then created a ~/boot directory to contain the kernel, dtb and System.map files..
Then, in the linux directory:
export ARCH=arm export CROSS_COMPILE=armv7hl-mandriva-linux-gnueabi- (or whatever cross-compiler you use.. don't forget the "-" at the end!) export INSTALL_PATH=../ (install the files locally, within the pi directory) export INSTALL_MOD_PATH=../ (install the ~/lib/modules files locally, within the pi directory)
Then:
make bcmrpi_defconfig (if necessary..) make xconfig make make modules_install make firmware_install cp System.map ../boot cp arch/arm/boot/dts/bcm2708-rpi-b-plus.dtb ../boot cp arch/arm/boot/Image ../boot/kernel.img (Pi armv6 kernel is still called kernel.img)
This will create the kernel, modules, and boot/dtb files all within the local directory created at the start..
Then shut down the Pi, mount its SDcard, and copy files across to its /boot and /lib/modules and /lib/firmware directories..
Re-insert the SDcard, and connect power:
Pidora release 2014 (Raspberry Pi Fedora Remix) Kernel 3.19.0 on an armv6l (ttyAMA0) ................. # uname -a Linux rgpi 3.19.0 #1 PREEMPT Sat Feb 21 15:24:00 PST 2015 armv6l armv6l armv6l GNU/Linux
Robert Gadsdon. February 21, 2014.
Comments
ARM – Raspberry Pi ‘Classic’ – Device Tree Kernel Compile.. — No Comments