VOL-3718 Packets coming from Open OLT Adapter to the VOLTHA Core always have zero in their UNI port field. OLT Adapter should set the true UNI port info to the control packets before passing them to the VOLTHA Core in the scope of packet-in workflow.

As a solution, pon-and-gem-port-to-uni-port relations are learned during subscriber provisioning operation and kept in the kv store and a cache (a map named gemToUniMap) in a lazy manner. In the packet-in workflow, UNI port info is resolved by looking up the gemToUniMap and put into the packet before passing it to the upper layer.

Change-Id: I6b60f7c1964452b6789f6a9905ab04000fe2d33c
diff --git a/pkg/mocks/mockKVClient.go b/pkg/mocks/mockKVClient.go
index 662e236..290f191 100644
--- a/pkg/mocks/mockKVClient.go
+++ b/pkg/mocks/mockKVClient.go
@@ -183,6 +183,20 @@
 			str, _ := json.Marshal(data)
 			return kvstore.NewKVPair(key, str, "mock", 3000, 1), nil
 		}
+		//Interface, GEM port path
+		if strings.Contains(key, "0,255") {
+			//return onuID, uniID associated with the given interface and GEM port
+			data := []uint32{1, 0}
+			str, _ := json.Marshal(data)
+			return kvstore.NewKVPair(key, str, "mock", 3000, 1), nil
+		}
+		//Interface, GEM port path
+		if strings.Contains(key, "0,257") {
+			//return onuID, uniID associated with the given interface and GEM port
+			data := []uint32{1, 0}
+			str, _ := json.Marshal(data)
+			return kvstore.NewKVPair(key, str, "mock", 3000, 1), nil
+		}
 
 		maps := make(map[string]*kvstore.KVPair)
 		maps[key] = &kvstore.KVPair{Key: key}