Skip to content
Commit 627877d2 authored by Thomas Abraham's avatar Thomas Abraham Committed by Shriram
Browse files

Platform/Sgi: add helper macros for DMA Named Component IORT nodes



Add preprocessor macros for DMA named component nodes of IORT table
that can be used to describe the IO topology connected to the IO
Virtualization block. An IO virtualization block could be used to
connect PCIe root bus or non-PCIe SoC expansion peripherals.

The SoC expansion block that connects to the IO Virtualization block
includes PL330 DMA controllers that connect with SMMUv3 present in
the IO virtualization block in the following manner:

    0x0  -------------   0x30000   ------------
        |  DMA device |---------->|    SMMU    |
        |    (ID)     |           | (StreamID) |
    0x9  -------------   0x30009   ------------

The DMA controller consists of 8 data channels and 1 instruction
channel. The device IDs emitted by the DMA go to the SMMUv3 as
StreamID and the SMMUv3 programs the corresponding translation
contexts.

The peripherals in the SoC expansion block are connected to one of
the x16/x8/x4_1/x4_0 ports of IO virtualization block. Each of these
ports have a base DeviceID that is added to the StreamID of devices
to create the IDs sent to the SMMUv3 and ITS.

Stream ID coming at SMMUv3 is calculated as below:
    Stream ID = DMA Channel Index + Base PCI port index, e.g.

For example, for channel 1 of DMA0 device (connected to x16 port
whose baseID is 0x30000, the streamID that SMMUv3 sees is:
    (1 + 0x30000) = 0x30001.

Change-Id: Id10d0d402621bfde0b5ac74ab93a095601897bf3
Signed-off-by: Thomas Abraham's avatarThomas Abraham <thomas.abraham@arm.com>
Signed-off-by: Vivek Kumar Gautam's avatarVivek Gautam <vivek.gautam@arm.com>
parent f47d0eaa
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment