Searched refs:rta (Results 1 – 3 of 3) sorted by relevance
/system/core/libsysutils/src/ |
D | NetlinkEvent.cpp | 135 struct rtattr *rta; in parseIfInfoMessage() local 136 for (rta = IFLA_RTA(ifi); RTA_OK(rta, len); rta = RTA_NEXT(rta, len)) { in parseIfInfoMessage() 137 switch(rta->rta_type) { in parseIfInfoMessage() 139 asprintf(&mParams[0], "INTERFACE=%s", (char *) RTA_DATA(rta)); in parseIfInfoMessage() 178 struct rtattr *rta; in parseIfAddrMessage() local 180 for (rta = IFA_RTA(ifaddr); RTA_OK(rta, len); rta = RTA_NEXT(rta, len)) { in parseIfAddrMessage() 181 if (rta->rta_type == IFA_ADDRESS) { in parseIfAddrMessage() 189 struct in_addr *addr4 = (struct in_addr *) RTA_DATA(rta); in parseIfAddrMessage() 190 if (RTA_PAYLOAD(rta) < sizeof(*addr4)) { in parseIfAddrMessage() 192 RTA_PAYLOAD(rta), msgtype); in parseIfAddrMessage() [all …]
|
/system/netd/server/ |
D | NetlinkCommands.cpp | 206 rtattr *rta = reinterpret_cast<rtattr *> RTM_RTA(msg); in getRtmU32Attribute() local 207 for (; RTA_OK(rta, rta_len); rta = RTA_NEXT(rta, rta_len)) { in getRtmU32Attribute() 208 if (rta->rta_type == attribute) { in getRtmU32Attribute() 209 return *(static_cast<uint32_t *>(RTA_DATA(rta))); in getRtmU32Attribute()
|
/system/core/libnetutils/ |
D | ifc_utils.c | 273 struct rtattr *rta; in ifc_act_on_address() local 320 rta = (struct rtattr *) (((char *) &req) + NLMSG_ALIGN(req.n.nlmsg_len)); in ifc_act_on_address() 321 rta->rta_type = IFA_LOCAL; in ifc_act_on_address() 322 rta->rta_len = RTA_LENGTH(addrlen); in ifc_act_on_address() 324 memcpy(RTA_DATA(rta), addr, addrlen); in ifc_act_on_address() 328 rta = (struct rtattr *) (((char *) &req) + NLMSG_ALIGN(req.n.nlmsg_len)); in ifc_act_on_address() 329 rta->rta_type = IFA_BROADCAST; in ifc_act_on_address() 330 rta->rta_len = RTA_LENGTH(addrlen); in ifc_act_on_address() 333 memcpy(RTA_DATA(rta), addr, addrlen); in ifc_act_on_address()
|