Lines Matching refs:rta
143 struct rtattr *rta;
144 for (rta = IFLA_RTA(ifi); RTA_OK(rta, len); rta = RTA_NEXT(rta, len)) {
145 switch(rta->rta_type) {
147 asprintf(&mParams[0], "INTERFACE=%s", (char *) RTA_DATA(rta));
180 struct rtattr *rta;
182 for (rta = IFA_RTA(ifaddr); RTA_OK(rta, len); rta = RTA_NEXT(rta, len)) {
183 if (rta->rta_type == IFA_ADDRESS) {
191 struct in_addr *addr4 = (struct in_addr *) RTA_DATA(rta);
192 if (RTA_PAYLOAD(rta) < sizeof(*addr4)) {
194 RTA_PAYLOAD(rta), msgtype);
199 struct in6_addr *addr6 = (struct in6_addr *) RTA_DATA(rta);
200 if (RTA_PAYLOAD(rta) < sizeof(*addr6)) {
202 RTA_PAYLOAD(rta), msgtype);
217 } else if (rta->rta_type == IFA_CACHEINFO) {
222 if (RTA_PAYLOAD(rta) < sizeof(*cacheinfo)) {
224 RTA_PAYLOAD(rta), sizeof(cacheinfo), msgtype);
228 cacheinfo = (struct ifa_cacheinfo *) RTA_DATA(rta);
313 struct rtattr *rta;
314 for (rta = RTM_RTA(rtm); RTA_OK(rta, len); rta = RTA_NEXT(rta, len)) {
315 switch (rta->rta_type) {
319 if (!inet_ntop(family, RTA_DATA(rta), dst, sizeof(dst)))
325 if (!inet_ntop(family, RTA_DATA(rta), gw, sizeof(gw)))
331 if (!if_indextoname(* (int *) RTA_DATA(rta), dev))