Home
last modified time | relevance | path

Searched refs:NLMSG_ALIGN (Results 1 – 16 of 16) sorted by relevance

/tools/testing/selftests/net/mptcp/
A Dpm_nl_ctl.c54 off += NLMSG_ALIGN(sizeof(*nh)); in init_genl_req()
59 off += NLMSG_ALIGN(sizeof(*gh)); in init_genl_req()
327 off += NLMSG_ALIGN(rta->rta_len); in resolve_mptcp_pm_netlink()
438 off += NLMSG_ALIGN(rta->rta_len); in dsf()
572 off += NLMSG_ALIGN(rta->rta_len); in csf()
671 off += NLMSG_ALIGN(rta->rta_len); in announce_addr()
678 off += NLMSG_ALIGN(rta->rta_len); in announce_addr()
736 off += NLMSG_ALIGN(rta->rta_len); in announce_addr()
748 off += NLMSG_ALIGN(rta->rta_len); in announce_addr()
795 off += NLMSG_ALIGN(rta->rta_len); in add_addr()
[all …]
/tools/include/uapi/linux/
A Dnetlink.h90 #define NLMSG_ALIGN(len) ( ((len)+NLMSG_ALIGNTO-1) & ~(NLMSG_ALIGNTO-1) ) macro
91 #define NLMSG_HDRLEN ((int) NLMSG_ALIGN(sizeof(struct nlmsghdr)))
93 #define NLMSG_SPACE(len) NLMSG_ALIGN(NLMSG_LENGTH(len))
95 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \
96 (struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len)))
A Dif_link.h398 #define IFLA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct ifinfomsg))))
/tools/testing/selftests/bpf/
A Dnetlink_helpers.c211 status -= NLMSG_ALIGN(len); in __rtnl_talk_iov()
212 h = (struct nlmsghdr *)((char *)h + NLMSG_ALIGN(len)); in __rtnl_talk_iov()
249 status -= NLMSG_ALIGN(len); in __rtnl_talk_iov()
250 h = (struct nlmsghdr *)((char *)h + NLMSG_ALIGN(len)); in __rtnl_talk_iov()
318 if (NLMSG_ALIGN(n->nlmsg_len) + RTA_ALIGN(len) > maxlen) { in addattr_l()
328 n->nlmsg_len = NLMSG_ALIGN(n->nlmsg_len) + RTA_ALIGN(len); in addattr_l()
334 if (NLMSG_ALIGN(n->nlmsg_len) + NLMSG_ALIGN(len) > maxlen) { in addraw_l()
341 memset((void *) NLMSG_TAIL(n) + len, 0, NLMSG_ALIGN(len) - len); in addraw_l()
342 n->nlmsg_len = NLMSG_ALIGN(n->nlmsg_len) + NLMSG_ALIGN(len); in addraw_l()
A Dnetlink_helpers.h24 ((struct rtattr *) (((void *) (nmsg)) + NLMSG_ALIGN((nmsg)->nlmsg_len)))
A Dxsk.c409 rta = (struct rtattr *)(((char *)&req) + NLMSG_ALIGN(req.nh.nlmsg_len)); in xsk_set_mtu()
412 req.nh.nlmsg_len = NLMSG_ALIGN(req.nh.nlmsg_len) + RTA_LENGTH(sizeof(mtu)); in xsk_set_mtu()
/tools/lib/bpf/
A Dnlattr.h138 return (struct nlattr *)((void *)req + NLMSG_ALIGN(req->nh.nlmsg_len)); in req_tail()
146 if (NLMSG_ALIGN(req->nh.nlmsg_len) + NLA_ALIGN(NLA_HDRLEN + len) > sizeof(*req)) in nlattr_add()
156 req->nh.nlmsg_len = NLMSG_ALIGN(req->nh.nlmsg_len) + NLA_ALIGN(nla->nla_len); in nlattr_add()
A Dnetlink.c352 attr = (struct nlattr *) ((void *) ifi + NLMSG_ALIGN(sizeof(*ifi))); in __dump_link_nlmsg()
702 (struct nlattr *)((void *)tc + NLMSG_ALIGN(sizeof(*tc))), in get_tc_info()
/tools/net/ynl/lib/
A Dynl-priv.h185 nlh->nlmsg_len += NLMSG_ALIGN(size); in ynl_nlmsg_put_extra_header()
253 attr = (struct nlattr *)((char *)start + NLMSG_ALIGN(skip)); in ynl_attr_first()
263 o = nlh->nlmsg_len + NLA_HDRLEN + NLMSG_ALIGN(size) > nlh->nlmsg_pid; in __ynl_attr_put_overflow()
308 nlh->nlmsg_len += NLMSG_ALIGN(attr->nla_len); in ynl_attr_put()
327 nlh->nlmsg_len += NLMSG_ALIGN(attr->nla_len); in ynl_attr_put_str()
/tools/testing/selftests/net/
A Dtun.c84 req.nh.nlmsg_len = NLMSG_ALIGN(NLMSG_LENGTH(sizeof(req.ifm))); in tun_delete()
90 rta = (struct rtattr *)(((char *)&req) + NLMSG_ALIGN(req.nh.nlmsg_len)); in tun_delete()
/tools/bpf/bpftool/
A Dnet.c219 attr = (struct nlattr *) ((void *) t + NLMSG_ALIGN(sizeof(*t))); in __dump_class_nlmsg()
258 attr = (struct nlattr *) ((void *) t + NLMSG_ALIGN(sizeof(*t))); in __dump_qdisc_nlmsg()
297 attr = (struct nlattr *) ((void *) t + NLMSG_ALIGN(sizeof(*t))); in __dump_filter_nlmsg()
336 attr = (struct nlattr *) ((void *) ifi + NLMSG_ALIGN(sizeof(*ifi))); in __dump_link_nlmsg()
/tools/accounting/
A Dprocacct.c147 msg.n.nlmsg_len += NLMSG_ALIGN(na->nla_len); in send_cmd()
A Dgetdelays.c140 msg.n.nlmsg_len += NLMSG_ALIGN(na->nla_len); in send_cmd()
A Ddelaytop.c306 msg.n.nlmsg_len += NLMSG_ALIGN(na->nla_len); in send_cmd()
/tools/testing/selftests/landlock/
A Daudit.h150 NLMSG_ALIGN(filter->exe_len), in audit_filter_exe()
/tools/testing/selftests/net/ovpn/
A Dovpn-cli.c1067 if ((int)(NLMSG_ALIGN(n->nlmsg_len) + RTA_ALIGN(len)) > maxlen) { in ovpn_addattr()
1082 n->nlmsg_len = NLMSG_ALIGN(n->nlmsg_len) + RTA_ALIGN(len); in ovpn_addattr()
1325 rcv_len -= NLMSG_ALIGN(len); in ovpn_rt_send()
1327 NLMSG_ALIGN(len)); in ovpn_rt_send()

Completed in 37 milliseconds