summaryrefslogtreecommitdiff
path: root/docs/03-Linux-kernel-build.txt
blob: 9252859d2c852e236b985ee4aa1ad0f39a7c60c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
Building and installing a Linux kernel
======================================

A suitable Linux kernel image for use with the virtualizer
can be built as follows (GCC toolchain used for these steps is:
CodeSourcery Sourcery G++ Lite 2010.09 v4.5.1)

$ tar -jxf arm-virtualizer-v2_3-130312.tar.bz2
$ cd arm-virtualizer-v2_3-130312/bootwrapper
$ make clean
$ pushd /tmp
$ git clone git://linux-arm.org/linux-2.6-lp.git linux-2.6-lp.git
$ cd linux-2.6-lp.git
$ git checkout -b a15-hotplug origin/a15-hotplug
$ yes | make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- vexpress_a15_virt_defconfig
$ make ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- -j4
$ popd
$ cp $OLDPWD/arch/arm/boot/Image payload/kernel

The virtualizer can now be built as usual by invoking:

$ make clean && make

.. in the top bootwrapper directory.

This will result in a file called img.axf located at
arm-virtualizer-v2_3-130312/bootwrapper/img.axf.

To launch the ARM FastModel with the virtualizer, first modify
arm-virtualizer-v2_3-130312/bootwrapper/big-little-MP<x>.mxscript
as usual to fill in paths to the model binary and the img.axf files.
The mxscript file is adequately commented to assist with this.

In case of an MP1 model, we would use the big-little-MP1.mxscript file
and we would specify the path to the model in a manner similar to:

string model = "/home/working_dir/RTSM_VE_Cortex-A15x1-A7x1";

Similarly, in case of an MP4 model, we would use the big-little-MP4.mxscript
and we would specify the path to the model in a manner similar to:

string model = "/home/working_dir/models/RTSM_VE_Cortex-A15x4-A7x4";

The path to the img.axf file is specified using the app directive as
follows:

string app = "arm-virtualizer-v2_3-130312/bootwrapper/img.axf";

The model can then be launched using:

modeldebugger -s arm-virtualizer-v2_3-130312/bootwrapper/big-little-MP<x>.mxscript

Where 'x' is the 1 or 4 respectively in the case of an MP1 model run or an
MP4 model run.

This will result in the Linux kernel console messages appearing the ARM
FastModel UART emulation window. The virtualizer will switch execution
between the two clusters at ~12 million instruction intervals.