Added docstring to a function.

Signed-off-by: Maciej Kurc <mkurc@antmicro.com>
diff --git a/v2x/vlog_to_pbtype.py b/v2x/vlog_to_pbtype.py
index 26b03a2..cef2102 100755
--- a/v2x/vlog_to_pbtype.py
+++ b/v2x/vlog_to_pbtype.py
@@ -377,6 +377,16 @@
 
 
 def mode_interconnects(mod, mode_name) -> Dict[CellPin, List[CellPin]]:
+    """
+    This function returns a definition of an interconnect used to connect
+    a child pb_type for the given mode with its parent pb_type that provides
+    the modes.
+
+    The returned dict is indexed by tuples containing source (driver) mode
+    names and pin names. Its values contain lists of sink modes and pin names
+    that are driven by the driver. If the mode name is None then the connection
+    refers to the parent pb_type.
+    """
     interconn = {}
     for name, width, bits, iodir in mod.ports:
         if iodir == "input":