Rc_mempoll procedure, Msi_poll procedure – Altera IP Compiler for PCI Express User Manual

Page 285

Advertising
background image

Chapter 15: Testbench and Design Example

15–53

BFM Procedures and Functions

August 2014

Altera Corporation

IP Compiler for PCI Express User Guide

rc_mempoll Procedure

Use the rc_mempoll procedure to poll a given DWORD in a given BFM shared
memory location.

msi_poll Procedure

The msi_poll procedure tracks MSI completion from the endpoint.

Arguments

bar_table

Address of the endpoint bar_table structure in BFM shared memory.

bar_num

BAR number to analyze.

Descriptor_size

Number of descriptor.

direction

When 0 the direction is read.

When 1 the direction is write.

Use_msi

When set, the root port uses native PCI Express MSI to detect the DMA
completion.

Use_eplast

When set, the root port uses BFM shared memory polling to detect the DMA
completion.

Bdt_msb

BFM shared memory upper address value.

Bdt_lsb

BFM shared memory lower address value.

Msi_number

When use_msi is set, specifies the number of the MSI which is set by the
dma_set_msi

procedure.

Msi_traffic_class

When use_msi is set, specifies the MSI traffic class which is set by the
dma_set_msi

procedure.

Multi_message_enable

When use_msi is set, specifies the MSI traffic class which is set by the
dma_set_msi

procedure.

Table 15–65.

dma_set_header

Procedure

Table 15–66.

rc_mempoll

Procedure

Location

altpcietb_bfm_driver_chaining.v or altpcietb_bfm_driver_chaining.vhd

Syntax

rc_mempoll (rc_addr, rc_data, rc_mask)

Arguments

rc_addr

Address of the BFM shared memory that is being polled.

rc_data

Expected data value of the that is being polled.

rc_mask

Mask that is logically ANDed with the shared memory data before it is
compared with rc_data.

Table 15–67.

msi_poll

Procedure

Location

altpcietb_bfm_driver_chaining.v or altpcietb_bfm_driver_chaining.vhd

Syntax

msi_poll(max_number_of_msi,msi_address,msi_expected_dmawr,msi_expected_dmard,dma_wri

te,dma_read)

Advertising