aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/cls_cgroup.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sched/cls_cgroup.c')
-rw-r--r--net/sched/cls_cgroup.c27
1 files changed, 11 insertions, 16 deletions
diff --git a/net/sched/cls_cgroup.c b/net/sched/cls_cgroup.c
index 1afaa284fcd7..024df8a32275 100644
--- a/net/sched/cls_cgroup.c
+++ b/net/sched/cls_cgroup.c
@@ -22,22 +22,6 @@
22#include <net/sock.h> 22#include <net/sock.h>
23#include <net/cls_cgroup.h> 23#include <net/cls_cgroup.h>
24 24
25static struct cgroup_subsys_state *cgrp_create(struct cgroup *cgrp);
26static void cgrp_destroy(struct cgroup *cgrp);
27static int cgrp_populate(struct cgroup_subsys *ss, struct cgroup *cgrp);
28
29struct cgroup_subsys net_cls_subsys = {
30 .name = "net_cls",
31 .create = cgrp_create,
32 .destroy = cgrp_destroy,
33 .populate = cgrp_populate,
34#ifdef CONFIG_NET_CLS_CGROUP
35 .subsys_id = net_cls_subsys_id,
36#endif
37 .module = THIS_MODULE,
38};
39
40
41static inline struct cgroup_cls_state *cgrp_cls_state(struct cgroup *cgrp) 25static inline struct cgroup_cls_state *cgrp_cls_state(struct cgroup *cgrp)
42{ 26{
43 return container_of(cgroup_subsys_state(cgrp, net_cls_subsys_id), 27 return container_of(cgroup_subsys_state(cgrp, net_cls_subsys_id),
@@ -93,6 +77,17 @@ static int cgrp_populate(struct cgroup_subsys *ss, struct cgroup *cgrp)
93 return cgroup_add_files(cgrp, ss, ss_files, ARRAY_SIZE(ss_files)); 77 return cgroup_add_files(cgrp, ss, ss_files, ARRAY_SIZE(ss_files));
94} 78}
95 79
80struct cgroup_subsys net_cls_subsys = {
81 .name = "net_cls",
82 .create = cgrp_create,
83 .destroy = cgrp_destroy,
84 .populate = cgrp_populate,
85#ifdef CONFIG_NET_CLS_CGROUP
86 .subsys_id = net_cls_subsys_id,
87#endif
88 .module = THIS_MODULE,
89};
90
96struct cls_cgroup_head { 91struct cls_cgroup_head {
97 u32 handle; 92 u32 handle;
98 struct tcf_exts exts; 93 struct tcf_exts exts;