Lines Matching refs:path
846 struct tb_path *path; in tb_test_path_not_connected() local
856 path = tb_path_alloc(NULL, down, 8, up, 8, 0, "PCIe Down"); in tb_test_path_not_connected()
857 KUNIT_ASSERT_NULL(test, path); in tb_test_path_not_connected()
858 path = tb_path_alloc(NULL, down, 8, up, 8, 1, "PCIe Down"); in tb_test_path_not_connected()
859 KUNIT_ASSERT_NULL(test, path); in tb_test_path_not_connected()
898 struct tb_path *path; in tb_test_path_not_bonded_lane0() local
907 path = tb_path_alloc(NULL, down, 8, up, 8, 0, "PCIe Down"); in tb_test_path_not_bonded_lane0()
908 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_not_bonded_lane0()
909 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_not_bonded_lane0()
913 in_port = path->hops[i].in_port; in tb_test_path_not_bonded_lane0()
914 out_port = path->hops[i].out_port; in tb_test_path_not_bonded_lane0()
925 tb_path_free(path); in tb_test_path_not_bonded_lane0()
960 struct tb_path *path; in tb_test_path_not_bonded_lane1() local
969 path = tb_path_alloc(NULL, in, 9, out, 9, 1, "Video"); in tb_test_path_not_bonded_lane1()
970 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_not_bonded_lane1()
971 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_not_bonded_lane1()
975 in_port = path->hops[i].in_port; in tb_test_path_not_bonded_lane1()
976 out_port = path->hops[i].out_port; in tb_test_path_not_bonded_lane1()
987 tb_path_free(path); in tb_test_path_not_bonded_lane1()
1038 struct tb_path *path; in tb_test_path_not_bonded_lane1_chain() local
1049 path = tb_path_alloc(NULL, in, 9, out, 9, 1, "Video"); in tb_test_path_not_bonded_lane1_chain()
1050 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_not_bonded_lane1_chain()
1051 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_not_bonded_lane1_chain()
1055 in_port = path->hops[i].in_port; in tb_test_path_not_bonded_lane1_chain()
1056 out_port = path->hops[i].out_port; in tb_test_path_not_bonded_lane1_chain()
1067 tb_path_free(path); in tb_test_path_not_bonded_lane1_chain()
1118 struct tb_path *path; in tb_test_path_not_bonded_lane1_chain_reverse() local
1129 path = tb_path_alloc(NULL, in, 9, out, 9, 1, "Video"); in tb_test_path_not_bonded_lane1_chain_reverse()
1130 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_not_bonded_lane1_chain_reverse()
1131 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_not_bonded_lane1_chain_reverse()
1135 in_port = path->hops[i].in_port; in tb_test_path_not_bonded_lane1_chain_reverse()
1136 out_port = path->hops[i].out_port; in tb_test_path_not_bonded_lane1_chain_reverse()
1147 tb_path_free(path); in tb_test_path_not_bonded_lane1_chain_reverse()
1209 struct tb_path *path; in tb_test_path_mixed_chain() local
1221 path = tb_path_alloc(NULL, in, 9, out, 9, 1, "Video"); in tb_test_path_mixed_chain()
1222 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_mixed_chain()
1223 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_mixed_chain()
1227 in_port = path->hops[i].in_port; in tb_test_path_mixed_chain()
1228 out_port = path->hops[i].out_port; in tb_test_path_mixed_chain()
1239 tb_path_free(path); in tb_test_path_mixed_chain()
1301 struct tb_path *path; in tb_test_path_mixed_chain_reverse() local
1313 path = tb_path_alloc(NULL, in, 9, out, 9, 1, "Video"); in tb_test_path_mixed_chain_reverse()
1314 KUNIT_ASSERT_NOT_NULL(test, path); in tb_test_path_mixed_chain_reverse()
1315 KUNIT_ASSERT_EQ(test, path->path_length, ARRAY_SIZE(test_data)); in tb_test_path_mixed_chain_reverse()
1319 in_port = path->hops[i].in_port; in tb_test_path_mixed_chain_reverse()
1320 out_port = path->hops[i].out_port; in tb_test_path_mixed_chain_reverse()
1331 tb_path_free(path); in tb_test_path_mixed_chain_reverse()
2028 struct tb_path *path; in tb_test_credit_alloc_legacy_not_bonded() local
2039 path = tunnel->paths[0]; in tb_test_credit_alloc_legacy_not_bonded()
2040 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_legacy_not_bonded()
2041 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_legacy_not_bonded()
2042 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_legacy_not_bonded()
2043 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_legacy_not_bonded()
2044 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 16U); in tb_test_credit_alloc_legacy_not_bonded()
2046 path = tunnel->paths[1]; in tb_test_credit_alloc_legacy_not_bonded()
2047 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_legacy_not_bonded()
2048 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_legacy_not_bonded()
2049 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_legacy_not_bonded()
2050 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_legacy_not_bonded()
2051 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 16U); in tb_test_credit_alloc_legacy_not_bonded()
2061 struct tb_path *path; in tb_test_credit_alloc_legacy_bonded() local
2072 path = tunnel->paths[0]; in tb_test_credit_alloc_legacy_bonded()
2073 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_legacy_bonded()
2074 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_legacy_bonded()
2075 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_legacy_bonded()
2076 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_legacy_bonded()
2077 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in tb_test_credit_alloc_legacy_bonded()
2079 path = tunnel->paths[1]; in tb_test_credit_alloc_legacy_bonded()
2080 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_legacy_bonded()
2081 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_legacy_bonded()
2082 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_legacy_bonded()
2083 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_legacy_bonded()
2084 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in tb_test_credit_alloc_legacy_bonded()
2094 struct tb_path *path; in tb_test_credit_alloc_pcie() local
2105 path = tunnel->paths[0]; in tb_test_credit_alloc_pcie()
2106 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_pcie()
2107 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_pcie()
2108 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_pcie()
2109 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_pcie()
2110 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in tb_test_credit_alloc_pcie()
2112 path = tunnel->paths[1]; in tb_test_credit_alloc_pcie()
2113 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_pcie()
2114 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_pcie()
2115 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_pcie()
2116 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_pcie()
2117 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 64U); in tb_test_credit_alloc_pcie()
2127 struct tb_path *path; in tb_test_credit_alloc_without_dp() local
2154 path = tunnel->paths[0]; in tb_test_credit_alloc_without_dp()
2155 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_without_dp()
2156 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_without_dp()
2157 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_without_dp()
2158 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_without_dp()
2159 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 9U); in tb_test_credit_alloc_without_dp()
2162 path = tunnel->paths[1]; in tb_test_credit_alloc_without_dp()
2163 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_without_dp()
2164 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_without_dp()
2165 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_without_dp()
2166 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_without_dp()
2167 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 64U); in tb_test_credit_alloc_without_dp()
2177 struct tb_path *path; in tb_test_credit_alloc_dp() local
2190 path = tunnel->paths[0]; in tb_test_credit_alloc_dp()
2191 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dp()
2192 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 12U); in tb_test_credit_alloc_dp()
2193 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in tb_test_credit_alloc_dp()
2194 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 18U); in tb_test_credit_alloc_dp()
2195 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 0U); in tb_test_credit_alloc_dp()
2198 path = tunnel->paths[1]; in tb_test_credit_alloc_dp()
2199 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dp()
2200 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dp()
2201 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in tb_test_credit_alloc_dp()
2202 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dp()
2203 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in tb_test_credit_alloc_dp()
2206 path = tunnel->paths[2]; in tb_test_credit_alloc_dp()
2207 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dp()
2208 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dp()
2209 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in tb_test_credit_alloc_dp()
2210 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dp()
2211 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in tb_test_credit_alloc_dp()
2221 struct tb_path *path; in tb_test_credit_alloc_usb3() local
2232 path = tunnel->paths[0]; in tb_test_credit_alloc_usb3()
2233 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_usb3()
2234 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_usb3()
2235 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_usb3()
2236 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_usb3()
2237 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_usb3()
2239 path = tunnel->paths[1]; in tb_test_credit_alloc_usb3()
2240 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_usb3()
2241 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_usb3()
2242 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in tb_test_credit_alloc_usb3()
2243 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_usb3()
2244 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in tb_test_credit_alloc_usb3()
2254 struct tb_path *path; in tb_test_credit_alloc_dma() local
2267 path = tunnel->paths[0]; in tb_test_credit_alloc_dma()
2268 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma()
2269 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma()
2270 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in tb_test_credit_alloc_dma()
2271 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma()
2272 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma()
2275 path = tunnel->paths[1]; in tb_test_credit_alloc_dma()
2276 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma()
2277 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma()
2278 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in tb_test_credit_alloc_dma()
2279 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma()
2280 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma()
2290 struct tb_path *path; in tb_test_credit_alloc_dma_multiple() local
2320 path = tunnel1->paths[0]; in tb_test_credit_alloc_dma_multiple()
2321 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2322 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2323 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2324 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2325 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2327 path = tunnel1->paths[1]; in tb_test_credit_alloc_dma_multiple()
2328 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2329 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2330 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2331 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2332 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2338 path = tunnel2->paths[0]; in tb_test_credit_alloc_dma_multiple()
2339 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2340 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2341 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2342 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2343 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in tb_test_credit_alloc_dma_multiple()
2345 path = tunnel2->paths[1]; in tb_test_credit_alloc_dma_multiple()
2346 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2347 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2348 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2349 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2350 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in tb_test_credit_alloc_dma_multiple()
2364 path = tunnel3->paths[0]; in tb_test_credit_alloc_dma_multiple()
2365 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2366 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2367 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2368 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2369 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2371 path = tunnel3->paths[1]; in tb_test_credit_alloc_dma_multiple()
2372 KUNIT_ASSERT_EQ(test, path->path_length, 2); in tb_test_credit_alloc_dma_multiple()
2373 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2374 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2375 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in tb_test_credit_alloc_dma_multiple()
2376 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in tb_test_credit_alloc_dma_multiple()
2387 struct tb_path *path; in TB_TEST_PCIE_TUNNEL() local
2395 path = pcie_tunnel->paths[0]; in TB_TEST_PCIE_TUNNEL()
2396 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_PCIE_TUNNEL()
2397 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_PCIE_TUNNEL()
2398 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in TB_TEST_PCIE_TUNNEL()
2399 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_PCIE_TUNNEL()
2400 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in TB_TEST_PCIE_TUNNEL()
2402 path = pcie_tunnel->paths[1]; in TB_TEST_PCIE_TUNNEL()
2403 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_PCIE_TUNNEL()
2404 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_PCIE_TUNNEL()
2405 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in TB_TEST_PCIE_TUNNEL()
2406 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_PCIE_TUNNEL()
2407 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 64U); in TB_TEST_PCIE_TUNNEL()
2417 struct tb_path *path; in TB_TEST_DP_TUNNEL1() local
2425 path = dp_tunnel1->paths[0]; in TB_TEST_DP_TUNNEL1()
2426 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL1()
2427 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 12U); in TB_TEST_DP_TUNNEL1()
2428 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in TB_TEST_DP_TUNNEL1()
2429 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 18U); in TB_TEST_DP_TUNNEL1()
2430 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 0U); in TB_TEST_DP_TUNNEL1()
2432 path = dp_tunnel1->paths[1]; in TB_TEST_DP_TUNNEL1()
2433 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL1()
2434 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DP_TUNNEL1()
2435 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in TB_TEST_DP_TUNNEL1()
2436 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DP_TUNNEL1()
2437 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DP_TUNNEL1()
2439 path = dp_tunnel1->paths[2]; in TB_TEST_DP_TUNNEL1()
2440 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL1()
2441 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DP_TUNNEL1()
2442 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in TB_TEST_DP_TUNNEL1()
2443 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DP_TUNNEL1()
2444 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DP_TUNNEL1()
2454 struct tb_path *path; in TB_TEST_DP_TUNNEL2() local
2462 path = dp_tunnel2->paths[0]; in TB_TEST_DP_TUNNEL2()
2463 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL2()
2464 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 12U); in TB_TEST_DP_TUNNEL2()
2465 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in TB_TEST_DP_TUNNEL2()
2466 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 18U); in TB_TEST_DP_TUNNEL2()
2467 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 0U); in TB_TEST_DP_TUNNEL2()
2469 path = dp_tunnel2->paths[1]; in TB_TEST_DP_TUNNEL2()
2470 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL2()
2471 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DP_TUNNEL2()
2472 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in TB_TEST_DP_TUNNEL2()
2473 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DP_TUNNEL2()
2474 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DP_TUNNEL2()
2476 path = dp_tunnel2->paths[2]; in TB_TEST_DP_TUNNEL2()
2477 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DP_TUNNEL2()
2478 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DP_TUNNEL2()
2479 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 1U); in TB_TEST_DP_TUNNEL2()
2480 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DP_TUNNEL2()
2481 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DP_TUNNEL2()
2491 struct tb_path *path; in TB_TEST_USB3_TUNNEL() local
2499 path = usb3_tunnel->paths[0]; in TB_TEST_USB3_TUNNEL()
2500 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_USB3_TUNNEL()
2501 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_USB3_TUNNEL()
2502 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in TB_TEST_USB3_TUNNEL()
2503 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_USB3_TUNNEL()
2504 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in TB_TEST_USB3_TUNNEL()
2506 path = usb3_tunnel->paths[1]; in TB_TEST_USB3_TUNNEL()
2507 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_USB3_TUNNEL()
2508 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_USB3_TUNNEL()
2509 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 7U); in TB_TEST_USB3_TUNNEL()
2510 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_USB3_TUNNEL()
2511 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 32U); in TB_TEST_USB3_TUNNEL()
2521 struct tb_path *path; in TB_TEST_DMA_TUNNEL1() local
2529 path = dma_tunnel1->paths[0]; in TB_TEST_DMA_TUNNEL1()
2530 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DMA_TUNNEL1()
2531 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL1()
2532 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in TB_TEST_DMA_TUNNEL1()
2533 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL1()
2534 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in TB_TEST_DMA_TUNNEL1()
2536 path = dma_tunnel1->paths[1]; in TB_TEST_DMA_TUNNEL1()
2537 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DMA_TUNNEL1()
2538 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL1()
2539 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in TB_TEST_DMA_TUNNEL1()
2540 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL1()
2541 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 14U); in TB_TEST_DMA_TUNNEL1()
2551 struct tb_path *path; in TB_TEST_DMA_TUNNEL2() local
2559 path = dma_tunnel2->paths[0]; in TB_TEST_DMA_TUNNEL2()
2560 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DMA_TUNNEL2()
2561 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL2()
2562 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 14U); in TB_TEST_DMA_TUNNEL2()
2563 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL2()
2564 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DMA_TUNNEL2()
2566 path = dma_tunnel2->paths[1]; in TB_TEST_DMA_TUNNEL2()
2567 KUNIT_ASSERT_EQ(test, path->path_length, 2); in TB_TEST_DMA_TUNNEL2()
2568 KUNIT_EXPECT_EQ(test, path->hops[0].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL2()
2569 KUNIT_EXPECT_EQ(test, path->hops[0].initial_credits, 0U); in TB_TEST_DMA_TUNNEL2()
2570 KUNIT_EXPECT_EQ(test, path->hops[1].nfc_credits, 0U); in TB_TEST_DMA_TUNNEL2()
2571 KUNIT_EXPECT_EQ(test, path->hops[1].initial_credits, 1U); in TB_TEST_DMA_TUNNEL2()