summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2023-02-07 09:01:59 -0800
committerDave Wallace <dwallacelf@gmail.com>2023-02-08 02:20:36 +0000
commita641763c5fac4fe08688dc453d5c67319ab730d8 (patch)
tree9a03a00eb7b8608b7ff383f5e6c81b49e7ff0935 /src
parentd1eaed02f3d16306e90b4f1ca5a63d3f02057a66 (diff)
vcl: drop lock on segment attach failure
Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I3bc2c7986f492b7b7dfbc84e4893202354223790 (cherry picked from commit aaad4f977cd7337b37cc6f00019f601f07abdced)
Diffstat (limited to 'src')
-rw-r--r--src/vcl/vcl_private.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/vcl/vcl_private.c b/src/vcl/vcl_private.c
index 589380d27aa..847e32c80f0 100644
--- a/src/vcl/vcl_private.c
+++ b/src/vcl/vcl_private.c
@@ -435,6 +435,7 @@ vcl_segment_attach (u64 segment_handle, char *name, ssvm_segment_type_t type,
if ((rv = fifo_segment_attach (&vcm->segment_main, a)))
{
clib_warning ("svm_fifo_segment_attach ('%s') failed", name);
+ clib_rwlock_writer_unlock (&vcm->segment_table_lock);
return rv;
}
hash_set (vcm->segment_table, segment_handle, a->new_segment_indices[0]);