Lines Matching refs:ifr
73 struct ifreq ifr; in tnl_get_ioctl() local
77 strncpy(ifr.ifr_name, basedev, IFNAMSIZ); in tnl_get_ioctl()
78 ifr.ifr_ifru.ifru_data = (void *)p; in tnl_get_ioctl()
86 err = ioctl(fd, SIOCGETTUNNEL, &ifr); in tnl_get_ioctl()
97 struct ifreq ifr; in tnl_add_ioctl() local
102 strncpy(ifr.ifr_name, name, IFNAMSIZ); in tnl_add_ioctl()
104 strncpy(ifr.ifr_name, basedev, IFNAMSIZ); in tnl_add_ioctl()
105 ifr.ifr_ifru.ifru_data = p; in tnl_add_ioctl()
113 err = ioctl(fd, cmd, &ifr); in tnl_add_ioctl()
115 fprintf(stderr, "add tunnel \"%s\" failed: %s\n", ifr.ifr_name, in tnl_add_ioctl()
123 struct ifreq ifr; in tnl_del_ioctl() local
128 strncpy(ifr.ifr_name, name, IFNAMSIZ); in tnl_del_ioctl()
130 strncpy(ifr.ifr_name, basedev, IFNAMSIZ); in tnl_del_ioctl()
132 ifr.ifr_ifru.ifru_data = p; in tnl_del_ioctl()
140 err = ioctl(fd, SIOCDELTUNNEL, &ifr); in tnl_del_ioctl()
143 ifr.ifr_name, strerror(errno)); in tnl_del_ioctl()
151 struct ifreq ifr; in tnl_gen_ioctl() local
155 strncpy(ifr.ifr_name, name, IFNAMSIZ); in tnl_gen_ioctl()
156 ifr.ifr_ifru.ifru_data = p; in tnl_gen_ioctl()
164 err = ioctl(fd, cmd, &ifr); in tnl_gen_ioctl()