Thread (10 messages) flat view 10 messages, 4 authors, 2017-01-23

Re: [PATCH v4 1/3] bpf: add a longest prefix match trie map implementation

From: Alexei Starovoitov <hidden>
Date: 2017-01-22 22:57:06

On Sat, Jan 21, 2017 at 05:26:11PM +0100, Daniel Mack wrote:
This trie implements a longest prefix match algorithm that can be used
to match IP addresses to a stored set of ranges.

Internally, data is stored in an unbalanced trie of nodes that has a
maximum height of n, where n is the prefixlen the trie was created
with.

Tries may be created with prefix lengths that are multiples of 8, in
the range from 8 to 2048. The key used for lookup and update operations
is a struct bpf_lpm_trie_key, and the value is a uint64_t.

The code carries more information about the internal implementation.

Signed-off-by: Daniel Mack <daniel@zonque.org>
Reviewed-by: David Herrmann <redacted>
Looks great to me.
Acked-by: Alexei Starovoitov <ast@kernel.org>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help