Home
last modified time | relevance | path

Searched refs:ifname (Results 1 – 25 of 286) sorted by relevance

12345678910>>...12

/external/ltp/testcases/network/stress/ns-tools/
Dinitialize_if70 ifname=`get_ifname $host_type $link_num` || exit 1
73 command="ifconfig $ifname down mtu 1500 ; ip route flush dev $ifname ; ip addr flush dev $ifname ; …
76 ( ifconfig $ifname down && \
77 ip link set mtu 1500 dev $ifname && \
78 ip route flush dev $ifname && \
79 ip addr flush dev $ifname && \
80 ifconfig $ifname up ) >/dev/null 2>&1
83 …config '$ifname' down && ip link set mtu 1500 dev '$ifname' && ip route flush dev '$ifname' && ip …
87 echo "Failed to initialize $ifname" >&2
Dadd_ipv6addr81 ifname=`get_ifname $host_type $link_num` || exit 1
84 ifconfig ${ifname} up ; ifconfig ${ifname} add ${addr}/${netmask}
87 …$LTP_RSH $RHOST '( PATH=/sbin:/usr/sbin:$PATH ; ifconfig '${ifname}' up && ifconfig '${ifname}' ad…
91 echo "Cannot assign $addr to $ifname" >&2
Dset_ipv4addr82 ifname=`get_ifname $host_type $link_num` || exit 1
85 ifconfig $ifname up
86 ifconfig $ifname $addr netmask $netmask broadcast $broadcast
89 …ret=`$LTP_RSH $RHOST '( PATH=/sbin:/usr/sbin:$PATH ; ifconfig '$ifname' up && ifconfig '$ifname $a…
93 echo "Cannot set $addr to $ifname" >&2
/external/wpa_supplicant_8/src/common/
Dwpa_helpers.c22 static struct wpa_ctrl * wpa_open_ctrl(const char *ifname) in wpa_open_ctrl() argument
27 os_snprintf(buf, sizeof(buf), "%s%s", wpas_ctrl_path, ifname); in wpa_open_ctrl()
35 int wpa_command(const char *ifname, const char *cmd) in wpa_command() argument
41 printf("wpa_command(ifname='%s', cmd='%s')\n", ifname, cmd); in wpa_command()
42 ctrl = wpa_open_ctrl(ifname); in wpa_command()
61 int wpa_command_resp(const char *ifname, const char *cmd, in wpa_command_resp() argument
67 printf("wpa_command(ifname='%s', cmd='%s')\n", ifname, cmd); in wpa_command_resp()
68 ctrl = wpa_open_ctrl(ifname); in wpa_command_resp()
83 struct wpa_ctrl * open_wpa_mon(const char *ifname) in open_wpa_mon() argument
87 ctrl = wpa_open_ctrl(ifname); in open_wpa_mon()
[all …]
Dwpa_helpers.h13 int wpa_command(const char *ifname, const char *cmd);
14 int wpa_command_resp(const char *ifname, const char *cmd,
16 int get_wpa_status(const char *ifname, const char *field, char *obuf,
19 struct wpa_ctrl * open_wpa_mon(const char *ifname);
20 int wait_ip_addr(const char *ifname, int timeout);
27 int add_network(const char *ifname);
28 int set_network(const char *ifname, int id, const char *field,
30 int set_network_quoted(const char *ifname, int id, const char *field,
32 int add_cred(const char *ifname);
33 int set_cred(const char *ifname, int id, const char *field, const char *value);
[all …]
/external/wpa_supplicant_8/src/ap/
Dvlan_init.c34 vlan->ifname); in vlan_if_add()
39 if (!iface_exists(vlan->ifname)) in vlan_if_add()
40 ret = hostapd_vlan_if_add(hapd, vlan->ifname); in vlan_if_add()
49 ifconfig_up(vlan->ifname); /* else wpa group will fail fatal */ in vlan_if_add()
60 wpa_printf(MSG_ERROR, "WPA deinit of %s failed", vlan->ifname); in vlan_if_add()
63 if (hostapd_vlan_if_remove(hapd, vlan->ifname)) in vlan_if_add()
64 wpa_printf(MSG_ERROR, "Removal of %s failed", vlan->ifname); in vlan_if_add()
80 return hostapd_vlan_if_remove(hapd, vlan->ifname); in vlan_if_remove()
92 vlan->ifname, strerror(errno)); in vlan_dynamic_add()
96 vlan_newlink(vlan->ifname, hapd); in vlan_dynamic_add()
[all …]
Dvlan_full.c40 char ifname[IFNAMSIZ + 1]; member
50 static void dyn_iface_get(struct hostapd_data *hapd, const char *ifname, in dyn_iface_get() argument
60 if (os_strcmp(ifname, next->ifname) == 0) in dyn_iface_get()
76 os_strlcpy(next->ifname, ifname, sizeof(next->ifname)); in dyn_iface_get()
87 static int dyn_iface_put(struct hostapd_data *hapd, const char *ifname) in dyn_iface_put() argument
97 if (os_strcmp(ifname, next->ifname) == 0) in dyn_iface_put()
461 void vlan_newlink(const char *ifname, struct hostapd_data *hapd) in vlan_newlink() argument
467 wpa_printf(MSG_DEBUG, "VLAN: vlan_newlink(%s)", ifname); in vlan_newlink()
471 os_strcmp(ifname, vlan->ifname) != 0) in vlan_newlink()
487 !br_addif(hapd->conf->bridge, ifname)) in vlan_newlink()
[all …]
/external/wpa_supplicant_8/wpa_supplicant/hidl/1.4/
Dhidl_manager.cpp57 const std::string &ifname, int network_id) in getNetworkObjectMapKey() argument
59 return ifname + "_" + std::to_string(network_id); in getNetworkObjectMapKey()
114 const std::string &ifname, const android::sp<CallbackType> &callback, in addIfaceCallbackHidlObjectToMap() argument
118 if (ifname.empty()) in addIfaceCallbackHidlObjectToMap()
121 auto iface_callback_map_iter = callbacks_map.find(ifname); in addIfaceCallbackHidlObjectToMap()
134 const std::string &ifname, int network_id, in addNetworkCallbackHidlObjectToMap() argument
139 if (ifname.empty() || network_id < 0) in addNetworkCallbackHidlObjectToMap()
144 getNetworkObjectMapKey(ifname, network_id); in addNetworkCallbackHidlObjectToMap()
158 const std::string &ifname, in removeAllIfaceCallbackHidlObjectsFromMap() argument
162 auto iface_callback_map_iter = callbacks_map.find(ifname); in removeAllIfaceCallbackHidlObjectsFromMap()
[all …]
/external/wpa_supplicant_8/src/drivers/
Dlinux_ioctl.c19 int linux_set_iface_flags(int sock, const char *ifname, int dev_up) in linux_set_iface_flags() argument
28 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in linux_set_iface_flags()
33 ifname, strerror(errno)); in linux_set_iface_flags()
51 ifname, dev_up ? "UP" : "DOWN", strerror(errno)); in linux_set_iface_flags()
59 int linux_iface_up(int sock, const char *ifname) in linux_iface_up() argument
68 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in linux_iface_up()
73 ifname, strerror(errno)); in linux_iface_up()
81 int linux_get_ifhwaddr(int sock, const char *ifname, u8 *addr) in linux_get_ifhwaddr() argument
86 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in linux_get_ifhwaddr()
89 ifname, strerror(errno)); in linux_get_ifhwaddr()
[all …]
Ddriver_wired_common.c33 static int driver_wired_get_ifflags(const char *ifname, int *flags) in driver_wired_get_ifflags() argument
45 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in driver_wired_get_ifflags()
58 static int driver_wired_set_ifflags(const char *ifname, int flags) in driver_wired_set_ifflags() argument
70 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in driver_wired_set_ifflags()
83 static int driver_wired_multi(const char *ifname, const u8 *addr, int add) in driver_wired_multi() argument
99 os_strlcpy(ifr.ifr_name, ifname, IFNAMSIZ); in driver_wired_multi()
191 static int driver_wired_get_ifstatus(const char *ifname, int *status) in driver_wired_get_ifstatus() argument
203 os_strlcpy(ifmr.ifm_name, ifname, IFNAMSIZ); in driver_wired_get_ifstatus()
220 const char *ifname, void *ctx) in driver_wired_init_common() argument
224 os_strlcpy(common->ifname, ifname, sizeof(common->ifname)); in driver_wired_init_common()
[all …]
Dlinux_ioctl.h12 int linux_set_iface_flags(int sock, const char *ifname, int dev_up);
13 int linux_iface_up(int sock, const char *ifname);
14 int linux_get_ifhwaddr(int sock, const char *ifname, u8 *addr);
15 int linux_set_ifhwaddr(int sock, const char *ifname, const u8 *addr);
18 int linux_br_add_if(int sock, const char *brname, const char *ifname);
19 int linux_br_del_if(int sock, const char *brname, const char *ifname);
20 int linux_br_get(char *brname, const char *ifname);
21 int linux_master_get(char *master_ifname, const char *ifname);
Ddriver_openbsd.c21 char ifname[IFNAMSIZ + 1]; member
36 os_strlcpy(ifr.ifr_name, drv->ifname, sizeof(ifr.ifr_name)); in wpa_driver_openbsd_get_ssid()
52 os_strlcpy(id.i_name, drv->ifname, sizeof(id.i_name)); in wpa_driver_openbsd_get_bssid()
85 os_strlcpy(keyavail.i_name, drv->ifname, sizeof(keyavail.i_name));
97 wpa_driver_openbsd_init(void *ctx, const char *ifname)
110 os_strlcpy(drv->ifname, ifname, sizeof(drv->ifname));
Ddriver_roboswitch.c58 char ifname[IFNAMSIZ + 1]; member
213 sep = drv->ifname + os_strlen(drv->ifname); in wpa_driver_roboswitch_set_param()
215 drv->l2 = l2_packet_init(drv->ifname, NULL, ETH_P_ALL, in wpa_driver_roboswitch_set_param()
220 __func__, drv->ifname); in wpa_driver_roboswitch_set_param()
236 return drv->ifname; in wpa_driver_roboswitch_get_ifname()
357 static void * wpa_driver_roboswitch_init(void *ctx, const char *ifname) in wpa_driver_roboswitch_init() argument
369 sep = drv->ifname + in wpa_driver_roboswitch_init()
370 os_strlcpy(drv->ifname, ifname, sizeof(drv->ifname)) - 2; in wpa_driver_roboswitch_init()
372 while (sep > drv->ifname && *sep != '.') sep--; in wpa_driver_roboswitch_init()
373 if (sep <= drv->ifname) { in wpa_driver_roboswitch_init()
[all …]
/external/scapy/scapy/arch/bpf/
Dcore.py36 def get_if_raw_addr(ifname): argument
41 fd = os.popen("%s %s" % (conf.prog.ifconfig, ifname))
49 warning("No IPv4 address found on %s !", ifname)
57 def get_if_raw_hwaddr(ifname): argument
63 if ifname == LOOPBACK_NAME:
68 fd = os.popen("%s %s" % (conf.prog.ifconfig, ifname))
77 raise Scapy_Exception("No MAC address found on %s !" % ifname)
152 for ifname in get_if_list():
155 if ifname == LOOPBACK_NAME:
160 result = get_if(ifname, SIOCGIFFLAGS)
[all …]
/external/compiler-rt/test/msan/
Dif_indextoname.cc14 char ifname[IF_NAMESIZE + 1]; in main() local
15 assert(0 == __msan_test_shadow(ifname, sizeof(ifname))); in main()
16 if (!if_indextoname(1, ifname)) { in main()
21 assert(strlen(ifname) + 1 <= __msan_test_shadow(ifname, sizeof(ifname))); in main()
/external/llvm-project/compiler-rt/test/msan/
Dif_indextoname.cpp14 char ifname[IF_NAMESIZE + 1]; in main() local
15 assert(0 == __msan_test_shadow(ifname, sizeof(ifname))); in main()
16 if (!if_indextoname(1, ifname)) { in main()
21 assert(strlen(ifname) + 1 <= __msan_test_shadow(ifname, sizeof(ifname))); in main()
/external/ppp/pppd/plugins/rp-pppoe/
Dif.c96 openInterface(char const *ifname, UINT16_t type, unsigned char *hwaddr) in openInterface() argument
136 strncpy(ifr.ifr_name, ifname, sizeof(ifr.ifr_name)); in openInterface()
138 error("Can't get hardware address for %s: %m", ifname); in openInterface()
145 warn("Interface %.16s is not Ethernet", ifname); in openInterface()
150 ifname); in openInterface()
155 strncpy(ifr.ifr_name, ifname, sizeof(ifr.ifr_name)); in openInterface()
157 error("Can't get MTU for %s: %m", ifname); in openInterface()
160 ifname, ifr.ifr_mtu, ETH_DATA_LEN); in openInterface()
169 strncpy(ifr.ifr_name, ifname, sizeof(ifr.ifr_name)); in openInterface()
171 error("Could not get interface index for %s: %m", ifname); in openInterface()
[all …]
/external/llvm-project/flang/test/Semantics/
Dacc-branch.f9038 ifname: if (j == 2) then
46 exit ifname
47 end if ifname
84 ifname: if (i == 2) then
86 exit ifname
87 end if ifname
149 ifname: if (.true.) then
155 exit ifname
157 end if ifname
/external/wpa_supplicant_8/src/l2_packet/
Dl2_packet_pcap.c33 char ifname[100]; member
55 l2->eth = eth_open(l2->ifname); in l2_packet_init_libdnet()
59 l2->ifname, strerror(errno)); in l2_packet_init_libdnet()
66 l2->ifname, strerror(errno)); in l2_packet_init_libdnet()
205 char ifname[128]; in l2_packet_init_libpcap() local
206 os_snprintf(ifname, sizeof(ifname), "\\Device\\NPF_%s", l2->ifname); in l2_packet_init_libpcap()
207 pcap_lookupnet(ifname, &pcap_netp, &pcap_maskp, pcap_err); in l2_packet_init_libpcap()
208 l2->pcap = pcap_open_live(ifname, 2500, 0, 10, pcap_err); in l2_packet_init_libpcap()
211 fprintf(stderr, "ifname='%s'\n", ifname); in l2_packet_init_libpcap()
218 pcap_lookupnet(l2->ifname, &pcap_netp, &pcap_maskp, pcap_err); in l2_packet_init_libpcap()
[all …]
Dl2_packet_winpcap.c50 char ifname[100]; member
168 pcap_lookupnet(l2->ifname, &pcap_netp, &pcap_maskp, pcap_err); in l2_packet_init_libpcap()
169 l2->pcap = pcap_open_live(l2->ifname, 2500, 0, 1, pcap_err); in l2_packet_init_libpcap()
172 fprintf(stderr, "ifname='%s'\n", l2->ifname); in l2_packet_init_libpcap()
199 const char *ifname, const u8 *own_addr, unsigned short protocol, in l2_packet_init() argument
210 if (os_strncmp(ifname, "\\Device\\NPF_", 12) == 0) in l2_packet_init()
211 os_strlcpy(l2->ifname, ifname, sizeof(l2->ifname)); in l2_packet_init()
213 os_snprintf(l2->ifname, sizeof(l2->ifname), "\\Device\\NPF_%s", in l2_packet_init()
214 ifname); in l2_packet_init()
255 const char *br_ifname, const char *ifname, const u8 *own_addr, in l2_packet_init_bridge() argument
[all …]
/external/libwebsockets/lib/plat/unix/
Dunix-sockets.c185 lws_interface_to_sa(int ipv6, const char *ifname, struct sockaddr_in *addr, in lws_interface_to_sa() argument
202 ifc->ifa_name, ifname, in lws_interface_to_sa()
205 if (strcmp(ifc->ifa_name, ifname)) in lws_interface_to_sa()
252 if (inet_pton(AF_INET6, ifname, &addr6->sin6_addr) == 1) in lws_interface_to_sa()
256 if (inet_pton(AF_INET, ifname, &addr->sin_addr) == 1) in lws_interface_to_sa()
277 lws_plat_ifname_to_hwaddr(int fd, const char *ifname, uint8_t *hwaddr, int len) in lws_plat_ifname_to_hwaddr() argument
283 lws_strncpy(i.ifr_name, ifname, sizeof(i.ifr_name)); in lws_plat_ifname_to_hwaddr()
339 lws_plat_if_up(const char *ifname, int fd, int up) in lws_plat_if_up() argument
345 lws_strncpy(ifr.ifr_name, ifname, IFNAMSIZ); in lws_plat_if_up()
371 lws_plat_BINDTODEVICE(lws_sockfd_type fd, const char *ifname) in lws_plat_BINDTODEVICE() argument
[all …]
/external/mdnsresponder/mDNSWindows/
DPosixCompat.c27 if_nametoindex( const char * ifname ) in if_nametoindex() argument
32 check( ifname ); in if_nametoindex()
42 index = if_nametoindex_funcptr(ifname); in if_nametoindex()
53 if_indextoname( unsigned ifindex, char * ifname ) in if_indextoname() argument
58 check( ifname ); in if_indextoname()
59 *ifname = '\0'; in if_indextoname()
69 name = if_indextoname_funcptr(ifindex, ifname); in if_indextoname()
/external/linux-kselftest/tools/testing/selftests/bpf/
Dxdping.c100 char *ifname = NULL; in main() local
119 ifname = optarg; in main()
120 ifindex = if_nametoindex(ifname); in main()
123 ifname); in main()
143 if (!ifname) { in main()
202 printf("Setting up XDP for %s, please wait...\n", ifname); in main()
207 fprintf(stderr, "Link set xdp fd failed for %s\n", ifname); in main()
215 ifname); in main()
239 count, ifname, argv[optind]); in main()
/external/libwebsockets/lib/plat/freertos/
Dfreertos-sockets.c137 lws_interface_to_sa(int ipv6, const char *ifname, struct sockaddr_in *addr, in lws_interface_to_sa() argument
154 lwsl_info(" interface %s vs %s\n", ifc->ifa_name, ifname); in lws_interface_to_sa()
156 if (strcmp(ifc->ifa_name, ifname)) in lws_interface_to_sa()
195 if (inet_pton(AF_INET6, ifname, &addr6->sin6_addr) == 1) in lws_interface_to_sa()
199 if (inet_pton(AF_INET, ifname, &addr->sin_addr) == 1) in lws_interface_to_sa()
222 lws_plat_ifname_to_hwaddr(int fd, const char *ifname, uint8_t *hwaddr, int len) in lws_plat_ifname_to_hwaddr() argument
239 lws_plat_if_up(const char *ifname, int fd, int up) in lws_plat_if_up() argument
247 lws_plat_BINDTODEVICE(lws_sockfd_type fd, const char *ifname) in lws_plat_BINDTODEVICE() argument
255 lws_plat_ifconfig_ip(const char *ifname, int fd, uint8_t *ip, uint8_t *mask_ip, in lws_plat_ifconfig_ip() argument
/external/wpa_supplicant_8/wpa_supplicant/
Deapol_test.py23 def __init__(self, ifname): argument
24 self.ifname = ifname
25 self.ctrl = wpaspy.Ctrl(os.path.join(wpas_ctrl, ifname))
27 raise Exception("Failed to connect to eapol_test (%s)" % ifname)
28 self.mon = wpaspy.Ctrl(os.path.join(wpas_ctrl, ifname))
63 logger.debug(self.ifname + ": " + ev)
75 def run(ifname, count, no_fast_reauth, res): argument
76 et = eapol_test(ifname)

12345678910>>...12