[v10,07/27] eal/class: register destructor
Checks
Commit Message
Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
---
lib/librte_eal/common/include/rte_class.h | 5 +++++
1 file changed, 5 insertions(+)
Comments
05/07/2018 13:48, Gaetan Rivet:
> Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
If there is no specific comment, this patch can be squashed.
@@ -112,6 +112,11 @@ static void classinitfn_ ##nm(void) \
{\
(cls).name = RTE_STR(nm);\
rte_class_register(&cls); \
+} \
+RTE_FINI_PRIO(classfinifn_ ##nm, CLASS); \
+static void classfinifn_ ##nm(void) \
+{ \
+ rte_class_unregister(&cls); \
}
#ifdef __cplusplus