netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tom Herbert <tom@herbertland.com>
To: <davem@davemloft.net>, <netdev@vger.kernel.org>, <tgraf@suug.ch>,
	<herbert@gondor.apana.org.au>
Cc: <kernel-team@fb.com>
Subject: [PATCH v2 net-next 0/3] rhashtable: Wildcard and scored lookups
Date: Tue, 14 Jul 2015 16:45:46 -0700	[thread overview]
Message-ID: <1436917549-3666965-1-git-send-email-tom@herbertland.com> (raw)

This patch set implements:
  - A compare function can be passed in the lookup. This allows for
    comparison to include "wildcard fields"
  - Order insertion within a bucket, so that entries with more specific
    information can be matched first.
  - Scored lookups. This is like the socket lookups. It allows
    different levels of matching, and returning one of N possible
    best matches with a uniform distribution based on flow hash.

Testing: Tested this in conjunction with ILA development. Will be
posting ILA patches shortly.

V2:
 - Added rhashtable_lookup_ordered_cmpfn to ensure that greatest
   ordered matching entry is found during rehashing
 - Minor cleanup to scored lookup patch

Tom Herbert (3):
  rhashtable: Allow lookup function to have compare function agument
  rhashtable: Add a function for in order insertion and lookup in
    buckets
  rhashtable: Add scored lookups

 include/linux/rhashtable.h | 194 +++++++++++++++++++++++++++++++++++++++++++--
 lib/rhashtable.c           |  20 ++---
 2 files changed, 196 insertions(+), 18 deletions(-)

-- 
1.8.1

             reply	other threads:[~2015-07-14 23:45 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-14 23:45 Tom Herbert [this message]
2015-07-14 23:45 ` [PATCH v2 net-next 1/3] rhashtable: Allow lookup function to have compare function agument Tom Herbert
2015-07-17 12:08   ` Thomas Graf
2015-07-14 23:45 ` [PATCH v2 net-next 2/3] rhashtable: Add a function for in order insertion and lookup in buckets Tom Herbert
2015-07-15  5:54   ` Herbert Xu
2015-07-15 19:46     ` Tom Herbert
2015-07-17 12:11       ` Thomas Graf
2015-07-14 23:45 ` [PATCH v2 net-next 3/3] rhashtable: Add scored lookups Tom Herbert
2015-07-15  0:18   ` Herbert Xu
2015-07-15  0:25     ` Tom Herbert

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=1436917549-3666965-1-git-send-email-tom@herbertland.com \
    --to=tom@herbertland.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=kernel-team@fb.com \
    --cc=netdev@vger.kernel.org \
    --cc=tgraf@suug.ch \
    /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).