Module Name: src Committed By: snj Date: Sun Dec 18 07:40:50 UTC 2016
Modified Files: src/sys/modules/npf [netbsd-7]: Makefile src/sys/net/npf [netbsd-7]: files.npf npf_impl.h npf_tableset.c src/sys/rump/net/lib/libnpf [netbsd-7]: Makefile Added Files: src/sys/net/npf [netbsd-7]: lpm.c lpm.h Removed Files: src/sys/net/npf [netbsd-7]: npf_tableset_ptree.c Log Message: Pull up following revision(s) (requested by rmind in ticket #1319): sys/modules/npf/Makefile: revision 1.19 sys/net/npf/files.npf: revision 1.18 sys/net/npf/lpm.c: revision 1.1 sys/net/npf/lpm.h: revision 1.1 sys/net/npf/npf_impl.h: revision 1.62 sys/net/npf/npf_tableset.c: revision 1.24 sys/net/npf/npf_tableset_ptree.c: file removal sys/rump/net/lib/libnpf/Makefile: revision 1.18 This patches ditches the ptree(3) library, because it is broken (you can get missing entries!). Instead, as a temporary solution, we switch to a simple linear scan of the hash tables for the longest-prefix-match (lpm.c lpm.h) algorithm. In fact, with few unique prefixes in the set, on modern hardware this simple algorithm is pretty fast anyway! -- ditch ptree and use lpm -- remove ptree add lpm To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.17.2.1 src/sys/modules/npf/Makefile cvs rdiff -u -r1.17 -r1.17.2.1 src/sys/net/npf/files.npf cvs rdiff -u -r0 -r1.1.2.2 src/sys/net/npf/lpm.c src/sys/net/npf/lpm.h cvs rdiff -u -r1.58.2.3 -r1.58.2.4 src/sys/net/npf/npf_impl.h cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/net/npf/npf_tableset.c cvs rdiff -u -r1.1 -r0 src/sys/net/npf/npf_tableset_ptree.c cvs rdiff -u -r1.14 -r1.14.2.1 src/sys/rump/net/lib/libnpf/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.