aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/cls_api.c
diff options
context:
space:
mode:
authorEric Dumazet <dada1@cosmosbay.com>2007-11-14 04:44:41 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 17:53:58 -0500
commit20fea08b5fb639c4c175b5c74a2bb346c5c5bc2e (patch)
tree3ffa7e1e82051c6772fc2a01d561e4a5a29bb138 /net/sched/cls_api.c
parent2a8cc6c89039e0530a3335954253b76ed0f9339a (diff)
[NET]: Move Qdisc_class_ops and Qdisc_ops in appropriate sections.
Qdisc_class_ops are const, and Qdisc_ops are mostly read. Using "const" and "__read_mostly" qualifiers helps to reduce false sharing. Signed-off-by: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/cls_api.c')
-rw-r--r--net/sched/cls_api.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
index 03657976fd50..bb98045d5508 100644
--- a/net/sched/cls_api.c
+++ b/net/sched/cls_api.c
@@ -130,7 +130,7 @@ static int tc_ctl_tfilter(struct sk_buff *skb, struct nlmsghdr *n, void *arg)
130 struct tcf_proto **back, **chain; 130 struct tcf_proto **back, **chain;
131 struct tcf_proto *tp; 131 struct tcf_proto *tp;
132 struct tcf_proto_ops *tp_ops; 132 struct tcf_proto_ops *tp_ops;
133 struct Qdisc_class_ops *cops; 133 const struct Qdisc_class_ops *cops;
134 unsigned long cl; 134 unsigned long cl;
135 unsigned long fh; 135 unsigned long fh;
136 int err; 136 int err;
@@ -382,7 +382,7 @@ static int tc_dump_tfilter(struct sk_buff *skb, struct netlink_callback *cb)
382 struct tcf_proto *tp, **chain; 382 struct tcf_proto *tp, **chain;
383 struct tcmsg *tcm = (struct tcmsg*)NLMSG_DATA(cb->nlh); 383 struct tcmsg *tcm = (struct tcmsg*)NLMSG_DATA(cb->nlh);
384 unsigned long cl = 0; 384 unsigned long cl = 0;
385 struct Qdisc_class_ops *cops; 385 const struct Qdisc_class_ops *cops;
386 struct tcf_dump_args arg; 386 struct tcf_dump_args arg;
387 387
388 if (cb->nlh->nlmsg_len < NLMSG_LENGTH(sizeof(*tcm))) 388 if (cb->nlh->nlmsg_len < NLMSG_LENGTH(sizeof(*tcm)))