linux/include/net/netfilter/nf_conntrack_acct.h

/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * (C) 2008 Krzysztof Piotr Oledzki <[email protected]>
 */

#ifndef _NF_CONNTRACK_ACCT_H
#define _NF_CONNTRACK_ACCT_H
#include <net/net_namespace.h>
#include <linux/netfilter/nf_conntrack_common.h>
#include <linux/netfilter/nf_conntrack_tuple_common.h>
#include <net/netfilter/nf_conntrack.h>
#include <net/netfilter/nf_conntrack_extend.h>

struct nf_conn_counter {};

struct nf_conn_acct {};

static inline
struct nf_conn_acct *nf_conn_acct_find(const struct nf_conn *ct)
{}

static inline
struct nf_conn_acct *nf_ct_acct_ext_add(struct nf_conn *ct, gfp_t gfp)
{}

/* Check if connection tracking accounting is enabled */
static inline bool nf_ct_acct_enabled(struct net *net)
{}

/* Enable/disable connection tracking accounting */
static inline void nf_ct_set_acct(struct net *net, bool enable)
{}

void nf_ct_acct_add(struct nf_conn *ct, u32 dir, unsigned int packets,
		    unsigned int bytes);

static inline void nf_ct_acct_update(struct nf_conn *ct, u32 dir,
				     unsigned int bytes)
{}

void nf_conntrack_acct_pernet_init(struct net *net);

#endif /* _NF_CONNTRACK_ACCT_H */