From patchwork Wed Dec 17 00:04:21 2008 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: gregkh@suse.de X-Patchwork-Id: 14379 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id EB6DADDF66 for ; Wed, 17 Dec 2008 11:06:58 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759780AbYLQAGT (ORCPT ); Tue, 16 Dec 2008 19:06:19 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1759680AbYLQAGG (ORCPT ); Tue, 16 Dec 2008 19:06:06 -0500 Received: from kroah.org ([198.145.64.141]:41292 "EHLO coco.kroah.org" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1759346AbYLQAGD (ORCPT ); Tue, 16 Dec 2008 19:06:03 -0500 Received: from localhost (mail.kroah.net [66.93.40.174]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by coco.kroah.org (Postfix) with ESMTPSA id B975F49049; Tue, 16 Dec 2008 16:06:01 -0800 (PST) Date: Tue, 16 Dec 2008 16:04:21 -0800 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org, David Miller Cc: Justin Forbes , Zwane Mwaikambo , Theodore Ts'o , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , Willy Tarreau , Rodrigo Rubira Branco , Jake Edge , Eugene Teo , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, netdev@vger.kernel.org, Stephen Hemminger , Herbert Xu Subject: [patch 11/22] net: eliminate warning from NETIF_F_UFO on bridge Message-ID: <20081217000421.GL4504@kroah.com> References: <20081216235704.347182084@mini.kroah.org> MIME-Version: 1.0 Content-Disposition: inline; filename="net-eliminate-warning-from-netif_f_ufo-on-bridge.patch" In-Reply-To: <20081217000306.GA4504@kroah.com> User-Agent: Mutt/1.5.16 (2007-06-09) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org 2.6.27-stable review patch. If anyone has any objections, please let us know. ------------------ From: Stephen Hemminger Based on commit b63365a2d60268a3988285d6c3c6003d7066f93a upstream, but drastically cut down for 2.6.27.y The bridge device always causes a warning because when it is first created it has the no checksum flag set along with all the segmentation/fragmentation offload bits. The code in register_netdevice incorrectly checks for only hardware checksum bit and ignores no checksum bit. Similar code is already in 2.6.28: commit b63365a2d60268a3988285d6c3c6003d7066f93a net: Fix disjunct computation of netdev features Signed-off-by: Stephen Hemminger Cc: David Miller Cc: Herbert Xu Signed-off-by: Greg Kroah-Hartman --- net/core/dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/net/core/dev.c +++ b/net/core/dev.c @@ -3990,7 +3990,7 @@ int register_netdevice(struct net_device dev->features &= ~NETIF_F_TSO; } if (dev->features & NETIF_F_UFO) { - if (!(dev->features & NETIF_F_HW_CSUM)) { + if (!(dev->features & NETIF_F_GEN_CSUM)) { printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " "NETIF_F_HW_CSUM feature.\n", dev->name);