| |||
| Home > Getting Started with ARM Streamline > Setting up the Gator driver and daemon | |||
The Gator daemon and driver collect target metrics and then send them to your host machine.
To enable profiling, load the Gator daemon and driver on your target.
You need the following tools on your host to build the Linux kernel and the Gator driver:
Linux kernel source code for the target platform. Note that Streamline supports only Linux kernel versions 2.6.32 and above.
Either the cross compiler for building the Linux kernel or the ARM Linux GCC that comes with DS-5.
To set up the Gator driver and daemon, first prepare and build your kernel by following these steps:
Navigate to the root source directory of the Linux kernel.
Enter the following command in your shell:
make ARCH=arm CROSS_COMPILE=${CROSS_TOOLS}/bin/arm-none-linux-gnueabi- Your_SoC_defconfig
Enter the following command in your shell:
make ARCH=arm CROSS_COMPILE=${CROSS_TOOLS}/bin/arm-none-linux-gnueabi- menuconfig
Activate the Profiling Support option in General Setup: CONFIG_PROFILING=y.
Under Kernel hacking, activate the Tracers and Trace process context switches and events options: CONFIG_FTRACE=y and CONFIG_ENABLE_DEFAULT_TRACERS=y.
Enter the following command in your shell to build the kernel:
make -j5 ARCH=arm CROSS_COMPILE=${CROSS_TOOLS}/bin/arm-none-linux-gnueabi- uImage
To use Streamline with your ARM target, you need to build
the Gator driver, gator.ko and place it in
the same directory as the Gator daemon, gatord,
on the target file system. Assuming that you have all of the required
tools for building kernel modules, enter the following command to create
the gator.ko module:
make -C kernel_build_dir M=`pwd`
ARCH=arm CROSS_COMPILE=<...> modules
Now that you have all of the necessary files in place, it
is time to start the Gator daemon. To run gatord:
Load the kernel onto the target
Copy gatord and gator.ko into
the file system on the target
gatord is located in on
your host. installdir/arm/armv5t/gatord must be placed in the same
directory as gator.ko on the target.
To ensure gatord has execute
permission, enter the following command:
chmod +x gatord
After making sure that you have root privileges, enter the following to execute the Gator daemon:
./gatord &
By default, gatord uses port 8080 for
communication with the host, but you can adjust this by launching gatord with
the port number as a parameter and changing the Port option
in the Capture Options dialog box. To open the Capture Options dialog
box, click Change capture options in the
ARM Streamline Data view.