Difference between revisions of "i.MX25 SODIMM PC Linux"

From Voipac Wiki
Jump to navigation Jump to search
 
Line 1: Line 1:
[[Category:i.MX25 SODIMM PC - Development kit]]
+
[[Category:i.MX25 SODIMM PC - Development Kit]]
 
[[Category:Linux]]
 
[[Category:Linux]]
 
<!-- -->
 
<!-- -->

Latest revision as of 10:24, 23 October 2021

This section shows basic steps how to compile a custom Linux kernel.

Linux 4.14

Set toolchain

Export toolchain variables for every related terminal session.

Download and extract source code

mkdir -pv ~/workdir/vmx/linux/
cd ~/workdir/vmx/linux/
git clone https://github.com/voipac/linux.git linux-voipac
cd linux-voipac
git checkout linux-4.14

Compile

Following ouptut files are generated:

  • arch/arm/boot/zImage
  • arch/arm/boot/dts/imx25-voipac-vmx25-254.dtb
  • arch/arm/boot/dts/imx25-voipac-vmx25-264.dtb
  • arch/arm/boot/dts/imx25-voipac-vmx25-265.dtb
cd ~/workdir/vmx/linux/linux-voipac
#make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- menuconfig
make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- imx_v4_v5_defconfig
make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- -j8
#sudo make ARCH=arm INSTALL_MOD_PATH=/srv/nfs/vmx25-rootfs modules_install

Linux 3.12.13

Set toolchain

Export toolchain variables for every related terminal session.

Set shell variables

LK_VERSION=3.12.13
SW_VERSION=20151129
LK_VNAME=${LK_VERSION%[-.]*}

Download and extract source code

mkdir -pv ~/workdir/vmx/linux/
cd ~/workdir/vmx/linux/
wget https://www.kernel.org/pub/linux/kernel/v3.x/linux-${LK_VERSION}.tar.xz
tar -xvJf linux-${LK_VERSION}.tar.xz
mv linux-${LK_VERSION} linux-${LK_VNAME}.orig
cp -rv linux-${LK_VNAME}.orig linux-${LK_VNAME}.work

Apply Voipac patches

cd ~/workdir/vmx/linux/
wget http://downloads.voipac.com/files/i.MX25_SODIMM_PC-Development_kit/module/software/linux/sources/linux-${LK_VERSION}_vmx25_${SW_VERSION}.patch
wget http://downloads.voipac.com/files/i.MX25_SODIMM_PC-Development_kit/module/software/linux/sources/linux-${LK_VERSION}_vmx25_${SW_VERSION}.cfg
cd ~/workdir/vmx/linux/linux-${LK_VNAME}.work
patch -p1  < ../linux-${LK_VERSION}_vmx25_${SW_VERSION}.patch
cp ../linux-${LK_VERSION}_vmx25_${SW_VERSION}.cfg .config

Compile

Output files are called arch/arm/boot/zImage and arch/arm/boot/dts/imx25-vmx25.dtb.

cd ~/workdir/vmx/linux/linux-${LK_VNAME}.work
#make ARCH=arm menuconfig
make -j4 zImage imx25-vmx25.dtb
#sudo make ARCH=arm INSTALL_MOD_PATH=/srv/nfs/vmx25-rootfs modules_install