DART-SD410 Debian 4.4.9 Download Packages: Difference between revisions
Line 44: | Line 44: | ||
</pre> | </pre> | ||
The file build.sh will be | The file build.sh will be placed in the git kernel directory | ||
{{note| NOTE:<br> | {{note| NOTE:<br> |
Revision as of 12:11, 14 August 2016
Create directory tree
Create the following directory tree:
$ mkdir ~/sd410 $ cd ~/sd410
Download kernel source
Download kernel source from git repository
$ git clone https://github.com/varigit/DART-SD410-kernel.git kernel $ git checkout -b kernel-16.06 release/kernel-16.06
Download files from FTP site
Download the whole Debian/Linaro-4.4.9 folder located in /dart-sd410/Software/ on Variscite FTP This will create the following directory tree
sd410 └── Debian └── Linaro-4.4.9(16.06) ├── kernel │ └── build.sh ├── ramdisk │ └── initrd.img-4.4.9-linaro-lt-qcom ├── RescueImages │ ├── sec.dat │ ├── flashall │ ├── boot-sd410.img │ ├── VAR-DT410_rootfs_alip_30Jun2016-68.img │ ├── VAR-DT410_rootfs_developer_30Jun2016-68.img │ ├── emmc_appsboot.mbn │ ├── hyp.mbn │ ├── rpm.mbn │ ├── sbl1.mbn │ ├── tz.mbn │ ├── license.txt │ ├── gpt_both0.bin │ ├── NON-HLOS.bin │ └── flashall.bat └── makebootimg.sh
The file build.sh will be placed in the git kernel directory
Please refer to support@variscite.com for obtaining FTP credentials.
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