Lines Matching refs:sock
18 int linux_set_iface_flags(int sock, const char *ifname, int dev_up) in linux_set_iface_flags() argument
23 if (sock < 0) in linux_set_iface_flags()
29 if (ioctl(sock, SIOCGIFFLAGS, &ifr) != 0) { in linux_set_iface_flags()
46 if (ioctl(sock, SIOCSIFFLAGS, &ifr) != 0) { in linux_set_iface_flags()
57 int linux_iface_up(int sock, const char *ifname) in linux_iface_up() argument
62 if (sock < 0) in linux_iface_up()
68 if (ioctl(sock, SIOCGIFFLAGS, &ifr) != 0) { in linux_iface_up()
79 int linux_get_ifhwaddr(int sock, const char *ifname, u8 *addr) in linux_get_ifhwaddr() argument
85 if (ioctl(sock, SIOCGIFHWADDR, &ifr)) { in linux_get_ifhwaddr()
102 int linux_set_ifhwaddr(int sock, const char *ifname, const u8 *addr) in linux_set_ifhwaddr() argument
111 if (ioctl(sock, SIOCSIFHWADDR, &ifr)) { in linux_set_ifhwaddr()
135 int linux_br_add(int sock, const char *brname) in linux_br_add() argument
137 if (ioctl(sock, SIOCBRADDBR, brname) < 0) { in linux_br_add()
147 int linux_br_del(int sock, const char *brname) in linux_br_del() argument
149 if (ioctl(sock, SIOCBRDELBR, brname) < 0) { in linux_br_del()
159 int linux_br_add_if(int sock, const char *brname, const char *ifname) in linux_br_add_if() argument
171 if (ioctl(sock, SIOCBRADDIF, &ifr) < 0) { in linux_br_add_if()
181 int linux_br_del_if(int sock, const char *brname, const char *ifname) in linux_br_del_if() argument
193 if (ioctl(sock, SIOCBRDELIF, &ifr) < 0) { in linux_br_del_if()