]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - queue-2.6.25/net_sched-cls_api-fix-return-value-for-non-existant-classifiers.patch
Add networking patches to 2.6.25 queue
[thirdparty/kernel/stable-queue.git] / queue-2.6.25 / net_sched-cls_api-fix-return-value-for-non-existant-classifiers.patch
1 From 44a02f11d1d7f26e1ae811009b7ef5a657c2056d Mon Sep 17 00:00:00 2001
2 Message-Id: <20080609.134337.193698173.davem@davemloft.net>
3 From: Patrick McHardy <kaber@trash.net>
4 Date: Tue, 20 May 2008 14:34:46 -0700
5 Subject: net_sched: cls_api: fix return value for non-existant classifiers
6
7 From: Patrick McHardy <kaber@trash.net>
8
9 [ upstream commit: f2df824948d559ea818e03486a8583e42ea6ab37 ]
10
11 cls_api should return ENOENT when the requested classifier doesn't
12 exist.
13
14 Signed-off-by: Patrick McHardy <kaber@trash.net>
15 Signed-off-by: David S. Miller <davem@davemloft.net>
16 Signed-off-by: Chris Wright <chrisw@sous-sol.org>
17 ---
18 net/sched/cls_api.c | 2 +-
19 1 file changed, 1 insertion(+), 1 deletion(-)
20
21 --- a/net/sched/cls_api.c
22 +++ b/net/sched/cls_api.c
23 @@ -220,7 +220,7 @@ replay:
24 tp = kzalloc(sizeof(*tp), GFP_KERNEL);
25 if (tp == NULL)
26 goto errout;
27 - err = -EINVAL;
28 + err = -ENOENT;
29 tp_ops = tcf_proto_lookup_ops(tca[TCA_KIND]);
30 if (tp_ops == NULL) {
31 #ifdef CONFIG_KMOD