Skip to content

Commit b766e3b

Browse files
kishonTero Kristo
authored andcommitted
arm64: dts: ti: k3-j721e-main: Add system controller node and SERDES lane mux
The system controller node manages the CTRL_MMR0 region. Add serdes_ln_ctrl node which is used for controlling the SERDES lane mux. Signed-off-by: Kishon Vijay Abraham I <[email protected]> Signed-off-by: Roger Quadros <[email protected]> Acked-by: Rob Herring <[email protected]> Signed-off-by: Tero Kristo <[email protected]>
1 parent afd094e commit b766e3b

File tree

2 files changed

+80
-0
lines changed

2 files changed

+80
-0
lines changed

arch/arm64/boot/dts/ti/k3-j721e-main.dtsi

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
* Copyright (C) 2016-2019 Texas Instruments Incorporated - https://www.ti.com/
66
*/
77
#include <dt-bindings/phy/phy.h>
8+
#include <dt-bindings/mux/mux.h>
9+
#include <dt-bindings/mux/mux-j721e-wiz.h>
810

911
&cbass_main {
1012
msmc_ram: sram@70000000 {
@@ -19,6 +21,31 @@
1921
};
2022
};
2123

24+
scm_conf: scm-conf@100000 {
25+
compatible = "ti,j721e-system-controller", "syscon", "simple-mfd";
26+
reg = <0 0x00100000 0 0x1c000>; /* excludes pinctrl region */
27+
#address-cells = <1>;
28+
#size-cells = <1>;
29+
ranges = <0x0 0x0 0x00100000 0x1c000>;
30+
31+
serdes_ln_ctrl: serdes-ln-ctrl@4080 {
32+
compatible = "mmio-mux";
33+
reg = <0x00004080 0x50>;
34+
#mux-control-cells = <1>;
35+
mux-reg-masks = <0x4080 0x3>, <0x4084 0x3>, /* SERDES0 lane0/1 select */
36+
<0x4090 0x3>, <0x4094 0x3>, /* SERDES1 lane0/1 select */
37+
<0x40a0 0x3>, <0x40a4 0x3>, /* SERDES2 lane0/1 select */
38+
<0x40b0 0x3>, <0x40b4 0x3>, /* SERDES3 lane0/1 select */
39+
<0x40c0 0x3>, <0x40c4 0x3>, <0x40c8 0x3>, <0x40cc 0x3>;
40+
/* SERDES4 lane0/1/2/3 select */
41+
idle-states = <SERDES0_LANE0_PCIE0_LANE0>, <SERDES0_LANE1_PCIE0_LANE1>,
42+
<SERDES1_LANE0_PCIE1_LANE0>, <SERDES1_LANE1_PCIE1_LANE1>,
43+
<SERDES2_LANE0_PCIE2_LANE0>, <SERDES2_LANE1_PCIE2_LANE1>,
44+
<MUX_IDLE_AS_IS>, <SERDES3_LANE1_USB3_0>,
45+
<SERDES4_LANE0_EDP_LANE0>, <SERDES4_LANE1_EDP_LANE1>, <SERDES4_LANE2_EDP_LANE2>, <SERDES4_LANE3_EDP_LANE3>;
46+
};
47+
};
48+
2249
gic500: interrupt-controller@1800000 {
2350
compatible = "arm,gic-v3";
2451
#address-cells = <2>;
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
/* SPDX-License-Identifier: GPL-2.0 */
2+
/*
3+
* This header provides constants for J721E WIZ.
4+
*/
5+
6+
#ifndef _DT_BINDINGS_J721E_WIZ
7+
#define _DT_BINDINGS_J721E_WIZ
8+
9+
#define SERDES0_LANE0_QSGMII_LANE1 0x0
10+
#define SERDES0_LANE0_PCIE0_LANE0 0x1
11+
#define SERDES0_LANE0_USB3_0_SWAP 0x2
12+
13+
#define SERDES0_LANE1_QSGMII_LANE2 0x0
14+
#define SERDES0_LANE1_PCIE0_LANE1 0x1
15+
#define SERDES0_LANE1_USB3_0 0x2
16+
17+
#define SERDES1_LANE0_QSGMII_LANE3 0x0
18+
#define SERDES1_LANE0_PCIE1_LANE0 0x1
19+
#define SERDES1_LANE0_USB3_1_SWAP 0x2
20+
#define SERDES1_LANE0_SGMII_LANE0 0x3
21+
22+
#define SERDES1_LANE1_QSGMII_LANE4 0x0
23+
#define SERDES1_LANE1_PCIE1_LANE1 0x1
24+
#define SERDES1_LANE1_USB3_1 0x2
25+
#define SERDES1_LANE1_SGMII_LANE1 0x3
26+
27+
#define SERDES2_LANE0_PCIE2_LANE0 0x1
28+
#define SERDES2_LANE0_SGMII_LANE0 0x3
29+
#define SERDES2_LANE0_USB3_1_SWAP 0x2
30+
31+
#define SERDES2_LANE1_PCIE2_LANE1 0x1
32+
#define SERDES2_LANE1_USB3_1 0x2
33+
#define SERDES2_LANE1_SGMII_LANE1 0x3
34+
35+
#define SERDES3_LANE0_PCIE3_LANE0 0x1
36+
#define SERDES3_LANE0_USB3_0_SWAP 0x2
37+
38+
#define SERDES3_LANE1_PCIE3_LANE1 0x1
39+
#define SERDES3_LANE1_USB3_0 0x2
40+
41+
#define SERDES4_LANE0_EDP_LANE0 0x0
42+
#define SERDES4_LANE0_QSGMII_LANE5 0x2
43+
44+
#define SERDES4_LANE1_EDP_LANE1 0x0
45+
#define SERDES4_LANE1_QSGMII_LANE6 0x2
46+
47+
#define SERDES4_LANE2_EDP_LANE2 0x0
48+
#define SERDES4_LANE2_QSGMII_LANE7 0x2
49+
50+
#define SERDES4_LANE3_EDP_LANE3 0x0
51+
#define SERDES4_LANE3_QSGMII_LANE8 0x2
52+
53+
#endif /* _DT_BINDINGS_J721E_WIZ */

0 commit comments

Comments
 (0)