License cleanup: add SPDX GPL-2.0 license identifier to files with no license
[linux-2.6-block.git] / include / net / netfilter / nft_meta.h
CommitLineData
b2441318 1/* SPDX-License-Identifier: GPL-2.0 */
aa45660c
TB
2#ifndef _NFT_META_H_
3#define _NFT_META_H_
4
5struct nft_meta {
6 enum nft_meta_keys key:8;
7 union {
8 enum nft_registers dreg:8;
9 enum nft_registers sreg:8;
10 };
11};
12
13extern const struct nla_policy nft_meta_policy[];
14
15int nft_meta_get_init(const struct nft_ctx *ctx,
16 const struct nft_expr *expr,
17 const struct nlattr * const tb[]);
18
19int nft_meta_set_init(const struct nft_ctx *ctx,
20 const struct nft_expr *expr,
21 const struct nlattr * const tb[]);
22
23int nft_meta_get_dump(struct sk_buff *skb,
24 const struct nft_expr *expr);
25
26int nft_meta_set_dump(struct sk_buff *skb,
27 const struct nft_expr *expr);
28
29void nft_meta_get_eval(const struct nft_expr *expr,
a55e22e9 30 struct nft_regs *regs,
aa45660c
TB
31 const struct nft_pktinfo *pkt);
32
33void nft_meta_set_eval(const struct nft_expr *expr,
a55e22e9 34 struct nft_regs *regs,
aa45660c
TB
35 const struct nft_pktinfo *pkt);
36
e639f7ab
FW
37void nft_meta_set_destroy(const struct nft_ctx *ctx,
38 const struct nft_expr *expr);
39
960fa72f
LZ
40int nft_meta_set_validate(const struct nft_ctx *ctx,
41 const struct nft_expr *expr,
42 const struct nft_data **data);
43
aa45660c 44#endif