/external/linux-kselftest/tools/testing/selftests/bpf/progs/ |
D | kfree_skb.c | 28 int ifindex; member 52 int ifindex; member 84 meta.ifindex = _(dev->ifindex); 99 meta.ifindex, data, pkt_data); 102 if (users != 1 || pkt_data != bpf_htons(0x86dd) || meta.ifindex != 1) 121 int len, ifindex; variable 125 ifindex = dev->ifindex; 129 if (len != 74 || ifindex != 1) 139 int len, ifindex; variable 143 ifindex = dev->ifindex; [all …]
|
/external/strace/ |
D | print_ifindex.c | 39 get_ifname(const unsigned int ifindex) in get_ifname() argument 44 if (!if_indextoname(ifindex, name_buf)) in get_ifname() 56 sprint_ifname(const unsigned int ifindex) in sprint_ifname() argument 60 const char *name_quoted = get_ifname(ifindex); in sprint_ifname() 72 const char *get_ifname(const unsigned int ifindex) { return NULL; } in get_ifname() argument 77 print_ifindex(const unsigned int ifindex) in print_ifindex() argument 80 print_xlat_ex(ifindex, sprint_ifname(ifindex), XLAT_STYLE_FMT_U); in print_ifindex() 82 tprintf("%u", ifindex); in print_ifindex()
|
D | rtnl_mdb.c | 70 PRINT_FIELD_IFINDEX("{", entry, ifindex); in decode_mdba_mdb_entry_info() 164 uint32_t ifindex; in decode_mdba_router_port() local 166 if (len < sizeof(ifindex)) in decode_mdba_router_port() 168 else if (!umove_or_printaddr(tcp, addr, &ifindex)) in decode_mdba_router_port() 169 print_ifindex(ifindex); in decode_mdba_router_port() 171 const size_t offset = NLMSG_ALIGN(sizeof(ifindex)); in decode_mdba_router_port() 219 PRINT_FIELD_IFINDEX("", bpm, ifindex); in DECL_NETLINK_ROUTE_DECODER()
|
/external/iputils/ninfod/ |
D | ninfod_addrs.c | 155 unsigned int ifindex = 0; in pr_nodeinfo_ipv6addr() local 177 if (!ifindex && in pr_nodeinfo_ipv6addr() 185 ifindex = p->pktinfo.ipi6_ifindex; in pr_nodeinfo_ipv6addr() 196 if (!ifindex || in pr_nodeinfo_ipv6addr() 197 (p->pktinfo.ipi6_ifindex == ifindex)) in pr_nodeinfo_ipv6addr() 198 ifindex = ifa->ifa_ifindex; in pr_nodeinfo_ipv6addr() 201 if (!ifindex) { in pr_nodeinfo_ipv6addr() 206 *subj_if = ifindex; in pr_nodeinfo_ipv6addr() 208 ifindex = subj_if ? *subj_if : 0; in pr_nodeinfo_ipv6addr() 209 if (ifindex == 0) in pr_nodeinfo_ipv6addr() [all …]
|
/external/iproute2/ip/ |
D | ipnetconf.c | 30 int ifindex; member 59 int ifindex = 0; in print_netconf() local 82 ifindex = rta_getattr_u32(tb[NETCONFA_IFINDEX]); in print_netconf() 84 if (filter.ifindex && filter.ifindex != ifindex) in print_netconf() 103 switch (ifindex) { in print_netconf() 111 fprintf(fp, "dev %s ", ll_index_to_name(ifindex)); in print_netconf() 157 void ipnetconf_reset_filter(int ifindex) in ipnetconf_reset_filter() argument 160 filter.ifindex = ifindex; in ipnetconf_reset_filter() 181 filter.ifindex = ll_name_to_index(*argv); in do_show() 182 if (filter.ifindex <= 0) { in do_show() [all …]
|
D | iplink_hsr.c | 49 int ifindex; in hsr_parse_opt() local 69 ifindex = ll_name_to_index(*argv); in hsr_parse_opt() 70 if (ifindex == 0) in hsr_parse_opt() 72 addattr_l(n, 1024, IFLA_HSR_SLAVE1, &ifindex, 4); in hsr_parse_opt() 75 ifindex = ll_name_to_index(*argv); in hsr_parse_opt() 76 if (ifindex == 0) in hsr_parse_opt() 78 addattr_l(n, 1024, IFLA_HSR_SLAVE2, &ifindex, 4); in hsr_parse_opt()
|
D | ipmacsec.c | 55 int ifindex; member 65 int ifindex; member 374 static int do_modify_nl(enum cmd c, enum macsec_nl_commands cmd, int ifindex, in do_modify_nl() argument 381 addattr32(&req.n, MACSEC_BUFLEN, MACSEC_ATTR_IFINDEX, ifindex); in do_modify_nl() 452 static int do_modify_txsa(enum cmd c, int argc, char **argv, int ifindex) in do_modify_txsa() argument 474 return do_modify_nl(c, cmd, ifindex, NULL, &txsa); in do_modify_txsa() 477 static int do_modify_rxsci(enum cmd c, int argc, char **argv, int ifindex) in do_modify_rxsci() argument 484 rxsc.ifindex = ifindex; in do_modify_rxsci() 502 return do_modify_nl(c, cmd, rxsc.ifindex, &rxsc, &rxsa); in do_modify_rxsci() 507 int ifindex; in do_modify() local [all …]
|
/external/libnl/python/netlink/route/ |
D | tc.py | 92 diff = self.ifindex - other.ifindex 107 def ifindex(self): member in Tc 111 @ifindex.setter 112 def ifindex(self, value): member in Tc 197 return buf + util.num(self.ifindex) 291 ret += get_cls(self.ifindex, parent=self.handle) 294 ret += get_class(self.ifindex, parent=TC_H_ROOT) 296 ret += get_class(self.ifindex, parent=self.handle) 396 def __init__(self, ifindex, cache=None): argument 402 self._set_arg1(ifindex) [all …]
|
/external/strace/tests-mx32/ |
D | nlattr_mdba_router_port.c | 65 .ifindex = ifindex_lo() in init_br_port_msg() 90 const uint32_t ifindex = ifindex_lo(); in main() local 96 char buf[NLMSG_ALIGN(ifindex) + NLA_HDRLEN + sizeof(type)]; in main() 108 MDBA_ROUTER_PORT, pattern, ifindex, in main() 111 memcpy(buf, &ifindex, sizeof(ifindex)); in main() 112 memcpy(buf + NLMSG_ALIGN(ifindex), &nla, sizeof(nla)); in main() 113 memcpy(buf + NLMSG_ALIGN(ifindex) + NLA_HDRLEN, &type, sizeof(type)); in main()
|
/external/strace/tests-m32/ |
D | nlattr_mdba_router_port.c | 65 .ifindex = ifindex_lo() in init_br_port_msg() 90 const uint32_t ifindex = ifindex_lo(); in main() local 96 char buf[NLMSG_ALIGN(ifindex) + NLA_HDRLEN + sizeof(type)]; in main() 108 MDBA_ROUTER_PORT, pattern, ifindex, in main() 111 memcpy(buf, &ifindex, sizeof(ifindex)); in main() 112 memcpy(buf + NLMSG_ALIGN(ifindex), &nla, sizeof(nla)); in main() 113 memcpy(buf + NLMSG_ALIGN(ifindex) + NLA_HDRLEN, &type, sizeof(type)); in main()
|
/external/strace/tests/ |
D | nlattr_mdba_router_port.c | 65 .ifindex = ifindex_lo() in init_br_port_msg() 90 const uint32_t ifindex = ifindex_lo(); in main() local 96 char buf[NLMSG_ALIGN(ifindex) + NLA_HDRLEN + sizeof(type)]; in main() 108 MDBA_ROUTER_PORT, pattern, ifindex, in main() 111 memcpy(buf, &ifindex, sizeof(ifindex)); in main() 112 memcpy(buf + NLMSG_ALIGN(ifindex), &nla, sizeof(nla)); in main() 113 memcpy(buf + NLMSG_ALIGN(ifindex) + NLA_HDRLEN, &type, sizeof(type)); in main()
|
/external/bcc/examples/networking/distributed_bridge/ |
D | tunnel_mesh.c | 27 int *ifindex = tunkey2if.lookup(&key); in handle_ingress() local 28 if (ifindex) { in handle_ingress() 33 bpf_clone_redirect(skb, *ifindex, 1/*ingress*/); in handle_ingress() 43 int ifindex = skb->ifindex; in handle_egress() local 57 key_p = if2tunkey.lookup(&ifindex); in handle_egress()
|
D | tunnel.c | 9 int ifindex; member 35 int *ifindex = vni2if.lookup(&tkey.tunnel_id); in handle_ingress() local 36 if (ifindex) { in handle_ingress() 38 struct vni_key vk = {ethernet->src, *ifindex, 0}; in handle_ingress() 42 bpf_clone_redirect(skb, *ifindex, 1/*ingress*/); in handle_ingress() 60 struct vni_key vk = {ethernet->dst, skb->ifindex, 0}; in handle_egress()
|
/external/linux-kselftest/tools/testing/selftests/net/ |
D | nettest.c | 76 int ifindex; member 317 int ifindex = 0; in check_device() local 323 ifindex = get_ifidx(name); in check_device() 326 *name ? name : "<none>", ifindex); in check_device() 331 if (args->expected_ifindex != ifindex) { in check_device() 333 args->expected_ifindex, ifindex); in check_device() 338 args->expected_ifindex, ifindex); in check_device() 391 static int set_unicast_if(int sd, int ifindex, int version) in set_unicast_if() argument 397 ifindex = htonl(ifindex); in set_unicast_if() 403 rc = setsockopt(sd, level, opt, &ifindex, sizeof(ifindex)); in set_unicast_if() [all …]
|
/external/libnl/src/ |
D | nl-tctree-list.c | 27 static int ifindex; variable 60 if (rtnl_cls_alloc_cache(sock, ifindex, parent, &cls_cache) < 0) in print_class() 93 if (rtnl_cls_alloc_cache(sock, ifindex, parent, &cls_cache) < 0) in print_qdisc() 106 ifindex = rtnl_link_get_ifindex(link); in print_link() 110 if (rtnl_class_alloc_cache(sock, ifindex, &class_cache) < 0) in print_link() 113 qdisc = rtnl_qdisc_get_by_parent(qdisc_cache, ifindex, TC_H_ROOT); in print_link() 119 qdisc = rtnl_qdisc_get_by_parent(qdisc_cache, ifindex, 0); in print_link() 125 qdisc = rtnl_qdisc_get_by_parent(qdisc_cache, ifindex, TC_H_INGRESS); in print_link()
|
D | nl-qdisc-list.c | 56 static void list_classes(int ifindex, uint32_t parent); 57 static void list_qdiscs(int ifindex, uint32_t parent); 68 static void list_classes(int ifindex, uint32_t parent) in list_classes() argument 73 class_cache = nl_cli_class_alloc_cache(sock, ifindex); in list_classes() 84 static void list_cls(int ifindex, uint32_t parent) in list_cls() argument 88 cls_cache = nl_cli_cls_alloc_cache(sock, ifindex, parent); in list_cls() 114 static void list_qdiscs(int ifindex, uint32_t parent) in list_qdiscs() argument 121 rtnl_tc_set_ifindex((struct rtnl_tc *) filter, ifindex); in list_qdiscs()
|
D | nl-class-list.c | 50 static void __dump_class(int ifindex, struct rtnl_class *filter) in __dump_class() argument 54 cache = nl_cli_class_alloc_cache(sock, ifindex); in __dump_class() 70 int ifindex; in main() local 114 if ((ifindex = rtnl_tc_get_ifindex(tc))) in main() 115 __dump_class(ifindex, class); in main()
|
D | nl-link-ifindex2name.c | 29 uint32_t ifindex; in main() local 38 ifindex = nl_cli_parse_u32(argv[1]); in main() 40 if (!rtnl_link_i2name(link_cache, ifindex, name, sizeof(name))) in main() 42 ifindex); in main()
|
D | nl-cls-list.c | 52 static void __dump_link(int ifindex, struct rtnl_cls *filter) in __dump_link() argument 57 cache = nl_cli_cls_alloc_cache(sock, ifindex, parent); in __dump_link() 74 int ifindex; in main() local 126 if ((ifindex = rtnl_tc_get_ifindex(tc))) in main() 127 __dump_link(ifindex, cls); in main()
|
/external/bcc/tests/python/ |
D | test_xlate1.py | 24 ifindex = ip.link_lookup(ifname="eth0")[0] 28 ip.addr("del", index=ifindex, address="172.16.1.2", mask=24) 29 ip.addr("add", index=ifindex, address="192.168.1.2", mask=24) 31 ip.tc("add", "ingress", ifindex, "ffff:") 32 ip.tc("add", "sfq", ifindex, "1:") 35 ip.tc("add-filter", "u32", ifindex, ":1", parent="ffff:", action=[action], 37 ip.tc("add-filter", "u32", ifindex, ":2", parent="1:", action=[action],
|
/external/iproute2/bridge/ |
D | mdb.c | 131 static void print_mdb_entry(FILE *f, int ifindex, struct br_mdb_entry *e, in print_mdb_entry() argument 153 jsonw_string_field(jw_global, "dev", ll_index_to_name(ifindex)); in print_mdb_entry() 156 ll_index_to_name(e->ifindex)); in print_mdb_entry() 169 ll_index_to_name(ifindex), in print_mdb_entry() 170 ll_index_to_name(e->ifindex), in print_mdb_entry() 203 static void br_print_mdb_entry(FILE *f, int ifindex, struct rtattr *attr, in br_print_mdb_entry() argument 216 print_mdb_entry(f, ifindex, e, n, etb); in br_print_mdb_entry() 240 if (filter_index && filter_index != r->ifindex) in print_mdb() 249 br_print_mdb_entry(fp, r->ifindex, i, n); in print_mdb() 256 r->ifindex); in print_mdb() [all …]
|
/external/libnl/lib/route/ |
D | netconf.c | 44 int ifindex; member 136 nc->ifindex = nla_get_s32(tb[NETCONFA_IFINDEX]); in netconf_msg_parser() 212 switch(nc->ifindex) { in netconf_dump_line() 223 rtnl_link_i2name(link_cache, nc->ifindex, in netconf_dump_line() 227 nl_dump(p, "dev %d ", nc->ifindex); in netconf_dump_line() 267 __ADD(NETCONF_ATTR_IFINDEX, ifindex), 294 nckey.nc_index = nc->ifindex; in netconf_keygen() 312 diff |= NETCONF_DIFF(IFINDEX, a->ifindex != b->ifindex); in netconf_compare() 335 new_nc->ifindex != old_nc->ifindex) in netconf_update() 383 int ifindex) in rtnl_netconf_get_by_idx() argument [all …]
|
/external/libnl/lib/xfrm/ |
D | selector.c | 171 (a->ifindex && a->ifindex != b->ifindex) || in xfrmnl_sel_cmp() 189 nl_ip_proto2str (sel->proto, buf, sizeof(buf)), sel->ifindex, sel->user); in xfrmnl_sel_dump() 331 return sel->ifindex; in xfrmnl_sel_get_ifindex() 334 int xfrmnl_sel_set_ifindex (struct xfrmnl_sel* sel, unsigned int ifindex) in xfrmnl_sel_set_ifindex() argument 336 sel->ifindex = ifindex; in xfrmnl_sel_set_ifindex()
|
/external/wpa_supplicant_8/src/drivers/ |
D | linux_ioctl.c | 153 int ifindex; in linux_br_add_if() local 155 ifindex = if_nametoindex(ifname); in linux_br_add_if() 156 if (ifindex == 0) in linux_br_add_if() 161 ifr.ifr_ifindex = ifindex; in linux_br_add_if() 178 int ifindex; in linux_br_del_if() local 180 ifindex = if_nametoindex(ifname); in linux_br_del_if() 181 if (ifindex == 0) in linux_br_del_if() 186 ifr.ifr_ifindex = ifindex; in linux_br_del_if()
|
/external/android-clat/ |
D | setif.c | 138 static int do_anycast_setsockopt(int sock, int what, struct in6_addr *addr, int ifindex) { in do_anycast_setsockopt() argument 139 struct ipv6_mreq mreq = { *addr, ifindex }; in do_anycast_setsockopt() 166 int ifindex; in add_anycast_address() local 168 ifindex = if_nametoindex(ifname); in add_anycast_address() 169 if (!ifindex) { in add_anycast_address() 174 return do_anycast_setsockopt(sock, IPV6_JOIN_ANYCAST, addr, ifindex); in add_anycast_address()
|