Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753554Ab1BBBEA (ORCPT ); Tue, 1 Feb 2011 20:04:00 -0500 Received: from mga09.intel.com ([134.134.136.24]:58186 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752671Ab1BBAnw (ORCPT ); Tue, 1 Feb 2011 19:43:52 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.60,412,1291622400"; d="scan'208";a="598622373" From: Andi Kleen References: <20110201443.618138584@firstfloor.org> In-Reply-To: <20110201443.618138584@firstfloor.org> To: davem@davemloft.net, gregkh@suse.de, ak@linux.intel.com, linux-kernel@vger.kernel.org, stable@kernel.org Subject: [PATCH] [47/139] tcp: Make TCP_MAXSEG minimum more correct. Message-Id: <20110202004403.0CEE53E09BD@tassilo.jf.intel.com> Date: Tue, 1 Feb 2011 16:44:02 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1321 Lines: 37 2.6.35-longterm review patch. If anyone has any objections, please let me know. ------------------ From: David S. Miller [ Upstream commit c39508d6f118308355468314ff414644115a07f3 ] Use TCP_MIN_MSS instead of constant 64. Reported-by: Min Zhang Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman Signed-off-by: Andi Kleen --- net/ipv4/tcp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Index: linux-2.6.35.y/net/ipv4/tcp.c =================================================================== --- linux-2.6.35.y.orig/net/ipv4/tcp.c +++ linux-2.6.35.y/net/ipv4/tcp.c @@ -2235,7 +2235,7 @@ static int do_tcp_setsockopt(struct sock /* Values greater than interface MTU won't take effect. However * at the point when this call is done we typically don't yet * know which interface is going to be used */ - if (val < 64 || val > MAX_TCP_WINDOW) { + if (val < TCP_MIN_MSS || val > MAX_TCP_WINDOW) { err = -EINVAL; break; } -- 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/