QDMA - 3.4 English

Versal Adaptive SoC CPM DMA and Bridge Mode for PCI Express Product Guide (PG347)

Document ID
PG347
Release Date
2024-11-22
Version
3.4 English
  1. Navigate to driver root directory
    1. $> cd <parent-path>/dma_ip_drivers/QDMA/linux-kernel
  2. Compile driver and applications
    1. $> make TANDEM_BOOT_SUPPORTED=1
  3. Copy driver and application executables to standard destinations
    1. $> make install
  4. Generate the qdma.conf file manually or using the qdma_generate_conf_file.sh script and place it in /etc/modprobe.d if this is the first time using the driver on the host system. It is also recommended to blacklist the driver modules for boot; refer to the README for instructions
  5. Insert the driver into the kernel
    1. $> modprobe qdma-pf
  6. Set the maximum number of possible queues using sysfs
    1. $> echo 1 > /sys/bus/pcie/devices/0000:01:00.0/qdma/qmax
  7. Add the queue; must use memory mapped DMA and direction is host to card
    1. $> dma-ctl qdma01000 q add idx 0 mode mm dir h2c
  8. Start the queue; must set aperture size so DMA transfer acts on a keyhole
    1. $> dma-ctl qdma01000 q start idx 0 dir h2c aperture_sz 4096
  9. Perform the DMA transfer to SBI
    1. $> dma-to-device -d /dev/qdma01000-MM-0 -f <.pdi file> -s <size> -a 0x102100000
  10. For CPM4 QDMA, perform the following additional steps to reload the qdma driver:
    1. rmmod qdma-pf
    2. modprobe qdma-pf
    3. echo 1 > /sys/bus/pcie/devices/0000:01:00.0/qdma/qmax
    4. dma-ctl qdma01000 q add idx 0 mode mm dir h2c
    5. dma-ctl qdma01000 q start idx 0 dir h2c