From: Pavel Emelianov <xemul@sw.ru>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, devel@openvz.org
Subject: Re: [PATCH] Consolidate udp hash calculations
Date: Mon, 07 May 2007 11:07:15 +0400 [thread overview]
Message-ID: <463ED023.4060109@sw.ru> (raw)
In-Reply-To: <20070504.123909.88476080.davem@davemloft.net>
David Miller wrote:
> From: Pavel Emelianov <xemul@sw.ru>
> Date: Fri, 04 May 2007 18:51:36 +0400
>
>> Make access to udphash/udplitehash symmetrical to inet hashes.
>>
>> This may also help network namespaces, since they tend to use
>> one hash for different namespaces by selecting the hash chain
>> depending on a hash value and the namespace.
>>
>> Signed-off-by: Pavel Emelianov <xemul@openvz.org>
>
> This is not the "UDP Hash Function", it is a mask to bring
> the hash value modulo of the hash table size.
>
> So your function name is misleading and makes the code
> even worse.
>
> I'm also not so sure this cleanup really adds any clarity,
> even with a proper function name.
The same is applicable to inet_lhashfn and inet_bhashfn, but they
are called hashfn-s and do exist in kernel. This hashfn will make
things look similar.
> I can only assume you wish to do something with the UDP hash table
> sizes, and therefore only want to have a need to touch one function.
You are right, I have told that this must help network namespaces,
by making the hash differ depending on the namespace passed.
next prev parent reply other threads:[~2007-05-07 7:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-04 14:51 [PATCH] Consolidate udp hash calculations Pavel Emelianov
2007-05-04 19:39 ` David Miller
2007-05-07 7:07 ` Pavel Emelianov [this message]
2007-05-07 7:04 ` David Miller
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=463ED023.4060109@sw.ru \
--to=xemul@sw.ru \
--cc=davem@davemloft.net \
--cc=devel@openvz.org \
--cc=netdev@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).