diff --git a/src/vnet/udp/udp.c b/src/vnet/udp/udp.c
index b069e72..3f36ce7 100644
--- a/src/vnet/udp/udp.c
+++ b/src/vnet/udp/udp.c
@@ -21,9 +21,77 @@
 #include <vnet/session/session.h>
 #include <vnet/dpo/load_balance.h>
 #include <vnet/fib/ip4_fib.h>
+#include <vppinfra/sparse_vec.h>
 
 udp_main_t udp_main;
 
+static void
+udp_connection_register_port (vlib_main_t * vm, u16 lcl_port, u8 is_ip4)
+{
+  udp_main_t *um = &udp_main;
+  udp_dst_port_info_t *pi;
+  u16 *n;
+
+  pi = udp_get_dst_port_info (um, lcl_port, is_ip4);
+  if (!pi)
+    {
+      udp_add_dst_port (um, lcl_port, 0, is_ip4);
+      pi = udp_get_dst_port_info (um, lcl_port, is_ip4);
+      pi->n_connections = 1;
+    }
+  else
+    {
+      pi->n_connections += 1;
+      /* Do not return. The fact that the pi is valid does not mean
+       * it's up to date */
+    }
+
+  pi->node_index = is_ip4 ? udp4_input_node.index : udp6_input_node.index;
+  pi->next_index = um->local_to_input_edge[is_ip4];
+
+  /* Setup udp protocol -> next index sparse vector mapping. */
+  if (is_ip4)
+    n = sparse_vec_validate (um->next_by_dst_port4,
+			     clib_host_to_net_u16 (lcl_port));
+  else
+    n = sparse_vec_validate (um->next_by_dst_port6,
+			     clib_host_to_net_u16 (lcl_port));
+
+  n[0] = pi->next_index;
+}
+
+static void
+udp_connection_unregister_port (u16 lcl_port, u8 is_ip4)
+{
+  udp_main_t *um = &udp_main;
+  udp_dst_port_info_t *pi;
+
+  pi = udp_get_dst_port_info (um, lcl_port, is_ip4);
+  if (!pi)
+    return;
+
+  if (!pi->n_connections)
+    {
+      clib_warning ("no connections using port %u", lcl_port);
+      return;
+    }
+
+  if (!clib_atomic_sub_fetch (&pi->n_connections, 1))
+    udp_unregister_dst_port (0, lcl_port, is_ip4);
+}
+
+void
+udp_connection_share_port (u16 lcl_port, u8 is_ip4)
+{
+  udp_main_t *um = &udp_main;
+  udp_dst_port_info_t *pi;
+
+  /* Done without a lock but the operation is atomic. Writers to pi hash
+   * table and vector should be guarded by a barrier sync */
+  pi = udp_get_dst_port_info (um, lcl_port, is_ip4);
+  clib_atomic_fetch_add_rel (&pi->n_connections, 1);
+}
+
 udp_connection_t *
 udp_connection_alloc (u32 thread_index)
 {
@@ -67,11 +135,8 @@
 void
 udp_connection_delete (udp_connection_t * uc)
 {
-  if ((uc->flags & UDP_CONN_F_OWNS_PORT)
-      || !(uc->flags & UDP_CONN_F_CONNECTED))
-    udp_unregister_dst_port (vlib_get_main (),
-			     clib_net_to_host_u16 (uc->c_lcl_port),
-			     uc->c_is_ip4);
+  udp_connection_unregister_port (clib_net_to_host_u16 (uc->c_lcl_port),
+				  uc->c_is_ip4);
   session_transport_delete_notify (&uc->connection);
   udp_connection_free (uc);
 }
@@ -84,13 +149,16 @@
   transport_endpoint_cfg_t *lcl_ext;
   udp_connection_t *listener;
   udp_dst_port_info_t *pi;
-  u32 node_index;
   void *iface_ip;
 
   pi = udp_get_dst_port_info (um, clib_net_to_host_u16 (lcl->port),
 			      lcl->is_ip4);
-  if (pi)
-    return -1;
+
+  if (pi && !pi->n_connections)
+    {
+      clib_warning ("port already used");
+      return -1;
+    }
 
   pool_get (um->listener_pool, listener);
   clib_memset (listener, 0, sizeof (udp_connection_t));
@@ -118,21 +186,21 @@
     listener->c_flags |= TRANSPORT_CONNECTION_F_CLESS;
   clib_spinlock_init (&listener->rx_lock);
 
-  node_index = lcl->is_ip4 ? udp4_input_node.index : udp6_input_node.index;
-  udp_register_dst_port (vm, clib_net_to_host_u16 (lcl->port), node_index,
-			 lcl->is_ip4);
+  udp_connection_register_port (vm, clib_net_to_host_u16 (lcl->port),
+				lcl->is_ip4);
   return listener->c_c_index;
 }
 
 u32
 udp_session_unbind (u32 listener_index)
 {
-  vlib_main_t *vm = vlib_get_main ();
-
+  udp_main_t *um = &udp_main;
   udp_connection_t *listener;
+
   listener = udp_listener_get (listener_index);
-  udp_unregister_dst_port (vm, clib_net_to_host_u16 (listener->c_lcl_port),
-			   listener->c_is_ip4);
+  udp_connection_unregister_port (clib_net_to_host_u16 (listener->c_lcl_port),
+				  listener->c_is_ip4);
+  pool_put (um->listener_pool, listener);
   return 0;
 }
 
@@ -295,30 +363,36 @@
 int
 udp_open_connection (transport_endpoint_cfg_t * rmt)
 {
-  udp_main_t *um = vnet_get_udp_main ();
   vlib_main_t *vm = vlib_get_main ();
   u32 thread_index = vm->thread_index;
   udp_connection_t *uc;
   ip46_address_t lcl_addr;
-  u32 node_index;
   u16 lcl_port;
 
   if (transport_alloc_local_endpoint (TRANSPORT_PROTO_UDP, rmt, &lcl_addr,
 				      &lcl_port))
     return -1;
 
-  while (udp_get_dst_port_info (um, lcl_port, rmt->is_ip4))
+  if (udp_is_valid_dst_port (lcl_port, rmt->is_ip4))
     {
-      lcl_port = transport_alloc_local_port (TRANSPORT_PROTO_UDP, &lcl_addr);
-      if (lcl_port < 1)
+      /* If specific source port was requested abort */
+      if (rmt->peer.port)
+	return -1;
+
+      /* Try to find a port that's not used */
+      while (udp_is_valid_dst_port (lcl_port, rmt->is_ip4))
 	{
-	  clib_warning ("Failed to allocate src port");
-	  return -1;
+	  lcl_port = transport_alloc_local_port (TRANSPORT_PROTO_UDP,
+						 &lcl_addr);
+	  if (lcl_port < 1)
+	    {
+	      clib_warning ("Failed to allocate src port");
+	      return -1;
+	    }
 	}
     }
 
-  node_index = rmt->is_ip4 ? udp4_input_node.index : udp6_input_node.index;
-  udp_register_dst_port (vm, lcl_port, node_index, 1 /* is_ipv4 */ );
+  udp_connection_register_port (vm, lcl_port, rmt->is_ip4);
 
   /* We don't poll main thread if we have workers */
   if (vlib_num_workers ())
@@ -483,6 +557,11 @@
 	clib_spinlock_init (&um->peekers_readers_locks[i]);
 	clib_spinlock_init (&um->peekers_write_locks[i]);
       }
+
+  um->local_to_input_edge[UDP_IP4] =
+    vlib_node_add_next (vm, udp4_local_node.index, udp4_input_node.index);
+  um->local_to_input_edge[UDP_IP6] =
+    vlib_node_add_next (vm, udp6_local_node.index, udp6_input_node.index);
   return 0;
 }
 
diff --git a/src/vnet/udp/udp.h b/src/vnet/udp/udp.h
index 5ff613b..32e660b 100644
--- a/src/vnet/udp/udp.h
+++ b/src/vnet/udp/udp.h
@@ -106,7 +106,7 @@
   /* Name (a c string). */
   char *name;
 
-  /* GRE protocol type in host byte order. */
+  /* Port number in host byte order. */
   udp_dst_port_t dst_port;
 
   /* Node which handles this type. */
@@ -115,6 +115,9 @@
   /* Next index for this type. */
   u32 next_index;
 
+  /* UDP sessions refcount (not tunnels) */
+  u32 n_connections;
+
   /* Parser for packet generator edits for this protocol */
   unformat_function_t *unformat_pg_edit;
 } udp_dst_port_info_t;
@@ -141,6 +144,9 @@
   u8 punt_unknown4;
   u8 punt_unknown6;
 
+  /* Udp local to input arc index */
+  u32 local_to_input_edge[N_UDP_AF];
+
   /*
    * Per-worker thread udp connection pools used with session layer
    */
@@ -257,6 +263,8 @@
 format_function_t format_udp_rx_trace;
 unformat_function_t unformat_udp_header;
 
+void udp_add_dst_port (udp_main_t * um, udp_dst_port_t dst_port,
+		       char *dst_port_name, u8 is_ip4);
 void udp_register_dst_port (vlib_main_t * vm,
 			    udp_dst_port_t dst_port,
 			    u32 node_index, u8 is_ip4);
@@ -264,6 +272,8 @@
 			      udp_dst_port_t dst_port, u8 is_ip4);
 bool udp_is_valid_dst_port (udp_dst_port_t dst_port, u8 is_ip4);
 
+void udp_connection_share_port (u16 lcl_port, u8 is_ip4);
+
 void udp_punt_unknown (vlib_main_t * vm, u8 is_ip4, u8 is_add);
 
 always_inline void *
diff --git a/src/vnet/udp/udp_input.c b/src/vnet/udp/udp_input.c
index 453e123..4b22cbe 100644
--- a/src/vnet/udp/udp_input.c
+++ b/src/vnet/udp/udp_input.c
@@ -220,6 +220,8 @@
 	      s0->session_state = SESSION_STATE_READY;
 	      tc0 = &child0->connection;
 	      uc0 = udp_get_connection_from_transport (tc0);
+	      udp_connection_share_port (clib_net_to_host_u16
+					 (uc0->c_lcl_port), uc0->c_is_ip4);
 	      error0 = UDP_ERROR_LISTENER;
 	    }
 	}
diff --git a/src/vnet/udp/udp_local.c b/src/vnet/udp/udp_local.c
index af54b73..748ad73 100644
--- a/src/vnet/udp/udp_local.c
+++ b/src/vnet/udp/udp_local.c
@@ -447,9 +447,9 @@
 /* *INDENT-ON* */
 
 #ifndef CLIB_MARCH_VARIANT
-static void
-add_dst_port (udp_main_t * um,
-	      udp_dst_port_t dst_port, char *dst_port_name, u8 is_ip4)
+void
+udp_add_dst_port (udp_main_t * um, udp_dst_port_t dst_port,
+		  char *dst_port_name, u8 is_ip4)
 {
   udp_dst_port_info_t *pi;
   u32 i;
@@ -484,7 +484,7 @@
   pi = udp_get_dst_port_info (um, dst_port, is_ip4);
   if (!pi)
     {
-      add_dst_port (um, dst_port, 0, is_ip4);
+      udp_add_dst_port (um, dst_port, 0, is_ip4);
       pi = udp_get_dst_port_info (um, dst_port, is_ip4);
       ASSERT (pi);
     }
@@ -633,10 +633,10 @@
     ( /* elt bytes */ sizeof (um->next_by_dst_port6[0]),
      /* bits in index */ BITS (((udp_header_t *) 0)->dst_port));
 
-#define _(n,s) add_dst_port (um, UDP_DST_PORT_##s, #s, 1 /* is_ip4 */);
+#define _(n,s) udp_add_dst_port (um, UDP_DST_PORT_##s, #s, 1 /* is_ip4 */);
   foreach_udp4_dst_port
 #undef _
-#define _(n,s) add_dst_port (um, UDP_DST_PORT_##s, #s, 0 /* is_ip4 */);
+#define _(n,s) udp_add_dst_port (um, UDP_DST_PORT_##s, #s, 0 /* is_ip4 */);
     foreach_udp6_dst_port
 #undef _
     ip4_register_protocol (IP_PROTOCOL_UDP, udp4_local_node.index);
