Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1763128AbYFNATB (ORCPT ); Fri, 13 Jun 2008 20:19:01 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1761454AbYFNANy (ORCPT ); Fri, 13 Jun 2008 20:13:54 -0400 Received: from mx2.suse.de ([195.135.220.15]:51823 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1761412AbYFNANs (ORCPT ); Fri, 13 Jun 2008 20:13:48 -0400 Date: Fri, 13 Jun 2008 17:11:16 -0700 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , Willy Tarreau , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, Patrick McHardy , "David S. Miller" , Chris Wright Subject: [patch 20/47] net_sched: cls_api: fix return value for non-existant classifiers Message-ID: <20080614001116.GT24698@suse.de> References: <20080613234753.235721454@mini.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="net_sched-cls_api-fix-return-value-for-non-existant-classifiers.patch" In-Reply-To: <20080614000840.GA24659@suse.de> User-Agent: Mutt/1.5.16 (2007-06-09) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1045 Lines: 35 -stable review patch. If anyone has any objections, please let us know. ------------------ From: Patrick McHardy [ upstream commit: f2df824948d559ea818e03486a8583e42ea6ab37 ] cls_api should return ENOENT when the requested classifier doesn't exist. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller Signed-off-by: Chris Wright --- net/sched/cls_api.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/net/sched/cls_api.c +++ b/net/sched/cls_api.c @@ -220,7 +220,7 @@ replay: tp = kzalloc(sizeof(*tp), GFP_KERNEL); if (tp == NULL) goto errout; - err = -EINVAL; + err = -ENOENT; tp_ops = tcf_proto_lookup_ops(tca[TCA_KIND]); if (tp_ops == NULL) { #ifdef CONFIG_KMOD -- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/