linux/net/sched/act_simple.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * net/sched/act_simple.c	Simple example of an action
 *
 * Authors:	Jamal Hadi Salim (2005-8)
 */

#include <linux/module.h>
#include <linux/slab.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/skbuff.h>
#include <linux/rtnetlink.h>
#include <net/netlink.h>
#include <net/pkt_sched.h>
#include <net/pkt_cls.h>
#include <net/tc_wrapper.h>

#include <linux/tc_act/tc_defact.h>
#include <net/tc_act/tc_defact.h>

static struct tc_action_ops act_simp_ops;

#define SIMP_MAX_DATA
TC_INDIRECT_SCOPE int tcf_simp_act(struct sk_buff *skb,
				   const struct tc_action *a,
				   struct tcf_result *res)
{}

static void tcf_simp_release(struct tc_action *a)
{}

static int alloc_defdata(struct tcf_defact *d, const struct nlattr *defdata)
{}

static int reset_policy(struct tc_action *a, const struct nlattr *defdata,
			struct tc_defact *p, struct tcf_proto *tp,
			struct netlink_ext_ack *extack)
{}

static const struct nla_policy simple_policy[TCA_DEF_MAX + 1] =;

static int tcf_simp_init(struct net *net, struct nlattr *nla,
			 struct nlattr *est, struct tc_action **a,
			 struct tcf_proto *tp, u32 flags,
			 struct netlink_ext_ack *extack)
{}

static int tcf_simp_dump(struct sk_buff *skb, struct tc_action *a,
			 int bind, int ref)
{}

static struct tc_action_ops act_simp_ops =;
MODULE_ALIAS_NET_ACT();

static __net_init int simp_init_net(struct net *net)
{}

static void __net_exit simp_exit_net(struct list_head *net_list)
{}

static struct pernet_operations simp_net_ops =;

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();

static int __init simp_init_module(void)
{}

static void __exit simp_cleanup_module(void)
{}

module_init();
module_exit(simp_cleanup_module);