[qca-nss-sfe] release the lock if no GRE proto handler
Change-Id: I9202aab951aa5971f7e94db5fdeac800c702a5fa
Signed-off-by: Nitin Shetty <quic_nitinsj@quicinc.com>
diff --git a/sfe_ipv4.c b/sfe_ipv4.c
index 78653ba..7d0e88a 100644
--- a/sfe_ipv4.c
+++ b/sfe_ipv4.c
@@ -1543,6 +1543,7 @@
#else
if (!refcount_inc_not_zero(&sk->sk_refcnt)) {
#endif
+ this_cpu_inc(si->stats_pcpu->connection_create_failures64);
spin_unlock_bh(&si->lock);
kfree(reply_cm);
kfree(original_cm);
@@ -1605,6 +1606,8 @@
rcu_read_unlock();
if (unlikely(!reply_cm->proto)) {
+ this_cpu_inc(si->stats_pcpu->connection_create_failures64);
+ spin_unlock_bh(&si->lock);
kfree(reply_cm);
kfree(original_cm);
kfree(c);