From 079527f069e61a0ec79b7aaa7be9fb09947c6125 Mon Sep 17 00:00:00 2001 From: Anatoly Burakov Date: Fri, 13 Apr 2018 16:58:39 +0100 Subject: [PATCH] malloc: fix not unlocking hotplug on fail to init We lock the hotplug during init, but do not unlock it if we couldn't register multiprocess callbacks. Add the missing unlock. Fixes: 07dcbfe0101f ("malloc: support multiprocess memory hotplug") Signed-off-by: Anatoly Burakov --- lib/librte_eal/common/malloc_heap.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_eal/common/malloc_heap.c b/lib/librte_eal/common/malloc_heap.c index 41c14a8224..590e9e34be 100644 --- a/lib/librte_eal/common/malloc_heap.c +++ b/lib/librte_eal/common/malloc_heap.c @@ -815,6 +815,7 @@ rte_eal_malloc_heap_init(void) if (register_mp_requests()) { RTE_LOG(ERR, EAL, "Couldn't register malloc multiprocess actions\n"); + rte_rwlock_read_unlock(&mcfg->memory_hotplug_lock); return -1; } -- 2.20.1