Home
last modified time | relevance | path

Searched refs:nla (Results 1 - 25 of 228) sorted by relevance

12345678910

/kernel/linux/linux-5.10/lib/
H A Dnlattr.c62 static int validate_nla_bitfield32(const struct nlattr *nla, in validate_nla_bitfield32() argument
65 const struct nla_bitfield32 *bf = nla_data(nla); in validate_nla_bitfield32()
164 const struct nlattr *nla, in nla_validate_range_unsigned()
173 value = nla_get_u8(nla); in nla_validate_range_unsigned()
176 value = nla_get_u16(nla); in nla_validate_range_unsigned()
179 value = nla_get_u32(nla); in nla_validate_range_unsigned()
183 value = nla_get_u64(nla); in nla_validate_range_unsigned()
186 value = nla_len(nla); in nla_validate_range_unsigned()
199 NL_SET_ERR_MSG_ATTR_POL(extack, nla, pt, in nla_validate_range_unsigned()
212 NL_SET_ERR_MSG_ATTR_POL(extack, nla, p in nla_validate_range_unsigned()
163 nla_validate_range_unsigned(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack, unsigned int validate) nla_validate_range_unsigned() argument
268 nla_validate_int_range_signed(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack) nla_validate_int_range_signed() argument
303 nla_validate_int_range(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack, unsigned int validate) nla_validate_int_range() argument
327 nla_validate_mask(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack) nla_validate_mask() argument
358 validate_nla(const struct nlattr *nla, int maxtype, const struct nla_policy *policy, unsigned int validate, struct netlink_ext_ack *extack, unsigned int depth) validate_nla() argument
566 const struct nlattr *nla; __nla_validate_parse() local
703 const struct nlattr *nla; nla_find() local
726 nla_strlcpy(char *dst, const struct nlattr *nla, size_t dstsize) nla_strlcpy() argument
752 nla_strdup(const struct nlattr *nla, gfp_t flags) nla_strdup() argument
798 nla_memcmp(const struct nlattr *nla, const void *data, size_t size) nla_memcmp() argument
815 nla_strcmp(const struct nlattr *nla, const char *str) nla_strcmp() argument
848 struct nlattr *nla; __nla_reserve() local
982 struct nlattr *nla; __nla_put() local
1003 struct nlattr *nla; __nla_put_64bit() local
[all...]
/kernel/linux/linux-5.10/tools/lib/bpf/
H A Dnlattr.c25 static struct nlattr *nla_next(const struct nlattr *nla, int *remaining) in nla_next() argument
27 int totlen = NLA_ALIGN(nla->nla_len); in nla_next()
30 return (struct nlattr *) ((char *) nla + totlen); in nla_next()
33 static int nla_ok(const struct nlattr *nla, int remaining) in nla_ok() argument
35 return remaining >= sizeof(*nla) && in nla_ok()
36 nla->nla_len >= sizeof(*nla) && in nla_ok()
37 nla->nla_len <= remaining; in nla_ok()
40 static int nla_type(const struct nlattr *nla) in nla_type() argument
42 return nla in nla_type()
45 validate_nla(struct nlattr *nla, int maxtype, struct libbpf_nla_policy *policy) validate_nla() argument
107 struct nlattr *nla; libbpf_nla_parse() local
149 libbpf_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla, struct libbpf_nla_policy *policy) libbpf_nla_parse_nested() argument
[all...]
H A Dnlattr.h67 * @nla: netlink attribute
69 static inline void *libbpf_nla_data(const struct nlattr *nla) in libbpf_nla_data() argument
71 return (char *) nla + NLA_HDRLEN; in libbpf_nla_data()
74 static inline uint8_t libbpf_nla_getattr_u8(const struct nlattr *nla) in libbpf_nla_getattr_u8() argument
76 return *(uint8_t *)libbpf_nla_data(nla); in libbpf_nla_getattr_u8()
79 static inline uint32_t libbpf_nla_getattr_u32(const struct nlattr *nla) in libbpf_nla_getattr_u32() argument
81 return *(uint32_t *)libbpf_nla_data(nla); in libbpf_nla_getattr_u32()
84 static inline const char *libbpf_nla_getattr_str(const struct nlattr *nla) in libbpf_nla_getattr_str() argument
86 return (const char *)libbpf_nla_data(nla); in libbpf_nla_getattr_str()
91 * @nla
93 libbpf_nla_len(const struct nlattr *nla) libbpf_nla_len() argument
[all...]
H A Dnetlink.c138 struct nlattr *nla, *nla_xdp; in __bpf_set_link_xdp_fd_replace() local
160 nla = (struct nlattr *)(((char *)&req) in __bpf_set_link_xdp_fd_replace()
162 nla->nla_type = NLA_F_NESTED | IFLA_XDP; in __bpf_set_link_xdp_fd_replace()
163 nla->nla_len = NLA_HDRLEN; in __bpf_set_link_xdp_fd_replace()
166 nla_xdp = (struct nlattr *)((char *)nla + nla->nla_len); in __bpf_set_link_xdp_fd_replace()
170 nla->nla_len += nla_xdp->nla_len; in __bpf_set_link_xdp_fd_replace()
174 nla_xdp = (struct nlattr *)((char *)nla + nla->nla_len); in __bpf_set_link_xdp_fd_replace()
178 nla in __bpf_set_link_xdp_fd_replace()
[all...]
/kernel/linux/linux-6.6/tools/lib/bpf/
H A Dnlattr.c25 static struct nlattr *nla_next(const struct nlattr *nla, int *remaining) in nla_next() argument
27 int totlen = NLA_ALIGN(nla->nla_len); in nla_next()
30 return (struct nlattr *)((void *)nla + totlen); in nla_next()
33 static int nla_ok(const struct nlattr *nla, int remaining) in nla_ok() argument
35 return remaining >= (int)sizeof(*nla) && in nla_ok()
36 nla->nla_len >= sizeof(*nla) && in nla_ok()
37 nla->nla_len <= remaining; in nla_ok()
40 static int nla_type(const struct nlattr *nla) in nla_type() argument
42 return nla in nla_type()
45 validate_nla(struct nlattr *nla, int maxtype, struct libbpf_nla_policy *policy) validate_nla() argument
107 struct nlattr *nla; libbpf_nla_parse() local
149 libbpf_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla, struct libbpf_nla_policy *policy) libbpf_nla_parse_nested() argument
[all...]
H A Dnlattr.h82 * @nla: netlink attribute
84 static inline void *libbpf_nla_data(const struct nlattr *nla) in libbpf_nla_data() argument
86 return (void *)nla + NLA_HDRLEN; in libbpf_nla_data()
89 static inline uint8_t libbpf_nla_getattr_u8(const struct nlattr *nla) in libbpf_nla_getattr_u8() argument
91 return *(uint8_t *)libbpf_nla_data(nla); in libbpf_nla_getattr_u8()
94 static inline uint16_t libbpf_nla_getattr_u16(const struct nlattr *nla) in libbpf_nla_getattr_u16() argument
96 return *(uint16_t *)libbpf_nla_data(nla); in libbpf_nla_getattr_u16()
99 static inline uint32_t libbpf_nla_getattr_u32(const struct nlattr *nla) in libbpf_nla_getattr_u32() argument
101 return *(uint32_t *)libbpf_nla_data(nla); in libbpf_nla_getattr_u32()
104 static inline uint64_t libbpf_nla_getattr_u64(const struct nlattr *nla) in libbpf_nla_getattr_u64() argument
109 libbpf_nla_getattr_str(const struct nlattr *nla) libbpf_nla_getattr_str() argument
118 libbpf_nla_len(const struct nlattr *nla) libbpf_nla_len() argument
131 nla_data(struct nlattr *nla) nla_data() argument
144 struct nlattr *nla; nlattr_add() local
[all...]
/kernel/linux/linux-6.6/lib/
H A Dnlattr.c66 static int validate_nla_bitfield32(const struct nlattr *nla, in validate_nla_bitfield32() argument
69 const struct nla_bitfield32 *bf = nla_data(nla); in validate_nla_bitfield32()
170 const struct nlattr *nla, in nla_validate_range_unsigned()
179 value = nla_get_u8(nla); in nla_validate_range_unsigned()
182 value = nla_get_u16(nla); in nla_validate_range_unsigned()
185 value = nla_get_u32(nla); in nla_validate_range_unsigned()
188 value = nla_get_u64(nla); in nla_validate_range_unsigned()
191 value = nla_get_u64(nla); in nla_validate_range_unsigned()
194 value = nla_len(nla); in nla_validate_range_unsigned()
197 value = ntohs(nla_get_be16(nla)); in nla_validate_range_unsigned()
169 nla_validate_range_unsigned(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack, unsigned int validate) nla_validate_range_unsigned() argument
282 nla_validate_int_range_signed(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack) nla_validate_int_range_signed() argument
317 nla_validate_int_range(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack, unsigned int validate) nla_validate_int_range() argument
343 nla_validate_mask(const struct nla_policy *pt, const struct nlattr *nla, struct netlink_ext_ack *extack) nla_validate_mask() argument
380 validate_nla(const struct nlattr *nla, int maxtype, const struct nla_policy *policy, unsigned int validate, struct netlink_ext_ack *extack, unsigned int depth) validate_nla() argument
588 const struct nlattr *nla; __nla_validate_parse() local
725 const struct nlattr *nla; nla_find() local
750 nla_strscpy(char *dst, const struct nlattr *nla, size_t dstsize) nla_strscpy() argument
786 nla_strdup(const struct nlattr *nla, gfp_t flags) nla_strdup() argument
832 nla_memcmp(const struct nlattr *nla, const void *data, size_t size) nla_memcmp() argument
849 nla_strcmp(const struct nlattr *nla, const char *str) nla_strcmp() argument
882 struct nlattr *nla; __nla_reserve() local
1016 struct nlattr *nla; __nla_put() local
1037 struct nlattr *nla; __nla_put_64bit() local
[all...]
/kernel/linux/linux-5.10/drivers/block/drbd/
H A Ddrbd_nla.c7 static int drbd_nla_check_mandatory(int maxtype, struct nlattr *nla) in drbd_nla_check_mandatory() argument
9 struct nlattr *head = nla_data(nla); in drbd_nla_check_mandatory()
10 int len = nla_len(nla); in drbd_nla_check_mandatory()
21 nla_for_each_attr(nla, head, len, rem) { in drbd_nla_check_mandatory()
22 if (nla->nla_type & DRBD_GENLA_F_MANDATORY) { in drbd_nla_check_mandatory()
23 nla->nla_type &= ~DRBD_GENLA_F_MANDATORY; in drbd_nla_check_mandatory()
24 if (nla_type(nla) > maxtype) in drbd_nla_check_mandatory()
31 int drbd_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla, in drbd_nla_parse_nested() argument
36 err = drbd_nla_check_mandatory(maxtype, nla); in drbd_nla_parse_nested()
38 err = nla_parse_nested_deprecated(tb, maxtype, nla, polic in drbd_nla_parse_nested()
44 drbd_nla_find_nested(int maxtype, struct nlattr *nla, int attrtype) drbd_nla_find_nested() argument
[all...]
/kernel/linux/linux-6.6/drivers/block/drbd/
H A Ddrbd_nla.c7 static int drbd_nla_check_mandatory(int maxtype, struct nlattr *nla) in drbd_nla_check_mandatory() argument
9 struct nlattr *head = nla_data(nla); in drbd_nla_check_mandatory()
10 int len = nla_len(nla); in drbd_nla_check_mandatory()
21 nla_for_each_attr(nla, head, len, rem) { in drbd_nla_check_mandatory()
22 if (nla->nla_type & DRBD_GENLA_F_MANDATORY) { in drbd_nla_check_mandatory()
23 nla->nla_type &= ~DRBD_GENLA_F_MANDATORY; in drbd_nla_check_mandatory()
24 if (nla_type(nla) > maxtype) in drbd_nla_check_mandatory()
31 int drbd_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla, in drbd_nla_parse_nested() argument
36 err = drbd_nla_check_mandatory(maxtype, nla); in drbd_nla_parse_nested()
38 err = nla_parse_nested_deprecated(tb, maxtype, nla, polic in drbd_nla_parse_nested()
44 drbd_nla_find_nested(int maxtype, struct nlattr *nla, int attrtype) drbd_nla_find_nested() argument
[all...]
/kernel/linux/linux-5.10/include/net/
H A Dnetlink.h84 * <- nla_len(nla) -> ^
85 * nla_data(nla)----^ |
86 * nla_next(nla)-----------------------------'
118 * nla_nest_end(skb, nla) finalize a nested attribute
119 * nla_nest_cancel(skb, nla) cancel nested attribute construction
127 * nla_data(nla) head of attribute payload
128 * nla_len(nla) length of attribute payload
131 * nla_get_u8(nla) get payload for a u8 attribute
132 * nla_get_u16(nla) get payload for a u16 attribute
133 * nla_get_u32(nla) ge
1128 nla_type(const struct nlattr *nla) nla_type() argument
1137 nla_data(const struct nlattr *nla) nla_data() argument
1146 nla_len(const struct nlattr *nla) nla_len() argument
1156 nla_ok(const struct nlattr *nla, int remaining) nla_ok() argument
1171 nla_next(const struct nlattr *nla, int *remaining) nla_next() argument
1187 nla_find_nested(const struct nlattr *nla, int attrtype) nla_find_nested() argument
1202 nla_parse_nested(struct nlattr *tb[], int maxtype, const struct nlattr *nla, const struct nla_policy *policy, struct netlink_ext_ack *extack) nla_parse_nested() argument
1226 nla_parse_nested_deprecated(struct nlattr *tb[], int maxtype, const struct nlattr *nla, const struct nla_policy *policy, struct netlink_ext_ack *extack) nla_parse_nested_deprecated() argument
1552 nla_get_u32(const struct nlattr *nla) nla_get_u32() argument
1561 nla_get_be32(const struct nlattr *nla) nla_get_be32() argument
1570 nla_get_le32(const struct nlattr *nla) nla_get_le32() argument
1579 nla_get_u16(const struct nlattr *nla) nla_get_u16() argument
1588 nla_get_be16(const struct nlattr *nla) nla_get_be16() argument
1597 nla_get_le16(const struct nlattr *nla) nla_get_le16() argument
1606 nla_get_u8(const struct nlattr *nla) nla_get_u8() argument
1615 nla_get_u64(const struct nlattr *nla) nla_get_u64() argument
1628 nla_get_be64(const struct nlattr *nla) nla_get_be64() argument
1641 nla_get_le64(const struct nlattr *nla) nla_get_le64() argument
1650 nla_get_s32(const struct nlattr *nla) nla_get_s32() argument
1659 nla_get_s16(const struct nlattr *nla) nla_get_s16() argument
1668 nla_get_s8(const struct nlattr *nla) nla_get_s8() argument
1677 nla_get_s64(const struct nlattr *nla) nla_get_s64() argument
1690 nla_get_flag(const struct nlattr *nla) nla_get_flag() argument
1701 nla_get_msecs(const struct nlattr *nla) nla_get_msecs() argument
1712 nla_get_in_addr(const struct nlattr *nla) nla_get_in_addr() argument
1721 nla_get_in6_addr(const struct nlattr *nla) nla_get_in6_addr() argument
1733 nla_get_bitfield32(const struct nlattr *nla) nla_get_bitfield32() argument
1939 nla_is_last(const struct nlattr *nla, int rem) nla_is_last() argument
[all...]
/kernel/linux/linux-6.6/include/net/
H A Dnetlink.h84 * <- nla_len(nla) -> ^
85 * nla_data(nla)----^ |
86 * nla_next(nla)-----------------------------'
118 * nla_nest_end(skb, nla) finalize a nested attribute
119 * nla_nest_cancel(skb, nla) cancel nested attribute construction
127 * nla_data(nla) head of attribute payload
128 * nla_len(nla) length of attribute payload
131 * nla_get_u8(nla) get payload for a u8 attribute
132 * nla_get_u16(nla) get payload for a u16 attribute
133 * nla_get_u32(nla) ge
1174 nla_type(const struct nlattr *nla) nla_type() argument
1183 nla_data(const struct nlattr *nla) nla_data() argument
1192 nla_len(const struct nlattr *nla) nla_len() argument
1202 nla_ok(const struct nlattr *nla, int remaining) nla_ok() argument
1217 nla_next(const struct nlattr *nla, int *remaining) nla_next() argument
1233 nla_find_nested(const struct nlattr *nla, int attrtype) nla_find_nested() argument
1248 nla_parse_nested(struct nlattr *tb[], int maxtype, const struct nlattr *nla, const struct nla_policy *policy, struct netlink_ext_ack *extack) nla_parse_nested() argument
1272 nla_parse_nested_deprecated(struct nlattr *tb[], int maxtype, const struct nlattr *nla, const struct nla_policy *policy, struct netlink_ext_ack *extack) nla_parse_nested_deprecated() argument
1598 nla_get_u32(const struct nlattr *nla) nla_get_u32() argument
1607 nla_get_be32(const struct nlattr *nla) nla_get_be32() argument
1616 nla_get_le32(const struct nlattr *nla) nla_get_le32() argument
1625 nla_get_u16(const struct nlattr *nla) nla_get_u16() argument
1634 nla_get_be16(const struct nlattr *nla) nla_get_be16() argument
1643 nla_get_le16(const struct nlattr *nla) nla_get_le16() argument
1652 nla_get_u8(const struct nlattr *nla) nla_get_u8() argument
1661 nla_get_u64(const struct nlattr *nla) nla_get_u64() argument
1674 nla_get_be64(const struct nlattr *nla) nla_get_be64() argument
1687 nla_get_le64(const struct nlattr *nla) nla_get_le64() argument
1696 nla_get_s32(const struct nlattr *nla) nla_get_s32() argument
1705 nla_get_s16(const struct nlattr *nla) nla_get_s16() argument
1714 nla_get_s8(const struct nlattr *nla) nla_get_s8() argument
1723 nla_get_s64(const struct nlattr *nla) nla_get_s64() argument
1736 nla_get_flag(const struct nlattr *nla) nla_get_flag() argument
1747 nla_get_msecs(const struct nlattr *nla) nla_get_msecs() argument
1758 nla_get_in_addr(const struct nlattr *nla) nla_get_in_addr() argument
1767 nla_get_in6_addr(const struct nlattr *nla) nla_get_in6_addr() argument
1779 nla_get_bitfield32(const struct nlattr *nla) nla_get_bitfield32() argument
1985 nla_is_last(const struct nlattr *nla, int rem) nla_is_last() argument
[all...]
/kernel/linux/linux-6.6/net/netfilter/
H A Dnf_tables_api.c137 const struct nlattr * const *nla) in nft_ctx_init()
144 ctx->nla = nla; in nft_ctx_init()
430 if (ctx->nla[NFTA_CHAIN_ID]) { in nft_trans_chain_add()
432 ntohl(nla_get_be32(ctx->nla[NFTA_CHAIN_ID])); in nft_trans_chain_add()
503 if (msg_type == NFT_MSG_NEWRULE && ctx->nla[NFTA_RULE_ID] != NULL) { in nft_trans_rule_add()
505 ntohl(nla_get_be32(ctx->nla[NFTA_RULE_ID])); in nft_trans_rule_add()
569 if (msg_type == NFT_MSG_NEWSET && ctx->nla[NFTA_SET_ID] && !desc) { in __nft_trans_set_add()
571 ntohl(nla_get_be32(ctx->nla[NFTA_SET_ID])); in __nft_trans_set_add()
782 const struct nlattr *nla, in nft_table_lookup()
130 nft_ctx_init(struct nft_ctx *ctx, struct net *net, const struct sk_buff *skb, const struct nlmsghdr *nlh, u8 family, struct nft_table *table, struct nft_chain *chain, const struct nlattr * const *nla) nft_ctx_init() argument
781 nft_table_lookup(const struct net *net, const struct nlattr *nla, u8 family, u8 genmask, u32 nlpid) nft_table_lookup() argument
808 nft_table_lookup_byhandle(const struct net *net, const struct nlattr *nla, int family, u8 genmask, u32 nlpid) nft_table_lookup_byhandle() argument
849 __nf_tables_chain_type_lookup(const struct nlattr *nla, u8 family) __nf_tables_chain_type_lookup() argument
919 nf_tables_chain_type_lookup(struct net *net, const struct nlattr *nla, u8 family, bool autoload) nf_tables_chain_type_lookup() argument
1104 nf_tables_gettable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_gettable() argument
1337 nf_tables_newtable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newtable() argument
1505 const struct nlattr * const *nla = ctx->nla; nft_flush() local
1535 nf_tables_deltable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_deltable() argument
1640 nft_chain_lookup(struct net *net, struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_chain_lookup() argument
1928 nf_tables_getchain(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getchain() argument
2209 nft_chain_parse_hook(struct net *net, struct nft_base_chain *basechain, const struct nlattr * const nla[], struct nft_chain_hook *hook, u8 family, u32 flags, struct netlink_ext_ack *extack) nft_chain_parse_hook() argument
2409 const struct nlattr * const *nla = ctx->nla; nf_tables_addchain() local
2552 const struct nlattr * const *nla = ctx->nla; nf_tables_updchain() local
2720 nft_chain_lookup_byid(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_chain_lookup_byid() argument
2740 nf_tables_newchain(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newchain() argument
2846 const struct nlattr * const *nla = ctx->nla; nft_delchain_hook() local
2891 nf_tables_delchain(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delchain() argument
3011 __nft_expr_type_get(u8 family, struct nlattr *nla) __nft_expr_type_get() argument
3028 nft_expr_type_request_module(struct net *net, u8 family, struct nlattr *nla) nft_expr_type_request_module() argument
3039 nft_expr_type_get(struct net *net, u8 family, struct nlattr *nla) nft_expr_type_get() argument
3118 nf_tables_expr_parse(const struct nft_ctx *ctx, const struct nlattr *nla, struct nft_expr_info *info) nf_tables_expr_parse() argument
3172 nft_expr_inner_parse(const struct nft_ctx *ctx, const struct nlattr *nla, struct nft_expr_info *info) nft_expr_inner_parse() argument
3239 nft_expr_init(const struct nft_ctx *ctx, const struct nlattr *nla) nft_expr_init() argument
3319 nft_rule_lookup(const struct nft_chain *chain, const struct nlattr *nla) nft_rule_lookup() argument
3574 const struct nlattr * const *nla = cb->data; nf_tables_dump_rules_start() local
3618 nf_tables_getrule(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getrule() argument
3821 nf_tables_newrule(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newrule() argument
4059 nft_rule_lookup_byid(const struct net *net, const struct nft_chain *chain, const struct nlattr *nla) nft_rule_lookup_byid() argument
4076 nf_tables_delrule(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delrule() argument
4184 nft_select_set_ops(const struct nft_ctx *ctx, const struct nlattr * const nla[], const struct nft_set_desc *desc) nft_select_set_ops() argument
4276 nft_set_lookup(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup() argument
4292 nft_set_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup_byhandle() argument
4306 nft_set_lookup_byid(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup_byid() argument
4404 nf_msecs_to_jiffies64(const struct nlattr *nla, u64 *result) nf_msecs_to_jiffies64() argument
4669 nf_tables_getset(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getset() argument
4761 nft_set_desc_concat(struct nft_set_desc *desc, const struct nlattr *nla) nft_set_desc_concat() argument
4790 nf_tables_set_desc_parse(struct nft_set_desc *desc, const struct nlattr *nla) nf_tables_set_desc_parse() argument
4809 nft_set_expr_alloc(struct nft_ctx *ctx, struct nft_set *set, const struct nlattr * const *nla, struct nft_expr **exprs, int *num_exprs, u32 flags) nft_set_expr_alloc() argument
4890 nf_tables_newset(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newset() argument
5218 nf_tables_delset(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delset() argument
5972 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_get_set_elem() local
6027 nf_tables_getsetelem(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getsetelem() argument
6531 nft_setelem_valid_key_end(const struct nft_set *set, struct nlattr **nla, u32 flags) nft_setelem_valid_key_end() argument
6554 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_add_set_elem() local
6923 nf_tables_newsetelem(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newsetelem() argument
7025 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_del_setelem() local
7203 nf_tables_delsetelem(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delsetelem() argument
7291 nft_obj_lookup(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u32 objtype, u8 genmask) nft_obj_lookup() argument
7325 nft_obj_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u32 objtype, u8 genmask) nft_obj_lookup_byhandle() argument
7493 nf_tables_newobj(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newobj() argument
7735 const struct nlattr * const *nla = cb->data; nf_tables_dump_obj_start() local
7772 nf_tables_getobj(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getobj() argument
7861 nf_tables_delobj(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delobj() argument
8002 nft_flowtable_lookup(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_flowtable_lookup() argument
8034 nft_flowtable_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_flowtable_lookup_byhandle() argument
8059 nft_flowtable_parse_hook(const struct nft_ctx *ctx, const struct nlattr * const nla[], struct nft_flowtable_hook *flowtable_hook, struct nft_flowtable *flowtable, struct netlink_ext_ack *extack, bool add) nft_flowtable_parse_hook() argument
8260 const struct nlattr * const *nla = ctx->nla; nft_flowtable_update() local
8330 nf_tables_newflowtable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_newflowtable() argument
8477 const struct nlattr * const *nla = ctx->nla; nft_delflowtable_hook() local
8522 nf_tables_delflowtable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_delflowtable() argument
8695 const struct nlattr * const *nla = cb->data; nf_tables_dump_flowtable_start() local
8729 nf_tables_getflowtable(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getflowtable() argument
8936 nf_tables_getgen(struct sk_buff *skb, const struct nfnl_info *info, const struct nlattr * const nla[]) nf_tables_getgen() argument
10861 nft_verdict_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_verdict_init() argument
10967 nft_value_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_value_init() argument
11015 nft_data_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_data_init() argument
[all...]
/kernel/linux/linux-5.10/net/netfilter/
H A Dnf_tables_api.c140 const struct nlattr * const *nla) in nft_ctx_init()
147 ctx->nla = nla; in nft_ctx_init()
434 if (ctx->nla[NFTA_CHAIN_ID]) { in nft_trans_chain_add()
436 ntohl(nla_get_be32(ctx->nla[NFTA_CHAIN_ID])); in nft_trans_chain_add()
507 if (msg_type == NFT_MSG_NEWRULE && ctx->nla[NFTA_RULE_ID] != NULL) { in nft_trans_rule_add()
509 ntohl(nla_get_be32(ctx->nla[NFTA_RULE_ID])); in nft_trans_rule_add()
572 if (msg_type == NFT_MSG_NEWSET && ctx->nla[NFTA_SET_ID] != NULL) { in nft_trans_set_add()
574 ntohl(nla_get_be32(ctx->nla[NFTA_SET_ID])); in nft_trans_set_add()
693 const struct nlattr *nla, in nft_table_lookup()
133 nft_ctx_init(struct nft_ctx *ctx, struct net *net, const struct sk_buff *skb, const struct nlmsghdr *nlh, u8 family, struct nft_table *table, struct nft_chain *chain, const struct nlattr * const *nla) nft_ctx_init() argument
692 nft_table_lookup(const struct net *net, const struct nlattr *nla, u8 family, u8 genmask) nft_table_lookup() argument
714 nft_table_lookup_byhandle(const struct net *net, const struct nlattr *nla, u8 genmask) nft_table_lookup_byhandle() argument
749 __nf_tables_chain_type_lookup(const struct nlattr *nla, u8 family) __nf_tables_chain_type_lookup() argument
817 nf_tables_chain_type_lookup(struct net *net, const struct nlattr *nla, u8 family, bool autoload) nf_tables_chain_type_lookup() argument
987 nf_tables_gettable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_gettable() argument
1214 nf_tables_newtable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newtable() argument
1379 const struct nlattr * const *nla = ctx->nla; nft_flush() local
1405 nf_tables_deltable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_deltable() argument
1505 nft_chain_lookup(struct net *net, struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_chain_lookup() argument
1777 nf_tables_getchain(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getchain() argument
2054 nft_chain_parse_hook(struct net *net, const struct nlattr * const nla[], struct nft_chain_hook *hook, u8 family, bool autoload) nft_chain_parse_hook() argument
2213 const struct nlattr * const *nla = ctx->nla; nf_tables_addchain() local
2374 const struct nlattr * const *nla = ctx->nla; nf_tables_updchain() local
2493 nft_chain_lookup_byid(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_chain_lookup_byid() argument
2513 nf_tables_newchain(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newchain() argument
2611 nf_tables_delchain(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delchain() argument
2715 __nft_expr_type_get(u8 family, struct nlattr *nla) __nft_expr_type_get() argument
2732 nft_expr_type_request_module(struct net *net, u8 family, struct nlattr *nla) nft_expr_type_request_module() argument
2743 nft_expr_type_get(struct net *net, u8 family, struct nlattr *nla) nft_expr_type_get() argument
2822 nf_tables_expr_parse(const struct nft_ctx *ctx, const struct nlattr *nla, struct nft_expr_info *info) nf_tables_expr_parse() argument
2906 nft_expr_init(const struct nft_ctx *ctx, const struct nlattr *nla) nft_expr_init() argument
2986 nft_rule_lookup(const struct nft_chain *chain, const struct nlattr *nla) nft_rule_lookup() argument
3197 const struct nlattr * const *nla = cb->data; nf_tables_dump_rules_start() local
3241 nf_tables_getrule(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getrule() argument
3383 nf_tables_newrule(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newrule() argument
3617 nft_rule_lookup_byid(const struct net *net, const struct nft_chain *chain, const struct nlattr *nla) nft_rule_lookup_byid() argument
3636 nf_tables_delrule(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delrule() argument
3735 nft_select_set_ops(const struct nft_ctx *ctx, const struct nlattr * const nla[], const struct nft_set_desc *desc, enum nft_set_policies policy) nft_select_set_ops() argument
3827 nft_ctx_init_from_setattr(struct nft_ctx *ctx, struct net *net, const struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack, u8 genmask) nft_ctx_init_from_setattr() argument
3851 nft_set_lookup(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup() argument
3867 nft_set_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup_byhandle() argument
3881 nft_set_lookup_byid(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_set_lookup_byid() argument
3979 nf_msecs_to_jiffies64(const struct nlattr *nla, u64 *result) nf_msecs_to_jiffies64() argument
4220 nf_tables_getset(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getset() argument
4306 nft_set_desc_concat(struct nft_set_desc *desc, const struct nlattr *nla) nft_set_desc_concat() argument
4335 nf_tables_set_desc_parse(struct nft_set_desc *desc, const struct nlattr *nla) nf_tables_set_desc_parse() argument
4354 nf_tables_newset(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newset() argument
4637 nf_tables_delset(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delset() argument
4907 nft_ctx_init_from_elemattr(struct nft_ctx *ctx, struct net *net, const struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack, u8 genmask) nft_ctx_init_from_elemattr() argument
5221 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_get_set_elem() local
5276 nf_tables_getsetelem(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getsetelem() argument
5496 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_add_set_elem() local
5780 nf_tables_newsetelem(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newsetelem() argument
5874 struct nlattr *nla[NFTA_SET_ELEM_MAX + 1]; nft_del_setelem() local
5983 nf_tables_delsetelem(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delsetelem() argument
6066 nft_obj_lookup(const struct net *net, const struct nft_table *table, const struct nlattr *nla, u32 objtype, u8 genmask) nft_obj_lookup() argument
6100 nft_obj_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u32 objtype, u8 genmask) nft_obj_lookup_byhandle() argument
6264 nf_tables_newobj(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newobj() argument
6490 const struct nlattr * const *nla = cb->data; nf_tables_dump_obj_start() local
6527 nf_tables_getobj(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getobj() argument
6617 nf_tables_delobj(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delobj() argument
6741 nft_flowtable_lookup(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_flowtable_lookup() argument
6773 nft_flowtable_lookup_byhandle(const struct nft_table *table, const struct nlattr *nla, u8 genmask) nft_flowtable_lookup_byhandle() argument
6993 const struct nlattr * const *nla = ctx->nla; nft_flowtable_update() local
7063 nf_tables_newflowtable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_newflowtable() argument
7210 const struct nlattr * const *nla = ctx->nla; nft_delflowtable_hook() local
7255 nf_tables_delflowtable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_delflowtable() argument
7416 const struct nlattr * const *nla = cb->data; nf_tables_dump_flowtable_start() local
7450 nf_tables_getflowtable(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getflowtable() argument
7656 nf_tables_getgen(struct net *net, struct sock *nlsk, struct sk_buff *skb, const struct nlmsghdr *nlh, const struct nlattr * const nla[], struct netlink_ext_ack *extack) nf_tables_getgen() argument
9322 nft_verdict_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_verdict_init() argument
9428 nft_value_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_value_init() argument
9476 nft_data_init(const struct nft_ctx *ctx, struct nft_data *data, struct nft_data_desc *desc, const struct nlattr *nla) nft_data_init() argument
[all...]
/kernel/linux/linux-5.10/net/wimax/
H A Dop-msg.c172 struct nlattr *nla; in wimax_msg_data_len() local
174 nla = nlmsg_find_attr(nlh, sizeof(struct genlmsghdr), in wimax_msg_data_len()
176 if (nla == NULL) { in wimax_msg_data_len()
180 *size = nla_len(nla); in wimax_msg_data_len()
181 return nla_data(nla); in wimax_msg_data_len()
194 struct nlattr *nla; in wimax_msg_data() local
196 nla = nlmsg_find_attr(nlh, sizeof(struct genlmsghdr), in wimax_msg_data()
198 if (nla == NULL) { in wimax_msg_data()
202 return nla_data(nla); in wimax_msg_data()
215 struct nlattr *nla; in wimax_msg_len() local
[all...]
/kernel/linux/linux-5.10/net/ipv4/
H A Dmetrics.c15 struct nlattr *nla; in ip_metrics_convert() local
21 nla_for_each_attr(nla, fc_mx, fc_mx_len, remaining) { in ip_metrics_convert()
22 int type = nla_type(nla); in ip_metrics_convert()
36 nla_strlcpy(tmp, nla, sizeof(tmp)); in ip_metrics_convert()
43 if (nla_len(nla) != sizeof(u32)) { in ip_metrics_convert()
44 NL_SET_ERR_MSG_ATTR(extack, nla, in ip_metrics_convert()
48 val = nla_get_u32(nla); in ip_metrics_convert()
/kernel/linux/linux-6.6/net/ipv4/
H A Dmetrics.c15 struct nlattr *nla; in ip_metrics_convert() local
18 nla_for_each_attr(nla, fc_mx, fc_mx_len, remaining) { in ip_metrics_convert()
19 int type = nla_type(nla); in ip_metrics_convert()
33 nla_strscpy(tmp, nla, sizeof(tmp)); in ip_metrics_convert()
40 if (nla_len(nla) != sizeof(u32)) { in ip_metrics_convert()
41 NL_SET_ERR_MSG_ATTR(extack, nla, in ip_metrics_convert()
45 val = nla_get_u32(nla); in ip_metrics_convert()
/kernel/linux/linux-5.10/include/linux/
H A Dgenl_magic_func.h99 * nla is supposed to point to the attribute containing the information
101 #define DPRINT_FIELD(dir, nla_type, name, s, nla) \
105 else if (nla) \
108 : nla_data(nla)); \
111 #define DPRINT_ARRAY(dir, nla_type, name, s, nla) \
116 else if (nla) \
118 nla_data(nla), nla_len(nla)); \
122 #define DPRINT_FIELD(dir, nla_type, name, s, nla) do {} while (0)
123 #define DPRINT_ARRAY(dir, nla_type, name, s, nla) d
[all...]
/kernel/linux/linux-6.6/include/linux/
H A Dgenl_magic_func.h100 * nla is supposed to point to the attribute containing the information
102 #define DPRINT_FIELD(dir, nla_type, name, s, nla) \
106 else if (nla) \
109 : nla_data(nla)); \
112 #define DPRINT_ARRAY(dir, nla_type, name, s, nla) \
117 else if (nla) \
119 nla_data(nla), nla_len(nla)); \
123 #define DPRINT_FIELD(dir, nla_type, name, s, nla) do {} while (0)
124 #define DPRINT_ARRAY(dir, nla_type, name, s, nla) d
[all...]
/kernel/linux/linux-5.10/net/sched/
H A Dact_tunnel_key.c87 tunnel_key_copy_geneve_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_geneve_opt() argument
96 nla, geneve_opt_policy, extack); in tunnel_key_copy_geneve_opt()
139 tunnel_key_copy_vxlan_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_vxlan_opt() argument
145 err = nla_parse_nested(tb, TCA_TUNNEL_KEY_ENC_OPT_VXLAN_MAX, nla, in tunnel_key_copy_vxlan_opt()
166 tunnel_key_copy_erspan_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_erspan_opt() argument
173 err = nla_parse_nested(tb, TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_MAX, nla, in tunnel_key_copy_erspan_opt()
205 nla = tb[TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_INDEX]; in tunnel_key_copy_erspan_opt()
206 md->u.index = nla_get_be32(nla); in tunnel_key_copy_erspan_opt()
208 nla = tb[TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_DIR]; in tunnel_key_copy_erspan_opt()
209 md->u.md2.dir = nla_get_u8(nla); in tunnel_key_copy_erspan_opt()
218 tunnel_key_copy_opts(const struct nlattr *nla, u8 *dst, int dst_len, struct netlink_ext_ack *extack) tunnel_key_copy_opts() argument
291 tunnel_key_get_opts_len(struct nlattr *nla, struct netlink_ext_ack *extack) tunnel_key_get_opts_len() argument
297 tunnel_key_opts_set(struct nlattr *nla, struct ip_tunnel_info *info, int opts_len, struct netlink_ext_ack *extack) tunnel_key_opts_set() argument
356 tunnel_key_init(struct net *net, struct nlattr *nla, struct nlattr *est, struct tc_action **a, int ovr, int bind, bool rtnl_held, struct tcf_proto *tp, u32 act_flags, struct netlink_ext_ack *extack) tunnel_key_init() argument
[all...]
H A Dact_bpf.c101 struct nlattr *nla; in tcf_bpf_dump_bpf_info() local
106 nla = nla_reserve(skb, TCA_ACT_BPF_OPS, prog->bpf_num_ops * in tcf_bpf_dump_bpf_info()
108 if (nla == NULL) in tcf_bpf_dump_bpf_info()
111 memcpy(nla_data(nla), prog->bpf_ops, nla_len(nla)); in tcf_bpf_dump_bpf_info()
119 struct nlattr *nla; in tcf_bpf_dump_ebpf_info() local
128 nla = nla_reserve(skb, TCA_ACT_BPF_TAG, sizeof(prog->filter->tag)); in tcf_bpf_dump_ebpf_info()
129 if (nla == NULL) in tcf_bpf_dump_ebpf_info()
132 memcpy(nla_data(nla), prog->filter->tag, nla_len(nla)); in tcf_bpf_dump_ebpf_info()
278 tcf_bpf_init(struct net *net, struct nlattr *nla, struct nlattr *est, struct tc_action **act, int replace, int bind, bool rtnl_held, struct tcf_proto *tp, u32 flags, struct netlink_ext_ack *extack) tcf_bpf_init() argument
[all...]
/kernel/linux/linux-6.6/net/sched/
H A Dact_tunnel_key.c88 tunnel_key_copy_geneve_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_geneve_opt() argument
97 nla, geneve_opt_policy, extack); in tunnel_key_copy_geneve_opt()
140 tunnel_key_copy_vxlan_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_vxlan_opt() argument
146 err = nla_parse_nested(tb, TCA_TUNNEL_KEY_ENC_OPT_VXLAN_MAX, nla, in tunnel_key_copy_vxlan_opt()
167 tunnel_key_copy_erspan_opt(const struct nlattr *nla, void *dst, int dst_len, in tunnel_key_copy_erspan_opt() argument
174 err = nla_parse_nested(tb, TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_MAX, nla, in tunnel_key_copy_erspan_opt()
206 nla = tb[TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_INDEX]; in tunnel_key_copy_erspan_opt()
207 md->u.index = nla_get_be32(nla); in tunnel_key_copy_erspan_opt()
209 nla = tb[TCA_TUNNEL_KEY_ENC_OPT_ERSPAN_DIR]; in tunnel_key_copy_erspan_opt()
210 md->u.md2.dir = nla_get_u8(nla); in tunnel_key_copy_erspan_opt()
219 tunnel_key_copy_opts(const struct nlattr *nla, u8 *dst, int dst_len, struct netlink_ext_ack *extack) tunnel_key_copy_opts() argument
292 tunnel_key_get_opts_len(struct nlattr *nla, struct netlink_ext_ack *extack) tunnel_key_get_opts_len() argument
298 tunnel_key_opts_set(struct nlattr *nla, struct ip_tunnel_info *info, int opts_len, struct netlink_ext_ack *extack) tunnel_key_opts_set() argument
357 tunnel_key_init(struct net *net, struct nlattr *nla, struct nlattr *est, struct tc_action **a, struct tcf_proto *tp, u32 act_flags, struct netlink_ext_ack *extack) tunnel_key_init() argument
[all...]
H A Dact_bpf.c102 struct nlattr *nla; in tcf_bpf_dump_bpf_info() local
107 nla = nla_reserve(skb, TCA_ACT_BPF_OPS, prog->bpf_num_ops * in tcf_bpf_dump_bpf_info()
109 if (nla == NULL) in tcf_bpf_dump_bpf_info()
112 memcpy(nla_data(nla), prog->bpf_ops, nla_len(nla)); in tcf_bpf_dump_bpf_info()
120 struct nlattr *nla; in tcf_bpf_dump_ebpf_info() local
129 nla = nla_reserve(skb, TCA_ACT_BPF_TAG, sizeof(prog->filter->tag)); in tcf_bpf_dump_ebpf_info()
130 if (nla == NULL) in tcf_bpf_dump_ebpf_info()
133 memcpy(nla_data(nla), prog->filter->tag, nla_len(nla)); in tcf_bpf_dump_ebpf_info()
279 tcf_bpf_init(struct net *net, struct nlattr *nla, struct nlattr *est, struct tc_action **act, struct tcf_proto *tp, u32 flags, struct netlink_ext_ack *extack) tcf_bpf_init() argument
[all...]
/kernel/linux/linux-5.10/net/xfrm/
H A Dxfrm_compat.c292 const struct nlattr *nla, *attrs; in xfrm_xlate64() local
303 nla_for_each_attr(nla, attrs, len, remaining) { in xfrm_xlate64()
308 err = xfrm_nla_cpy(dst, nla, nla_len(nla)); in xfrm_xlate64()
311 err = xfrm_xlate64_attr(dst, nla); in xfrm_xlate64()
403 struct nlattr *nla; in xfrm_attr_cpy32() local
415 nla = dst + *pos; in xfrm_attr_cpy32()
417 memcpy(nla, src, nla_attr_size(copy_len)); in xfrm_attr_cpy32()
418 nla->nla_len = nla_attr_size(payload); in xfrm_attr_cpy32()
420 nlmsg->nlmsg_len += nla in xfrm_attr_cpy32()
428 xfrm_xlate32_attr(void *dst, const struct nlattr *nla, size_t *pos, size_t size, struct netlink_ext_ack *extack) xfrm_xlate32_attr() argument
[all...]
/kernel/linux/linux-6.6/net/xfrm/
H A Dxfrm_compat.c292 const struct nlattr *nla, *attrs; in xfrm_xlate64() local
303 nla_for_each_attr(nla, attrs, len, remaining) { in xfrm_xlate64()
308 err = xfrm_nla_cpy(dst, nla, nla_len(nla)); in xfrm_xlate64()
311 err = xfrm_xlate64_attr(dst, nla); in xfrm_xlate64()
403 struct nlattr *nla; in xfrm_attr_cpy32() local
415 nla = dst + *pos; in xfrm_attr_cpy32()
417 memcpy(nla, src, nla_attr_size(copy_len)); in xfrm_attr_cpy32()
418 nla->nla_len = nla_attr_size(payload); in xfrm_attr_cpy32()
420 nlmsg->nlmsg_len += nla in xfrm_attr_cpy32()
428 xfrm_xlate32_attr(void *dst, const struct nlattr *nla, size_t *pos, size_t size, struct netlink_ext_ack *extack) xfrm_xlate32_attr() argument
[all...]
/kernel/linux/linux-6.6/drivers/net/vxlan/
H A Dvxlan_private.h89 const struct nlattr *nla) in vxlan_nla_get_addr()
91 if (nla_len(nla) >= sizeof(struct in6_addr)) { in vxlan_nla_get_addr()
92 ip->sin6.sin6_addr = nla_get_in6_addr(nla); in vxlan_nla_get_addr()
95 } else if (nla_len(nla) >= sizeof(__be32)) { in vxlan_nla_get_addr()
96 ip->sin.sin_addr.s_addr = nla_get_in_addr(nla); in vxlan_nla_get_addr()
130 const struct nlattr *nla) in vxlan_nla_get_addr()
132 if (nla_len(nla) >= sizeof(struct in6_addr)) { in vxlan_nla_get_addr()
134 } else if (nla_len(nla) >= sizeof(__be32)) { in vxlan_nla_get_addr()
135 ip->sin.sin_addr.s_addr = nla_get_in_addr(nla); in vxlan_nla_get_addr()
88 vxlan_nla_get_addr(union vxlan_addr *ip, const struct nlattr *nla) vxlan_nla_get_addr() argument
129 vxlan_nla_get_addr(union vxlan_addr *ip, const struct nlattr *nla) vxlan_nla_get_addr() argument

Completed in 27 milliseconds

12345678910