blob: 80917224b95eeee49126c9d58d006094aac8ddad [file] [log] [blame]
York Sun5f208d12013-03-25 07:40:06 +00001/*
2 * Copyright 2012 Freescale Semiconductor, Inc.
3 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02004 * SPDX-License-Identifier: GPL-2.0+
York Sun5f208d12013-03-25 07:40:06 +00005 */
6
7#include <common.h>
8#include <asm/fsl_portals.h>
9#include <asm/fsl_liodn.h>
10
11#ifdef CONFIG_SYS_DPAA_QBMAN
12struct qportal_info qp_info[CONFIG_SYS_QMAN_NUM_PORTALS] = {
13 /* dqrr liodn, frame data liodn, liodn off, sdest */
14 SET_QP_INFO(1, 27, 1, 0),
15 SET_QP_INFO(2, 28, 1, 0),
16 SET_QP_INFO(3, 29, 1, 1),
17 SET_QP_INFO(4, 30, 1, 1),
18 SET_QP_INFO(5, 31, 1, 2),
19 SET_QP_INFO(6, 32, 1, 2),
20 SET_QP_INFO(7, 33, 1, 3),
21 SET_QP_INFO(8, 34, 1, 3),
22 SET_QP_INFO(9, 35, 1, 0),
23 SET_QP_INFO(10, 36, 1, 0),
York Sun5f208d12013-03-25 07:40:06 +000024};
25#endif
26
York Sun5f208d12013-03-25 07:40:06 +000027struct liodn_id_table liodn_tbl[] = {
28#ifdef CONFIG_SYS_DPAA_QBMAN
29 SET_QMAN_LIODN(62),
30 SET_BMAN_LIODN(63),
31#endif
32
33 SET_SDHC_LIODN(1, 552),
34
Priyanka Jain2892ec52014-11-18 10:53:49 +053035 SET_PME_LIODN(117),
York Sun5f208d12013-03-25 07:40:06 +000036
Priyanka Jain2892ec52014-11-18 10:53:49 +053037 SET_USB_LIODN(1, "fsl-usb2-mph", 553),
38 SET_USB_LIODN(2, "fsl-usb2-dr", 554),
39
40 SET_SATA_LIODN(1, 555),
41 SET_SATA_LIODN(2, 556),
42
43 SET_PCI_LIODN_BASE(CONFIG_SYS_FSL_PCIE_COMPAT, 1, 148),
44 SET_PCI_LIODN_BASE(CONFIG_SYS_FSL_PCIE_COMPAT, 2, 228),
45 SET_PCI_LIODN_BASE(CONFIG_SYS_FSL_PCIE_COMPAT, 3, 308),
46 SET_PCI_LIODN_BASE(CONFIG_SYS_FSL_PCIE_COMPAT, 4, 388),
York Sun5f208d12013-03-25 07:40:06 +000047
Tudor Laurentiu8d3eaa92014-11-20 12:09:31 +020048 SET_DMA_LIODN(1, "fsl,elo3-dma", 147),
49 SET_DMA_LIODN(2, "fsl,elo3-dma", 227),
York Sun5f208d12013-03-25 07:40:06 +000050
York Sun5f208d12013-03-25 07:40:06 +000051 /* SET_NEXUS_LIODN(557), -- not yet implemented */
Zhao Qiang2a44efe2014-03-21 16:21:45 +080052 SET_QE_LIODN(559),
Sandeep Singh377ffcf2014-06-05 18:49:57 +053053 SET_TDM_LIODN(560),
York Sun5f208d12013-03-25 07:40:06 +000054};
55int liodn_tbl_sz = ARRAY_SIZE(liodn_tbl);
56
57#ifdef CONFIG_SYS_DPAA_FMAN
58struct liodn_id_table fman1_liodn_tbl[] = {
59 SET_FMAN_RX_1G_LIODN(1, 0, 88),
60 SET_FMAN_RX_1G_LIODN(1, 1, 89),
61 SET_FMAN_RX_1G_LIODN(1, 2, 90),
62 SET_FMAN_RX_1G_LIODN(1, 3, 91),
63 SET_FMAN_RX_1G_LIODN(1, 4, 92),
64 SET_FMAN_RX_1G_LIODN(1, 5, 93),
York Sun5f208d12013-03-25 07:40:06 +000065};
66int fman1_liodn_tbl_sz = ARRAY_SIZE(fman1_liodn_tbl);
67#endif
68
69struct liodn_id_table sec_liodn_tbl[] = {
70 SET_SEC_JR_LIODN_ENTRY(0, 454, 458),
71 SET_SEC_JR_LIODN_ENTRY(1, 455, 459),
72 SET_SEC_JR_LIODN_ENTRY(2, 456, 460),
73 SET_SEC_JR_LIODN_ENTRY(3, 457, 461),
74 SET_SEC_RTIC_LIODN_ENTRY(a, 453),
75 SET_SEC_RTIC_LIODN_ENTRY(b, 549),
76 SET_SEC_RTIC_LIODN_ENTRY(c, 550),
77 SET_SEC_RTIC_LIODN_ENTRY(d, 551),
78 SET_SEC_DECO_LIODN_ENTRY(0, 541, 610),
79 SET_SEC_DECO_LIODN_ENTRY(1, 542, 611),
Priyanka Jain2892ec52014-11-18 10:53:49 +053080 SET_SEC_DECO_LIODN_ENTRY(2, 543, 612),
81 SET_SEC_DECO_LIODN_ENTRY(3, 544, 613),
82 SET_SEC_DECO_LIODN_ENTRY(4, 545, 614),
83 SET_SEC_DECO_LIODN_ENTRY(5, 546, 615),
84 SET_SEC_DECO_LIODN_ENTRY(6, 547, 616),
85 SET_SEC_DECO_LIODN_ENTRY(7, 548, 617),
York Sun5f208d12013-03-25 07:40:06 +000086};
87int sec_liodn_tbl_sz = ARRAY_SIZE(sec_liodn_tbl);
88
York Sun5f208d12013-03-25 07:40:06 +000089struct liodn_id_table liodn_bases[] = {
90 [FSL_HW_PORTAL_SEC] = SET_LIODN_BASE_2(462, 558),
91#ifdef CONFIG_SYS_DPAA_FMAN
92 [FSL_HW_PORTAL_FMAN1] = SET_LIODN_BASE_1(973),
93#endif
Priyanka Jain2892ec52014-11-18 10:53:49 +053094#ifdef CONFIG_SYS_DPAA_PME
95 [FSL_HW_PORTAL_PME] = SET_LIODN_BASE_2(770, 846),
96#endif
York Sun5f208d12013-03-25 07:40:06 +000097};