DART-SD410 Ubuntu Download Packages: Difference between revisions
(3 intermediate revisions by the same user not shown) | |||
Line 28: | Line 28: | ||
= Boot Image Build = | = Boot Image Build = | ||
Variscite suggests using the downloaded script for building the boot images. | |||
If something goes wrong then try the manual build. | |||
== Automatic creation of the boot image == | == Automatic creation of the boot image == | ||
Build kernel source using supplied script file: | Build kernel source using supplied script file: | ||
Line 55: | Line 57: | ||
</pre> | </pre> | ||
== Manual boot image creation == | == Manual boot image creation == | ||
You will need a default ramdisk for boot image creation.<br> | |||
It is located in the ramdisk directory of the downloaded folder.<br> | |||
Compress all the dtb files and the kernel image file into one dt.img file by: | |||
<pre> | |||
$ ~/bin/skales/dtbTool -o dt.img -s 2048 kernel/build-${ARCH}/arch/arm64/boot/dts/qcom/ | |||
</pre> | |||
Export the command line for linux kernel by: | |||
<pre> | |||
$ export cmdline="root=/dev/mmcblk0p10 rw rootwait console=ttyMSM0,115200n8" | |||
</pre> | |||
Create the boot image by: | |||
<pre> | |||
$ ~/bin/skales/mkbootimg --kernel kernel/build-${ARCH}/arch/arm64/boot/Image \ | |||
--ramdisk ramdisk/initrd.img-4.2.4-linaro-lt-qcom \ | |||
--output boot-sd410.img \ | |||
--dt dt.img \ | |||
--pagesize 2048 \ | |||
--base 0x80000000 \ | |||
--cmdline "$cmdline" | |||
</pre> | |||
The file named boot-sd410.img is created. It should be burned into the board using fastboot. | |||
Remove unneeded dt.img file: | |||
<pre> | |||
$ rm dt.img | |||
</pre> | |||
= Flash new image to the board = | = Flash new image to the board = |
Latest revision as of 12:07, 14 August 2016
Create directory tree
Create the following directory tree:
$ mkdir ~/sd410 $ cd ~/sd410
Download files from FTP site
Download the whole Ubuntu folder located in /dart-sd410/Software/ on Variscite FTP This will create the following directory tree
sd410 └── ubuntu ├── kernel └── ramdisk
Please refer to support@variscite.com for obtaining FTP credentials.
Download kernel source
Download kernel source from git repository
$ git clone https://github.com/varigit/DART-SD410-kernel.git kernel $ git checkout -b release/qcomlt-4.2
Boot Image Build
Variscite suggests using the downloaded script for building the boot images. If something goes wrong then try the manual build.
Automatic creation of the boot image
Build kernel source using supplied script file:
$ ./makebootimg.sh
The kernel sources will be built and the output boot image file will be created in the ~/sd410/ubuntu/Linaro4.2/ directory
Manual kernel build
Export Envornment variables for compiler and architecture
$ export CROSS_COMPILE=aarch64-linux-gnu- $ export ARCH=arm64
The gcc-aarch64-linux-gnu package usually intalled by default. If it is not installed run
$ sudo apt-get install gcc-aarch64-linux-gnu
Select the needed defconfig file for kernel:
$ make O=build-${ARCH} defconfig
Build the kernel and modules
$ make O=build-${ARCH} -j10 $ make O=build-${ARCH} INSTALL_MOD_PATH=build-${ARCH}-modules modules_install
Manual boot image creation
You will need a default ramdisk for boot image creation.
It is located in the ramdisk directory of the downloaded folder.
Compress all the dtb files and the kernel image file into one dt.img file by:
$ ~/bin/skales/dtbTool -o dt.img -s 2048 kernel/build-${ARCH}/arch/arm64/boot/dts/qcom/
Export the command line for linux kernel by:
$ export cmdline="root=/dev/mmcblk0p10 rw rootwait console=ttyMSM0,115200n8"
Create the boot image by:
$ ~/bin/skales/mkbootimg --kernel kernel/build-${ARCH}/arch/arm64/boot/Image \ --ramdisk ramdisk/initrd.img-4.2.4-linaro-lt-qcom \ --output boot-sd410.img \ --dt dt.img \ --pagesize 2048 \ --base 0x80000000 \ --cmdline "$cmdline"
The file named boot-sd410.img is created. It should be burned into the board using fastboot. Remove unneeded dt.img file:
$ rm dt.img
Flash new image to the board
Cycle power of the VAR-SD410CustomBoard with Back button pressed. it will enter fastboot. run the following commend to update the boot image:
$ sudo fastboot flash boot boot-sd410.img $ sudo fastboot reboot
The board will update the system and reboot with the updated kernel