DMA Accelerator Functional Unit User Guide: Intel® FPGA Programmable Acceleration Card D5005

ID 683270
Date 8/03/2020
Public
Give Feedback

5. Running DMA AFU Example

Before you begin:
  • You should be familiar with the examples in the Intel Acceleration Stack Quick Start Guide for Intel® FPGA Programmable Acceleration Card D5005 .
  • You must define an environment variable. The environment variable is dependent on the Intel® Acceleration Stack version you are using:
    • For current version, set the environment variable to $OPAE_PLATFORM_ROOT
  • You must install the Intel® Threading Building Blocks (TBB) library since the DMA driver relies on it.
  • You must also set up two 1 GB hugepages to run the sample application.
    $ sudo sh -c "echo 2 > /sys/kernel/mm/hugepages/hugepages-1048576kB/nr_hugepages"

Perform the following steps to download the DMA Accelerator Function (AF) bitstream, to build the application and driver, and to run the design example:

  1. Change to the DMA application and driver directory:
    cd $OPAE_PLATFORM_ROOT/hw/samples/dma_afu/sw
  2. Build the driver and application:
    make
  3. Download the DMA AFU bitstream:
    sudo fpgasupdate ../bin/dma_afu_unsigned.gbs
  4. Execute the host application to write 100 MB in 1 MB portions from host memory to FPGA device memory and read it back:
    ./fpga_dma_test -s 104857600 -p 1048576 -r mtom