Blame view
arch/arm/include/asm/arch-fsl-layerscape/stream_id_lsch3.h
4.7 KB
83d290c56 SPDX: Convert all... |
1 |
/* SPDX-License-Identifier: GPL-2.0+ */ |
39da644ea armv8/fsl-lsch3: ... |
2 |
/* |
254a7e3ff armv8: ls1028a: f... |
3 |
* Copyright 2015-2021 NXP |
39da644ea armv8/fsl-lsch3: ... |
4 5 |
* Copyright 2014 Freescale Semiconductor, Inc. * |
39da644ea armv8/fsl-lsch3: ... |
6 7 8 |
*/ #ifndef __FSL_STREAM_ID_H #define __FSL_STREAM_ID_H |
029a407da armv8: ls2080a: u... |
9 |
/* |
a4954f946 armv8: fsl-lsch3:... |
10 11 12 13 14 |
* Stream IDs on NXP Chassis-3 (for example ls2080a, ls1088a, ls2088a) * devices are not hardwired and are programmed by sw. There are a limited * number of stream IDs available, and the partitioning of them is scenario * dependent. This header defines the partitioning between legacy, * PCI, and DPAA2 devices. |
39da644ea armv8/fsl-lsch3: ... |
15 |
* |
029a407da armv8: ls2080a: u... |
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
* This partitioning can be customized in this file depending * on the specific hardware config: * * -non-PCI legacy, platform devices (USB, SD/MMC, SATA, DMA) * -all legacy devices get a unique stream ID assigned and programmed in * their AMQR registers by u-boot * * -PCIe * -there is a range of stream IDs set aside for PCI in this * file. U-boot will scan the PCI bus and for each device discovered: * -allocate a streamID * -set a PEXn LUT table entry mapping 'requester ID' to 'stream ID' * -set a msi-map entry in the PEXn controller node in the * device tree (see Documentation/devicetree/bindings/pci/pci-msi.txt * for more info on the msi-map definition) |
a4954f946 armv8: fsl-lsch3:... |
31 32 33 |
* -set a iommu-map entry in the PEXn controller node in the * device tree (see Documentation/devicetree/bindings/pci/pci-iommu.txt * for more info on the iommu-map definition) |
39da644ea armv8/fsl-lsch3: ... |
34 |
* |
029a407da armv8: ls2080a: u... |
35 36 37 |
* -DPAA2 * -u-boot will allocate a range of stream IDs to be used by the Management * Complex for containers and will set these values in the MC DPC image. |
a78df40cb u-boot: fixup the... |
38 39 40 |
* -u-boot will fixup the iommu-map property in the fsl-mc node in the * device tree (see Documentation/devicetree/bindings/misc/fsl,qoriq-mc.txt * for more info on the msi-map definition) |
029a407da armv8: ls2080a: u... |
41 42 43 |
* -the MC is responsible for allocating and setting up 'isolation context * IDs (ICIDs) based on the allocated stream IDs for all DPAA2 devices. * |
3499dd033 ls1028a: Configur... |
44 45 46 47 |
* - ECAM (integrated PCI) * - U-Boot applies the value here to HW and does DT fix-up for both * 'iommu-map' and 'msi-map' * |
a4954f946 armv8: fsl-lsch3:... |
48 |
* On Chasis-3 SoCs stream IDs are programmed in AMQ registers (32-bits) for |
39da644ea armv8/fsl-lsch3: ... |
49 50 51 52 |
* each of the different bus masters. The relationship between * the AMQ registers and stream IDs is defined in the table below: * AMQ bit streamID bit * --------------------------- |
029a407da armv8: ls2080a: u... |
53 54 55 56 57 58 |
* PL[18] 9 // privilege bit * BMT[17] 8 // bypass translation * VA[16] 7 // reserved * [15] - // unused * ICID[14:7] - // unused * ICID[6:0] 6-0 // isolation context id |
39da644ea armv8/fsl-lsch3: ... |
59 |
* ---------------------------- |
029a407da armv8: ls2080a: u... |
60 |
* |
39da644ea armv8/fsl-lsch3: ... |
61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
*/ #define AMQ_PL_MASK (0x1 << 18) /* priviledge bit */ #define AMQ_BMT_MASK (0x1 << 17) /* bypass bit */ #define FSL_INVALID_STREAM_ID 0 #define FSL_BYPASS_AMQ (AMQ_PL_MASK | AMQ_BMT_MASK) /* legacy devices */ #define FSL_USB1_STREAM_ID 1 #define FSL_USB2_STREAM_ID 2 #define FSL_SDMMC_STREAM_ID 3 #define FSL_SATA1_STREAM_ID 4 |
6d9b82d08 armv8: ls1088a: A... |
75 |
|
dfd52f336 armv8: lx2162a: A... |
76 77 |
#if defined(CONFIG_ARCH_LS2080A) || defined(CONFIG_ARCH_LX2160A) || \ defined(CONFIG_ARCH_LX2162A) |
39da644ea armv8/fsl-lsch3: ... |
78 |
#define FSL_SATA2_STREAM_ID 5 |
6d9b82d08 armv8: ls1088a: A... |
79 |
#endif |
dfd52f336 armv8: lx2162a: A... |
80 81 |
#if defined(CONFIG_ARCH_LS2080A) || defined(CONFIG_ARCH_LX2160A) || \ defined(CONFIG_ARCH_LX2162A) |
39da644ea armv8/fsl-lsch3: ... |
82 |
#define FSL_DMA_STREAM_ID 6 |
b249fcba0 armv8: ls1028a: a... |
83 |
#elif defined(CONFIG_ARCH_LS1088A) || defined(CONFIG_ARCH_LS1028A) |
6d9b82d08 armv8: ls1088a: A... |
84 85 |
#define FSL_DMA_STREAM_ID 5 #endif |
39da644ea armv8/fsl-lsch3: ... |
86 |
|
029a407da armv8: ls2080a: u... |
87 88 |
/* PCI - programmed in PEXn_LUT */ #define FSL_PEX_STREAM_ID_START 7 |
6d9b82d08 armv8: ls1088a: A... |
89 |
|
d4ad111dc armv8: ls1028a: A... |
90 |
#if defined(CONFIG_ARCH_LS2080A) || defined(CONFIG_ARCH_LS1028A) |
029a407da armv8: ls2080a: u... |
91 |
#define FSL_PEX_STREAM_ID_END 22 |
6d9b82d08 armv8: ls1088a: A... |
92 93 |
#elif defined(CONFIG_ARCH_LS1088A) #define FSL_PEX_STREAM_ID_END 18 |
dfd52f336 armv8: lx2162a: A... |
94 |
#elif defined(CONFIG_ARCH_LX2160A) || defined(CONFIG_ARCH_LX2162A) |
7cd427282 armv8: lx2160a: A... |
95 |
#define FSL_PEX_STREAM_ID_END (0x100) |
6d9b82d08 armv8: ls1088a: A... |
96 |
#endif |
39da644ea armv8/fsl-lsch3: ... |
97 98 99 100 |
/* DPAA2 - set in MC DPC and alloced by MC */ #define FSL_DPAA2_STREAM_ID_START 23 #define FSL_DPAA2_STREAM_ID_END 63 |
3499dd033 ls1028a: Configur... |
101 |
/* PCI IEPs, this overlaps DPAA2 but these two are exclusive at least for now */ |
254a7e3ff armv8: ls1028a: f... |
102 |
#define FSL_ECAM_STREAM_ID_START 41 |
3499dd033 ls1028a: Configur... |
103 |
#define FSL_ECAM_STREAM_ID_END 63 |
5c6dc6c9a armv8: ls1088a: a... |
104 105 106 107 108 |
#define FSL_SEC_STREAM_ID 64 #define FSL_SEC_JR1_STREAM_ID 65 #define FSL_SEC_JR2_STREAM_ID 66 #define FSL_SEC_JR3_STREAM_ID 67 #define FSL_SEC_JR4_STREAM_ID 68 |
b249fcba0 armv8: ls1028a: a... |
109 |
#define FSL_SDMMC2_STREAM_ID 69 |
b4a59115e armv8: ls1028a: a... |
110 111 112 113 114 115 116 117 118 119 120 121 122 |
/* * Erratum A-050382 workaround * * Description: * The eDMA ICID programmed in the eDMA_AMQR register in DCFG is not * correctly forwarded to the SMMU. * Workaround: * Program eDMA ICID in the eDMA_AMQR register in DCFG to 40. */ #ifdef CONFIG_SYS_FSL_ERRATUM_A050382 #define FSL_EDMA_STREAM_ID 40 #else |
b249fcba0 armv8: ls1028a: a... |
123 |
#define FSL_EDMA_STREAM_ID 70 |
b4a59115e armv8: ls1028a: a... |
124 |
#endif |
b249fcba0 armv8: ls1028a: a... |
125 126 |
#define FSL_GPU_STREAM_ID 71 #define FSL_DISPLAY_STREAM_ID 72 |
30449aea5 armv8: lx2160a: a... |
127 128 |
#define FSL_SATA3_STREAM_ID 73 #define FSL_SATA4_STREAM_ID 74 |
b249fcba0 armv8: ls1028a: a... |
129 |
|
39da644ea armv8/fsl-lsch3: ... |
130 |
#endif |