Home
last modified time | relevance | path

Searched refs:rtattr (Results 1 – 25 of 60) sorted by relevance

123

/linux-6.15/tools/testing/selftests/net/
H A Dtap.c33 static struct rtattr *rtattr_add(struct nlmsghdr *nh, unsigned short type, in rtattr_add()
36 struct rtattr *rta = in rtattr_add()
37 (struct rtattr *)((uint8_t *)nh + RTA_ALIGN(nh->nlmsg_len)); in rtattr_add()
44 static struct rtattr *rtattr_begin(struct nlmsghdr *nh, unsigned short type) in rtattr_begin()
49 static void rtattr_end(struct nlmsghdr *nh, struct rtattr *attr) in rtattr_end()
56 static struct rtattr *rtattr_add_str(struct nlmsghdr *nh, unsigned short type, in rtattr_add_str()
59 struct rtattr *rta = rtattr_add(nh, type, strlen(s)); in rtattr_add_str()
68 struct rtattr *rta = rtattr_add(nh, type, strlen(s) + 1); in rtattr_add_strsz()
74 static struct rtattr *rtattr_add_any(struct nlmsghdr *nh, unsigned short type, in rtattr_add_any()
77 struct rtattr *rta = rtattr_add(nh, type, len); in rtattr_add_any()
[all …]
H A Dtun.c74 struct rtattr *rta; in tun_delete()
90 rta = (struct rtattr *)(((char *)&req) + NLMSG_ALIGN(req.nh.nlmsg_len)); in tun_delete()
H A Dipsec.c210 static inline struct rtattr *rtattr_hdr(struct nlmsghdr *nh) in rtattr_hdr()
212 return (struct rtattr *)((char *)(nh) + RTA_ALIGN((nh)->nlmsg_len)); in rtattr_hdr()
219 struct rtattr *attr = rtattr_hdr(nh); in rtattr_pack()
236 static struct rtattr *_rtattr_begin(struct nlmsghdr *nh, size_t req_sz, in _rtattr_begin()
239 struct rtattr *ret = rtattr_hdr(nh); in _rtattr_begin()
247 static inline struct rtattr *rtattr_begin(struct nlmsghdr *nh, size_t req_sz, in rtattr_begin()
253 static inline void rtattr_end(struct nlmsghdr *nh, struct rtattr *attr) in rtattr_end()
264 struct rtattr *peer_attr; in veth_pack_peerb()
318 struct rtattr *link_info, *info_data; in veth_add()
1678 struct rtattr *attr = (void *)req.attrbuf; in xfrm_spdinfo_attrs()
/linux-6.15/tools/testing/selftests/bpf/prog_tests/
H A Dxfrm_info.c171 static struct rtattr *rtattr_add(struct nlmsghdr *nh, unsigned short type, in rtattr_add()
174 struct rtattr *rta = in rtattr_add()
175 (struct rtattr *)((uint8_t *)nh + RTA_ALIGN(nh->nlmsg_len)); in rtattr_add()
182 static struct rtattr *rtattr_add_str(struct nlmsghdr *nh, unsigned short type, in rtattr_add_str()
185 struct rtattr *rta = rtattr_add(nh, type, strlen(s)); in rtattr_add_str()
191 static struct rtattr *rtattr_begin(struct nlmsghdr *nh, unsigned short type) in rtattr_begin()
196 static void rtattr_end(struct nlmsghdr *nh, struct rtattr *attr) in rtattr_end()
210 struct rtattr *link_info, *info_data; in setup_xfrmi_external_dev()
/linux-6.15/tools/testing/selftests/net/tcp_ao/lib/
H A Dnetlink.c60 static inline struct rtattr *rtattr_hdr(struct nlmsghdr *nh) in rtattr_hdr()
62 return (struct rtattr *)((char *)(nh) + RTA_ALIGN((nh)->nlmsg_len)); in rtattr_hdr()
69 struct rtattr *attr = rtattr_hdr(nh); in rtattr_pack()
85 static struct rtattr *_rtattr_begin(struct nlmsghdr *nh, size_t req_sz, in _rtattr_begin()
88 struct rtattr *ret = rtattr_hdr(nh); in _rtattr_begin()
96 static inline struct rtattr *rtattr_begin(struct nlmsghdr *nh, size_t req_sz, in rtattr_begin()
102 static inline void rtattr_end(struct nlmsghdr *nh, struct rtattr *attr) in rtattr_end()
113 struct rtattr *peer_attr; in veth_pack_peerb()
144 struct rtattr *link_info, *info_data; in __add_veth()
358 struct rtattr *link_info, *info_data; in __add_vrf()
/linux-6.15/tools/testing/selftests/net/mptcp/
H A Dmptcp_diag.c82 struct rtattr rta_proto; in send_query()
117 static void parse_rtattr_flags(struct rtattr *tb[], int max, struct rtattr *rta, in parse_rtattr_flags()
122 memset(tb, 0, sizeof(struct rtattr *) * (max + 1)); in parse_rtattr_flags()
166 struct rtattr *tb[INET_DIAG_MAX + 1]; in parse_nlmsg()
168 parse_rtattr_flags(tb, INET_DIAG_MAX, (struct rtattr *)(r + 1), in parse_nlmsg()
H A Dpm_nl_ctl.c77 struct rtattr *attrs = (struct rtattr *)NLMSG_DATA(nh); in nl_error()
104 struct rtattr *attrs; in capture_events()
244 struct rtattr *attrs; in genl_parse_getfamily()
245 struct rtattr *grps; in genl_parse_getfamily()
246 struct rtattr *grp; in genl_parse_getfamily()
314 struct rtattr *rta; in resolve_mptcp_pm_netlink()
453 struct rtattr *addr; in csf()
454 struct rtattr *rta; in csf()
585 struct rtattr *rta; in remove_addr()
1052 struct rtattr *attrs; in print_addrs()
[all …]
/linux-6.15/include/crypto/
H A Dalgapi.h53 struct rtattr;
81 int (*create)(struct crypto_template *tmpl, struct rtattr **tb);
157 struct crypto_attr_type *crypto_get_attr_type(struct rtattr **tb);
158 int crypto_check_attr_type(struct rtattr **tb, u32 type, u32 *mask_ret);
159 const char *crypto_attr_alg_name(struct rtattr *rta);
/linux-6.15/tools/testing/selftests/bpf/
H A Dnetlink_helpers.h24 ((struct rtattr *) (((void *) (nmsg)) + NLMSG_ALIGN((nmsg)->nlmsg_len)))
44 struct rtattr *addattr_nest(struct nlmsghdr *n, int maxlen, int type);
45 int addattr_nest_end(struct nlmsghdr *n, struct rtattr *nest);
H A Dnetlink_helpers.c316 struct rtattr *rta; in addattr_l()
346 struct rtattr *addattr_nest(struct nlmsghdr *n, int maxlen, int type) in addattr_nest()
348 struct rtattr *nest = NLMSG_TAIL(n); in addattr_nest()
354 int addattr_nest_end(struct nlmsghdr *n, struct rtattr *nest) in addattr_nest_end()
/linux-6.15/include/uapi/linux/
H A Drtnetlink.h219 struct rtattr { struct
228 #define RTA_OK(rta,len) ((len) >= (int)sizeof(struct rtattr) && \ argument
229 (rta)->rta_len >= sizeof(struct rtattr) && \
232 (struct rtattr*)(((char*)(rta)) + RTA_ALIGN((rta)->rta_len)))
233 #define RTA_LENGTH(len) (RTA_ALIGN(sizeof(struct rtattr)) + (len))
407 #define RTM_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct rtmsg))))
448 #define RTNH_DATA(rtnh) ((struct rtattr*)(((char*)(rtnh)) + RTNH_LENGTH(0)))
663 #define TCA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct tcmsg))))
817 #define TA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct tcamsg))))
H A Dif_addr.h69 #define IFA_RTA(r) ((struct rtattr*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct ifaddrmsg))))
/linux-6.15/crypto/
H A Dalgboss.c24 struct rtattr *tb[CRYPTO_MAX_ATTRS + 2];
27 struct rtattr attr;
32 struct rtattr attr;
H A Ddh.c552 struct crypto_template *tmpl, struct rtattr **tb, in __dh_safe_prime_create()
834 struct rtattr **tb) in dh_ffdhe2048_create()
840 struct rtattr **tb) in dh_ffdhe3072_create()
846 struct rtattr **tb) in dh_ffdhe4096_create()
852 struct rtattr **tb) in dh_ffdhe6144_create()
858 struct rtattr **tb) in dh_ffdhe8192_create()
H A Decb.c98 struct crypto_template *tmpl, struct rtattr **tb) in lskcipher_alloc_instance_simple2()
149 static int crypto_ecb_create2(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ecb_create2()
171 static int crypto_ecb_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ecb_create()
H A Dauthenc.c49 struct rtattr *rta = (struct rtattr *)key; in crypto_authenc_extractkeys()
365 struct rtattr **tb) in crypto_authenc_create()
H A Dkrb5enc.c65 struct rtattr *rta = (struct rtattr *)key; in crypto_krb5enc_extractkeys()
399 static int krb5enc_create(struct crypto_template *tmpl, struct rtattr **tb) in krb5enc_create()
H A Dhctr2.c405 struct rtattr **tb, in hctr2_create_common()
516 static int hctr2_create_base(struct crypto_template *tmpl, struct rtattr **tb) in hctr2_create_base()
532 static int hctr2_create(struct crypto_template *tmpl, struct rtattr **tb) in hctr2_create()
H A Dccm.c447 struct rtattr **tb, in crypto_ccm_create_common()
529 static int crypto_ccm_create(struct crypto_template *tmpl, struct rtattr **tb) in crypto_ccm_create()
551 struct rtattr **tb) in crypto_ccm_base_create()
705 struct rtattr **tb) in crypto_rfc4309_create()
858 static int cbcmac_create(struct crypto_template *tmpl, struct rtattr **tb) in cbcmac_create()
H A Dpcrypt.c240 static int pcrypt_create_aead(struct crypto_template *tmpl, struct rtattr **tb, in pcrypt_create_aead()
299 static int pcrypt_create(struct crypto_template *tmpl, struct rtattr **tb) in pcrypt_create()
/linux-6.15/include/crypto/internal/
H A Dskcipher.h25 struct rtattr;
279 struct crypto_template *tmpl, struct rtattr **tb);
298 struct crypto_template *tmpl, struct rtattr **tb);
H A Dgeniv.h23 struct rtattr **tb);
H A Daead.h16 struct rtattr;
/linux-6.15/tools/testing/selftests/net/af_unix/
H A Ddiag_uid.c120 struct rtattr *attr; in render_response()
126 attr = (struct rtattr *)(udr + 1); in render_response()
/linux-6.15/samples/bpf/
H A Dxdp_router_ipv4_user.c95 struct rtattr *rt_attr; in read_route()
123 rt_attr = (struct rtattr *)RTM_RTA(rt_msg); in read_route()
318 struct rtattr *rt_attr; in read_arp()
335 rt_attr = (struct rtattr *)RTM_RTA(rt_msg); in read_arp()

123