summaryrefslogtreecommitdiff
path: root/include/net/tc_act/tc_nat.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/tc_act/tc_nat.h')
-rw-r--r--include/net/tc_act/tc_nat.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/include/net/tc_act/tc_nat.h b/include/net/tc_act/tc_nat.h
index 4a691f34d703..ae35f4009445 100644
--- a/include/net/tc_act/tc_nat.h
+++ b/include/net/tc_act/tc_nat.h
@@ -1,21 +1,24 @@
+/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __NET_TC_NAT_H
#define __NET_TC_NAT_H
#include <linux/types.h>
#include <net/act_api.h>
-struct tcf_nat {
- struct tcf_common common;
-
+struct tcf_nat_parms {
+ int action;
__be32 old_addr;
__be32 new_addr;
__be32 mask;
u32 flags;
+ struct rcu_head rcu;
+};
+
+struct tcf_nat {
+ struct tc_action common;
+ struct tcf_nat_parms __rcu *parms;
};
-static inline struct tcf_nat *to_tcf_nat(struct tcf_common *pc)
-{
- return container_of(pc, struct tcf_nat, common);
-}
+#define to_tcf_nat(a) ((struct tcf_nat *)a)
#endif /* __NET_TC_NAT_H */