Running Sample Applications
Getting Started Guide
69
You may be prompted for a directory location to build the package and the Build Output
Directory. Use the default value for the location to build the package. The Build Output
Directory parameter is ignored.
Note:
In the case where both QAT1.5 and QAT1.6 drivers are loaded, the sample code from the
QAT1.6 driver should be used.
Proceed to
Section 10.1.2.1, “signOfLife Tests”
for instructions on executing the tests.
To manually compile the acceleration sample code, do the following:
The following environment variables must be set to build the modules:
# export ICP_ROOT=<QATdir>
# export ICP_BUILDSYSTEM_PATH=$ICP_ROOT/quickassist/build_system
# export
ICP_ENV_DIR=$ICP_ROOT/quickassist/build_system/build_files/env_files
Note:
Where
<QATdir>
is
/QAT/QAT1.6
or
/QAT/QAT1.5
, depending on what hardware support
is required. If building with mux support, always use the QAT1.6 sample code.
If intermediate modules are required, the following variables must also be set:
# export ICP_BUILD_OUTPUT=$ICP_ROOT/build
# export ICP_TOOLS_TARGET=accelcomp
The sample code is compiled with the default assumption that the kernel source header
files are located in one of the following directories:
64-bit:
/usr/src/kernels/3.1.0-7.fc16.x86_64
32-bit:
/usr/src/kernels/3.1.0-7.fc16.i686
If the kernel source header files are located in a different directory, create the environment
variable with the directory of desired target kernel sources. For example:
# export KERNEL_SOURCE_ROOT=/usr/src/kernels/linux
For Yocto*:
# export KERNEL_SOURCE_ROOT=/usr/src/kernel
You can compile for both Kernel space and User space at the same time using the following
commands:
# cd $ICP_ROOT/quickassist/lookaside/access_layer/src/sample_code
# make perf_all
The generated Linux* kernel object and sample application are located at:
$ICP_ROOT/quickassist/lookaside/access_layer/src/sample_code/build
Proceed to
Section 10.1.2.1, “signOfLife Tests”
for instructions on executing the tests.
10.1.2
Loading the Sample Code
The acceleration kernel module must be installed and the software must be started before
attempting to execute the sample code. This can be verified by running the following
commands:
# lsmod | grep icp_qa_al
# service qat_service status