lpm: implement RCU rule reclamation
authorRuifeng Wang <ruifeng.wang@arm.com>
Fri, 10 Jul 2020 02:22:25 +0000 (10:22 +0800)
committerDavid Marchand <david.marchand@redhat.com>
Fri, 10 Jul 2020 11:41:29 +0000 (13:41 +0200)
commit8a9f8564e9f916d469492f5c5a4dc5886e814e05
tree7ffab854021e1da2d13ed8c5ed6161fc5804fa47
parente0a439466b9d63e3a5cc063efbf08784300b54c4
lpm: implement RCU rule reclamation

Currently, the tbl8 group is freed even though the readers might be
using the tbl8 group entries. The freed tbl8 group can be reallocated
quickly. This results in incorrect lookup results.

RCU QSBR process is integrated for safe tbl8 group reclaim.
Refer to RCU documentation to understand various aspects of
integrating RCU library into other libraries.

To avoid ABI breakage, a struct __rte_lpm is created for lpm library
internal use. This struct wraps rte_lpm that has been exposed and
also includes members that don't need to be exposed such as RCU related
config.

Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Reviewed-by: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Acked-by: Ray Kinsella <mdr@ashroe.eu>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
doc/guides/prog_guide/lpm_lib.rst
lib/librte_lpm/Makefile
lib/librte_lpm/meson.build
lib/librte_lpm/rte_lpm.c
lib/librte_lpm/rte_lpm.h
lib/librte_lpm/rte_lpm_version.map