public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Eduard Roccatello <lilo@roccatello.it>
To: Andrew Morton <akpm@osdl.org>, Linus Torvalds <torvalds@osdl.org>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] net/ipv4/tcp.c little cleanup
Date: Thu, 22 Jan 2004 22:53:37 +0100	[thread overview]
Message-ID: <200401222253.37426.lilo@roccatello.it> (raw)

[-- Attachment #1: Type: text/plain, Size: 106 bytes --]

Hello,
i've done a little cleanup to net/ipv4/tcp.c

I hope it is ok :-)

Best regards,
Eduard Roccatello

[-- Attachment #2: tcp.c.patch --]
[-- Type: text/x-diff, Size: 561 bytes --]

--- net/ipv4/tcp.c.orig	2004-01-22 22:49:38.000000000 +0100
+++ net/ipv4/tcp.c	2004-01-22 22:42:38.000000000 +0100
@@ -549,9 +549,9 @@ int tcp_listen_start(struct sock *sk)
 		return -ENOMEM;
 
 	memset(lopt, 0, sizeof(struct tcp_listen_opt));
-	for (lopt->max_qlen_log = 6; ; lopt->max_qlen_log++)
-		if ((1 << lopt->max_qlen_log) >= sysctl_max_syn_backlog)
-			break;
+	lopt->max_qlen_log = 6;
+	while (sysctl_max_syn_backlog > (1 << lopt->max_qlen_log))
+		lopt->max_qlen_log++;
 	get_random_bytes(&lopt->hash_rnd, 4);
 
 	write_lock_bh(&tp->syn_wait_lock);

             reply	other threads:[~2004-01-22 21:53 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-22 21:53 Eduard Roccatello [this message]
2004-01-22 23:48 ` [PATCH] net/ipv4/tcp.c little cleanup Willy Tarreau
2004-01-23 20:03   ` Eduard Roccatello
2004-01-23 22:27     ` Willy Tarreau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200401222253.37426.lilo@roccatello.it \
    --to=lilo@roccatello.it \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox