Lines Matching refs:ports
54 size = (sw->config.max_port_number + 1) * sizeof(*sw->ports);
55 sw->ports = kunit_kzalloc(test, size, GFP_KERNEL);
56 if (!sw->ports)
60 sw->ports[i].sw = sw;
61 sw->ports[i].port = i;
62 sw->ports[i].config.port_number = i;
64 kunit_ida_init(test, &sw->ports[i].in_hopids);
65 kunit_ida_init(test, &sw->ports[i].out_hopids);
83 sw->ports[0].config.type = TB_TYPE_PORT;
84 sw->ports[0].config.max_in_hop_id = 7;
85 sw->ports[0].config.max_out_hop_id = 7;
87 sw->ports[1].config.type = TB_TYPE_PORT;
88 sw->ports[1].config.max_in_hop_id = 19;
89 sw->ports[1].config.max_out_hop_id = 19;
90 sw->ports[1].dual_link_port = &sw->ports[2];
92 sw->ports[2].config.type = TB_TYPE_PORT;
93 sw->ports[2].config.max_in_hop_id = 19;
94 sw->ports[2].config.max_out_hop_id = 19;
95 sw->ports[2].dual_link_port = &sw->ports[1];
96 sw->ports[2].link_nr = 1;
98 sw->ports[3].config.type = TB_TYPE_PORT;
99 sw->ports[3].config.max_in_hop_id = 19;
100 sw->ports[3].config.max_out_hop_id = 19;
101 sw->ports[3].dual_link_port = &sw->ports[4];
103 sw->ports[4].config.type = TB_TYPE_PORT;
104 sw->ports[4].config.max_in_hop_id = 19;
105 sw->ports[4].config.max_out_hop_id = 19;
106 sw->ports[4].dual_link_port = &sw->ports[3];
107 sw->ports[4].link_nr = 1;
109 sw->ports[5].config.type = TB_TYPE_DP_HDMI_IN;
110 sw->ports[5].config.max_in_hop_id = 9;
111 sw->ports[5].config.max_out_hop_id = 9;
112 sw->ports[5].cap_adap = -1;
114 sw->ports[6].config.type = TB_TYPE_DP_HDMI_IN;
115 sw->ports[6].config.max_in_hop_id = 9;
116 sw->ports[6].config.max_out_hop_id = 9;
117 sw->ports[6].cap_adap = -1;
119 sw->ports[7].config.type = TB_TYPE_NHI;
120 sw->ports[7].config.max_in_hop_id = 11;
121 sw->ports[7].config.max_out_hop_id = 11;
123 sw->ports[8].config.type = TB_TYPE_PCIE_DOWN;
124 sw->ports[8].config.max_in_hop_id = 8;
125 sw->ports[8].config.max_out_hop_id = 8;
127 sw->ports[9].config.type = TB_TYPE_PCIE_DOWN;
128 sw->ports[9].config.max_in_hop_id = 8;
129 sw->ports[9].config.max_out_hop_id = 8;
131 sw->ports[10].disabled = true;
132 sw->ports[11].disabled = true;
134 sw->ports[12].config.type = TB_TYPE_USB3_DOWN;
135 sw->ports[12].config.max_in_hop_id = 8;
136 sw->ports[12].config.max_out_hop_id = 8;
138 sw->ports[13].config.type = TB_TYPE_USB3_DOWN;
139 sw->ports[13].config.max_in_hop_id = 8;
140 sw->ports[13].config.max_out_hop_id = 8;
159 sw->ports[0].config.type = TB_TYPE_PORT;
160 sw->ports[0].config.max_in_hop_id = 8;
161 sw->ports[0].config.max_out_hop_id = 8;
163 sw->ports[1].config.type = TB_TYPE_PORT;
164 sw->ports[1].config.max_in_hop_id = 19;
165 sw->ports[1].config.max_out_hop_id = 19;
166 sw->ports[1].dual_link_port = &sw->ports[2];
168 sw->ports[2].config.type = TB_TYPE_PORT;
169 sw->ports[2].config.max_in_hop_id = 19;
170 sw->ports[2].config.max_out_hop_id = 19;
171 sw->ports[2].dual_link_port = &sw->ports[1];
172 sw->ports[2].link_nr = 1;
174 sw->ports[3].config.type = TB_TYPE_PORT;
175 sw->ports[3].config.max_in_hop_id = 19;
176 sw->ports[3].config.max_out_hop_id = 19;
177 sw->ports[3].dual_link_port = &sw->ports[4];
179 sw->ports[4].config.type = TB_TYPE_PORT;
180 sw->ports[4].config.max_in_hop_id = 19;
181 sw->ports[4].config.max_out_hop_id = 19;
182 sw->ports[4].dual_link_port = &sw->ports[3];
183 sw->ports[4].link_nr = 1;
185 sw->ports[5].config.type = TB_TYPE_PORT;
186 sw->ports[5].config.max_in_hop_id = 19;
187 sw->ports[5].config.max_out_hop_id = 19;
188 sw->ports[5].dual_link_port = &sw->ports[6];
190 sw->ports[6].config.type = TB_TYPE_PORT;
191 sw->ports[6].config.max_in_hop_id = 19;
192 sw->ports[6].config.max_out_hop_id = 19;
193 sw->ports[6].dual_link_port = &sw->ports[5];
194 sw->ports[6].link_nr = 1;
196 sw->ports[7].config.type = TB_TYPE_PORT;
197 sw->ports[7].config.max_in_hop_id = 19;
198 sw->ports[7].config.max_out_hop_id = 19;
199 sw->ports[7].dual_link_port = &sw->ports[8];
201 sw->ports[8].config.type = TB_TYPE_PORT;
202 sw->ports[8].config.max_in_hop_id = 19;
203 sw->ports[8].config.max_out_hop_id = 19;
204 sw->ports[8].dual_link_port = &sw->ports[7];
205 sw->ports[8].link_nr = 1;
207 sw->ports[9].config.type = TB_TYPE_PCIE_UP;
208 sw->ports[9].config.max_in_hop_id = 8;
209 sw->ports[9].config.max_out_hop_id = 8;
211 sw->ports[10].config.type = TB_TYPE_PCIE_DOWN;
212 sw->ports[10].config.max_in_hop_id = 8;
213 sw->ports[10].config.max_out_hop_id = 8;
215 sw->ports[11].config.type = TB_TYPE_PCIE_DOWN;
216 sw->ports[11].config.max_in_hop_id = 8;
217 sw->ports[11].config.max_out_hop_id = 8;
219 sw->ports[12].config.type = TB_TYPE_PCIE_DOWN;
220 sw->ports[12].config.max_in_hop_id = 8;
221 sw->ports[12].config.max_out_hop_id = 8;
223 sw->ports[13].config.type = TB_TYPE_DP_HDMI_OUT;
224 sw->ports[13].config.max_in_hop_id = 9;
225 sw->ports[13].config.max_out_hop_id = 9;
226 sw->ports[13].cap_adap = -1;
228 sw->ports[14].config.type = TB_TYPE_DP_HDMI_OUT;
229 sw->ports[14].config.max_in_hop_id = 9;
230 sw->ports[14].config.max_out_hop_id = 9;
231 sw->ports[14].cap_adap = -1;
233 sw->ports[15].disabled = true;
235 sw->ports[16].config.type = TB_TYPE_USB3_UP;
236 sw->ports[16].config.max_in_hop_id = 8;
237 sw->ports[16].config.max_out_hop_id = 8;
239 sw->ports[17].config.type = TB_TYPE_USB3_DOWN;
240 sw->ports[17].config.max_in_hop_id = 8;
241 sw->ports[17].config.max_out_hop_id = 8;
243 sw->ports[18].config.type = TB_TYPE_USB3_DOWN;
244 sw->ports[18].config.max_in_hop_id = 8;
245 sw->ports[18].config.max_out_hop_id = 8;
247 sw->ports[19].config.type = TB_TYPE_USB3_DOWN;
248 sw->ports[19].config.max_in_hop_id = 8;
249 sw->ports[19].config.max_out_hop_id = 8;
285 sw->ports[13].config.type = TB_TYPE_DP_HDMI_IN;
286 sw->ports[13].config.max_in_hop_id = 9;
287 sw->ports[13].config.max_out_hop_id = 9;
289 sw->ports[14].config.type = TB_TYPE_DP_HDMI_IN;
290 sw->ports[14].config.max_in_hop_id = 9;
291 sw->ports[14].config.max_out_hop_id = 9;
303 src_port = &host->ports[5];
322 src_port = &host->ports[12];
323 dst_port = &dev->ports[16];
329 KUNIT_EXPECT_PTR_EQ(test, p, &host->ports[3]);
340 KUNIT_EXPECT_PTR_EQ(test, p, &dev->ports[1]);
376 src_port = &host->ports[8];
377 dst_port = &dev->ports[9];
435 src_port = &host->ports[5];
436 dst_port = &dev2->ports[13];
498 src_port = &host->ports[5];
499 dst_port = &dev3->ports[13];
582 src_port = &dev3->ports[13];
583 dst_port = &dev9->ports[14];
685 src_port = &dev6->ports[13];
686 dst_port = &dev12->ports[13];
726 down = &dev1->ports[10];
727 up = &dev2->ports[9];
777 down = &host->ports[9];
778 up = &dev->ports[9];
839 in = &host->ports[5];
840 out = &dev->ports[13];
919 in = &host->ports[5];
920 out = &dev3->ports[13];
999 in = &dev3->ports[13];
1000 out = &host->ports[5];
1091 in = &host->ports[5];
1092 out = &dev4->ports[13];
1183 in = &dev4->ports[13];
1184 out = &host->ports[5];
1228 down = &host->ports[8];
1229 up = &dev1->ports[9];
1243 down = &dev1->ports[10];
1244 up = &dev2->ports[9];
1279 in = &host->ports[5];
1280 out = &dev->ports[13];
1325 in = &host->ports[5];
1326 out = &dev4->ports[14];
1375 in = &dev2->ports[13];
1376 out = &dev5->ports[13];
1440 in = &dev6->ports[13];
1441 out = &dev12->ports[13];
1454 &host->ports[1]);
1456 &host->ports[3]);
1462 &host->ports[1]);
1464 &host->ports[3]);
1469 &host->ports[3]);
1471 &host->ports[1]);
1497 down = &host->ports[12];
1498 up = &dev1->ports[16];
1512 down = &dev1->ports[17];
1513 up = &dev2->ports[16];
1558 in = &dev2->ports[13];
1559 out = &dev5->ports[13];
1567 port = &host->ports[8];
1570 port = &host->ports[3];
1573 port = &dev1->ports[1];
1576 port = &dev1->ports[3];
1579 port = &dev1->ports[5];
1582 port = &dev1->ports[7];
1585 port = &dev3->ports[1];
1588 port = &dev5->ports[1];
1591 port = &dev4->ports[1];