Lines Matching defs:link
23 struct bpf_link *link;
41 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
42 if (!ASSERT_OK_PTR(link, "link_attach"))
45 skel->links.tc1 = link;
76 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
77 if (!ASSERT_OK_PTR(link, "link_attach"))
80 skel->links.tc2 = link;
123 struct bpf_link *link;
154 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
155 if (!ASSERT_OK_PTR(link, "link_attach"))
158 skel->links.tc1 = link;
164 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
165 if (!ASSERT_OK_PTR(link, "link_attach"))
168 skel->links.tc2 = link;
207 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
208 if (!ASSERT_OK_PTR(link, "link_attach"))
211 skel->links.tc3 = link;
220 link = bpf_program__attach_tcx(skel->progs.tc4, loopback, &optl);
221 if (!ASSERT_OK_PTR(link, "link_attach"))
224 skel->links.tc4 = link;
277 struct bpf_link *link;
308 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
309 if (!ASSERT_OK_PTR(link, "link_attach"))
312 skel->links.tc1 = link;
318 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
319 if (!ASSERT_OK_PTR(link, "link_attach"))
322 skel->links.tc2 = link;
361 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
362 if (!ASSERT_OK_PTR(link, "link_attach"))
365 skel->links.tc3 = link;
374 link = bpf_program__attach_tcx(skel->progs.tc4, loopback, &optl);
375 if (!ASSERT_OK_PTR(link, "link_attach"))
378 skel->links.tc4 = link;
430 struct bpf_link *link;
455 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
456 if (!ASSERT_OK_PTR(link, "link_attach"))
459 skel->links.tc1 = link;
467 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
468 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
469 bpf_link__destroy(link);
477 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
478 if (!ASSERT_OK_PTR(link, "link_attach"))
481 skel->links.tc2 = link;
531 struct bpf_link *link;
573 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
574 if (!ASSERT_OK_PTR(link, "link_attach"))
577 skel->links.tc1 = link;
579 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
580 if (!ASSERT_OK_PTR(link, "link_attach"))
583 skel->links.tc2 = link;
636 struct bpf_link *link;
665 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
666 if (!ASSERT_OK_PTR(link, "link_attach"))
669 skel->links.tc1 = link;
681 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
682 if (!ASSERT_OK_PTR(link, "link_attach"))
685 skel->links.tc2 = link;
724 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
725 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
726 bpf_link__destroy(link);
738 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
739 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
740 bpf_link__destroy(link);
751 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
752 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
753 bpf_link__destroy(link);
861 struct bpf_link *link;
886 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
887 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
888 bpf_link__destroy(link);
898 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
899 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
900 bpf_link__destroy(link);
910 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
911 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
912 bpf_link__destroy(link);
922 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
923 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
924 bpf_link__destroy(link);
935 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
936 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
937 bpf_link__destroy(link);
947 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
948 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
949 bpf_link__destroy(link);
959 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
960 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
961 bpf_link__destroy(link);
972 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
973 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
974 bpf_link__destroy(link);
985 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
986 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
987 bpf_link__destroy(link);
998 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
999 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1000 bpf_link__destroy(link);
1011 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1012 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1013 bpf_link__destroy(link);
1024 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1025 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1026 bpf_link__destroy(link);
1037 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1038 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1039 bpf_link__destroy(link);
1050 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1051 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1052 bpf_link__destroy(link);
1060 link = bpf_program__attach_tcx(skel->progs.tc1, 0, &optl);
1061 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1062 bpf_link__destroy(link);
1073 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1074 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1075 bpf_link__destroy(link);
1083 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1084 if (!ASSERT_OK_PTR(link, "link_attach"))
1087 skel->links.tc1 = link;
1098 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1099 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1100 bpf_link__destroy(link);
1111 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1112 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1113 bpf_link__destroy(link);
1124 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1125 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1126 bpf_link__destroy(link);
1137 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1138 if (!ASSERT_ERR_PTR(link, "link_attach_should_fail")) {
1139 bpf_link__destroy(link);
1149 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1150 if (!ASSERT_OK_PTR(link, "link_attach"))
1153 skel->links.tc2 = link;
1175 struct bpf_link *link;
1206 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1207 if (!ASSERT_OK_PTR(link, "link_attach"))
1210 skel->links.tc1 = link;
1220 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1221 if (!ASSERT_OK_PTR(link, "link_attach"))
1224 skel->links.tc2 = link;
1262 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
1263 if (!ASSERT_OK_PTR(link, "link_attach"))
1266 skel->links.tc3 = link;
1274 link = bpf_program__attach_tcx(skel->progs.tc4, loopback, &optl);
1275 if (!ASSERT_OK_PTR(link, "link_attach"))
1278 skel->links.tc4 = link;
1331 struct bpf_link *link;
1362 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1363 if (!ASSERT_OK_PTR(link, "link_attach"))
1366 skel->links.tc1 = link;
1376 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1377 if (!ASSERT_OK_PTR(link, "link_attach"))
1380 skel->links.tc2 = link;
1418 link = bpf_program__attach_tcx(skel->progs.tc3, loopback, &optl);
1419 if (!ASSERT_OK_PTR(link, "link_attach"))
1422 skel->links.tc3 = link;
1430 link = bpf_program__attach_tcx(skel->progs.tc4, loopback, &optl);
1431 if (!ASSERT_OK_PTR(link, "link_attach"))
1434 skel->links.tc4 = link;
1485 struct bpf_link *link;
1488 ASSERT_OK(system("ip link add dev tcx_opts1 type veth peer name tcx_opts2"), "add veth");
1520 link = bpf_program__attach_tcx(skel->progs.tc1, ifindex, &optl);
1521 if (!ASSERT_OK_PTR(link, "link_attach"))
1524 skel->links.tc1 = link;
1528 link = bpf_program__attach_tcx(skel->progs.tc2, ifindex, &optl);
1529 if (!ASSERT_OK_PTR(link, "link_attach"))
1532 skel->links.tc2 = link;
1536 link = bpf_program__attach_tcx(skel->progs.tc3, ifindex, &optl);
1537 if (!ASSERT_OK_PTR(link, "link_attach"))
1540 skel->links.tc3 = link;
1544 link = bpf_program__attach_tcx(skel->progs.tc4, ifindex, &optl);
1545 if (!ASSERT_OK_PTR(link, "link_attach"))
1548 skel->links.tc4 = link;
1552 ASSERT_OK(system("ip link del dev tcx_opts1"), "del veth");
1566 ASSERT_OK(system("ip link del dev tcx_opts1"), "del veth");
1583 struct bpf_link *link;
1623 link = bpf_program__attach_tcx(skel->progs.tc6, loopback, &optl);
1624 if (!ASSERT_OK_PTR(link, "link_attach"))
1627 skel->links.tc6 = link;
1697 struct bpf_link *link;
1733 link = bpf_program__attach_tcx(skel->progs.tc1, loopback, &optl);
1734 if (!ASSERT_OK_PTR(link, "link_attach"))
1737 skel->links.tc1 = link;
1739 link = bpf_program__attach_tcx(skel->progs.tc2, loopback, &optl);
1740 if (!ASSERT_OK_PTR(link, "link_attach"))
1743 skel->links.tc2 = link;
1830 ASSERT_OK(system("ip link add dev foo type veth peer name bar"), "add veth");
1846 ASSERT_OK(system("ip link del dev foo"), "del veth");
1858 struct bpf_link *link;
1861 ASSERT_OK(system("ip link add dev tcx_opts1 type veth peer name tcx_opts2"), "add veth");
1893 link = bpf_program__attach_tcx(skel->progs.tc1, ifindex, &optl);
1894 if (!ASSERT_OK_PTR(link, "link_attach"))
1897 skel->links.tc1 = link;
1901 link = bpf_program__attach_tcx(skel->progs.tc2, ifindex, &optl);
1902 if (!ASSERT_OK_PTR(link, "link_attach"))
1905 skel->links.tc2 = link;
1909 link = bpf_program__attach_tcx(skel->progs.tc3, ifindex, &optl);
1910 if (!ASSERT_OK_PTR(link, "link_attach"))
1913 skel->links.tc3 = link;
1917 link = bpf_program__attach_tcx(skel->progs.tc4, ifindex, &optl);
1918 if (!ASSERT_OK_PTR(link, "link_attach"))
1921 skel->links.tc4 = link;
1939 ASSERT_OK(system("ip link del dev tcx_opts1"), "del veth");
1953 ASSERT_OK(system("ip link del dev tcx_opts1"), "del veth");