hc
2023-12-08 01573e231f18eb2d99162747186f59511f56b64d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
ROHM BU18TL82/BU18RL82 Clockless Link-BD Serializer/Deserializer bridge bindings
 
Required properties:
 - compatible: "rohm,bu18tl82" or "rohm,bu18rl82"
 - reg: i2c address of the bridge
 - serdes-init-sequence: register initial code from Rohm vendor
 
optional properties:
 - reset-gpios: a GPIO spec for the reset pin
 - enable-gpios: a GPIO spec for the enable pin
 - power-supply: Reference to the regulator powering the serdes power supply pins
 - sel-mipi: string property for mipi dsi data stream input
 
Example:
 
/ {
   panel {
       compatible = "simple-panel";
       backlight = <&backlight>;
 
       display-timings {
           native-mode = <&timing0>;
           timing0: timing0 {
               clock-frequency = <87000000>;
               hactive = <1920>;
               vactive = <720>;
               hfront-porch = <32>;
               hsync-len = <10>;
               hback-porch = <22>;
               vfront-porch = <10>;
               vsync-len = <4>;
               vback-porch = <7>;
               hsync-active = <0>;
               vsync-active = <0>;
               de-active = <0>;
               pixelclk-active = <0>;
           };
       };
 
       ports {
           #address-cells = <1>;
           #size-cells = <0>;
 
           port@0 {
               reg = <0>;
               panel0_in_i2c2_bu18rl82: endpoint {
                   remote-endpoint = <&i2c2_bu18rl82_out_panel0>;
               };
           };
       };
   };
};
 
&dsi {
   status = "okay";
 
   ports {
       #address-cells = <1>;
       #size-cells = <0>;
 
       port@1 {
           reg = <1>;
 
           dsi0_out_i2c2_bu18tl82: endpoint {
               remote-endpoint = <&i2c2_bu18tl82_in_dsi0>;
           };
       };
   };
};
 
&i2c2 {
   status = "okay";
 
   bu18tl82: bu18tl82@10 {
       compatible = "rohm,bu18tl82";
       reg = <0x10>;
       pinctrl-names = "default";
       pinctrl-0 = <&ser0_rst_gpio>;
       reset-gpios = <&gpio1 RK_PA4 GPIO_ACTIVE_LOW>;
       sel-mipi;
       status = "okay";
 
       serdes-init-sequence = [
           /* TL82 Pattern Gen Set 1
            * Horizontal Gray Scale 256 steps
            */
           040A 0010
           040B 0080
           040C 0080
           040D 0080
           0444 0019
           0445 0020
           0446 001f
 
           ...
       ];
 
       ports {
           #address-cells = <1>;
           #size-cells = <0>;
 
           port@0 {
               reg = <0>;
 
               i2c2_bu18tl82_in_dsi0: endpoint {
                   remote-endpoint = <&dsi0_out_i2c2_bu18tl82>;
               };
           };
 
           port@1 {
               reg = <1>;
 
               i2c2_bu18tl82_out_i2c2_bu18rl82: endpoint {
                   remote-endpoint = <&i2c2_bu18rl82_in_i2c2_bu18tl82>;
               };
           };
       };
   };
 
   bu18rl82: bu18rl82@30 {
       compatible = "rohm,bu18rl82";
       reg = <0x30>;
       status = "okay";
       serdes-init-sequence = [
           /* RL82 Pattern Gen Set
            * Vertical Gray Scale Color Bar
            */
           060A 00B0
           060B 00FF
           060C 00FF
           060D 00FF
           0644 0019
           0645 0020
           0646 001f
           ...
       ];
 
       ports {
           #address-cells = <1>;
           #size-cells = <0>;
 
           port@0 {
               reg = <0>;
 
               i2c2_bu18rl82_in_i2c2_bu18tl82: endpoint {
                   remote-endpoint = <&i2c2_bu18tl82_out_i2c2_bu18rl82>;
               };
           };
 
           port@1 {
               reg = <1>;
 
               i2c2_bu18rl82_out_panel0: endpoint {
                   remote-endpoint = <&panel0_in_i2c2_bu18rl82>;
               };
           };
       };
   };
};