RapidIO Intel FPGA IP User Guide

ID 683884
Date 9/15/2021
Public
Document Table of Contents

4.5.3.3.2. Input/Output Avalon® -MM Slave Address Mapping Windows

Address mapping or translation windows map windows of 32-bit Avalon® -MM addresses to windows of 34-bit RapidIO addresses, and are defined by sets of the 32-bit registers.
Table 24.  Address Mapping and Translation Registers
Registers Location
Input/Output slave base address

0x10400, 0x10410, 0x10420, 0x10430, 0x10440,

0x10450, 0x10460, 0x10470, 0x10480, 0x10490, 0x104A0, 0x104B0, 0x104C0, 0x104D0, 0x104E0, 0x104F0

Input/Output slave address mask

0x10404, 0x10414, 0x10424, 0x10434, 0x10444,

0x10454, 0x10464, 0x10474, 0x10484, 0x10494, 0x104A4, 0x104B4, 0x104C4, 0x104D4, 0x104E4, 0x104F4

Input/Output slave address offset

0x10408, 0x10418, 0x10428, 0x10438, 0x10448,

0x10458, 0x10468, 0x10478, 0x10488, 0x10498, 0x104A8, 0x104B8, 0x104C8, 0x104D8, 0x104E8, 0x104F8

Input/Output slave packet control information (for packet header)

0x1040C, 0x1041C, 0x1042C, 0x1043C, 0x1044C,

0x1045C, 0x1046C, 0x1047C, 0x1048C, 0x1049C, 0x104AC, 0x104BC, 0x104CC, 0x104DC, 0x104EC, 0x104FC

A base register, a mask register, and an offset register define a window. The control register stores information used to prepare the packet header on the RapidIO side of the transaction, including the target device’s destination ID, the request packet's priority, and selects between the three available write request packet types: NWRITE, NWRITE_R and SWRITE.

You can change the values of the window-defining registers at any time, even after sending a request packet and before receiving its response packet. However, you should disable a window before changing its window-defining registers. A window is enabled if the window enable (WEN) bit of the Input/Output Slave Mapping Window n Mask register is set, where n is the number of the transmit address translation window.

The number of mapping windows is defined by the parameter Number of transmit address translation windows; up to 16 windows are supported. Each set of registers supports one external host or entity at a time. Your variation must have at least one translation window. Intel® Arria® 10 and Intel® Cyclone® 10 GX variations have 16 transmit address translation windows.

For each window that is enabled, the least significant bits of the Avalon® -MM address are masked out by the window mask and the resulting address is compared to the window base. If the addresses match, the RapidIO address in the outgoing request packet is made of the least significant bits of the Avalon® -MM address and the window offset using the following equation:

Let avalon_address[31:0] be the 32-bit Avalon® -MM address, and rio_addr[33:0] be the RapidIO address, in which rio_addr[33:32] is the 2-bit wide xamsbs field, rio_addr[31:3] is the 29-bit wide address field in the packet, and rio_addr[2:0] is implicitly defined by wdptr and rdsize or wrsize.

Let base[31:0], mask[31:0], and offset[31:0] be the values defined by the three corresponding window-defining registers. The least significant 3 bits of base, mask, and offset are fixed at 3’b000 regardless of the content of the window-defining registers.

Let xamo be the Extended Address MSBits Offset field in the Input/Output Slave Window n Offset register (the two least significant bits of the register).

Starting with window 0, find the first window for which

(({address,Nb’0} & mask) == (base & mask))

where N is 2 in 1x variations and 3 in 2x and 4x variations.

Let 
rio_addr [33:3] = {xamo, (offset [31:3] & mask [31:3]) |
 ({avalon_address,Nb’0} [31:3]])}

If the address matches multiple windows, the lowest number window register set is used. The Avalon® -MM slave interface’s burstcount and byteenable signals determine the values of wdptr and rdsize or wrsize.

The priority and DESTINATION_ID fields are inserted from the control register.

If the address does not match any window the following events occur:

  • An interrupt bit, either WRITE_OUT_OF_BOUNDS or READ_OUT_OF_BOUNDS in the Input/Output Slave Interrupt register, is set.
  • The interrupt signal sys_mnt_s_irq is asserted if enabled by the corresponding bit in the Input/Output Slave Interrupt Enable register.
  • The COMPLETED_OR_CANCELLED_WRITES field of the Input/Output Slave RapidIO Write Requests register is incremented if the transaction is a write request.

An interrupt is cleared by writing 1 to the interrupt register’s corresponding bit location.

Figure 29. Input/Output Slave Window Translation