[SDFAB-595] Add UPF configuration guide

Change-Id: I59cb4bd229f70dd334ffb1e3597764374adf4df7
diff --git a/advanced/upf.rst b/advanced/upf.rst
index 72c9ae7..8298898 100644
--- a/advanced/upf.rst
+++ b/advanced/upf.rst
@@ -1,2 +1,8 @@
 User Plane Function (UPF)
 =========================
+
+.. toctree::
+   :maxdepth: 2
+   :glob:
+
+   upf_configuration
diff --git a/advanced/upf_configuration.rst b/advanced/upf_configuration.rst
new file mode 100644
index 0000000..0e78837
--- /dev/null
+++ b/advanced/upf_configuration.rst
@@ -0,0 +1,84 @@
+User Plane Function (UPF) Network Configuration
+===============================================
+
+.. tip::
+    See :doc:`User Plane Function (UPF) </advanced/upf>` to learn how UPF works in the
+    SD-Fabric project.
+
+The UPF configuration is split in two configurations, that can be provided independently to ONOS.
+Th first is used to configure the UP4 ONOS application and defines UPF-related information
+such as S1U Address, network devices implementing UPF etc.
+The second one, instead, is used to configure parameters related to the Downlink
+Buffering (DBUF) functionality.
+
+Here's a list of fields that you can configure via the UPF Network Configuration for UP4:
+
+* ``devices``: A list of devices IDs that implements the UPF data plane. This list
+  must include all the leaf switches in the topology.
+  The UPF state is replicated on all devices specified in this configuration field.
+  The devices specified in this list must use a P4 pipeline implementing the UPF functionality. *Required*
+
+* ``s1uAddr``: The IP address of the S1-U interface (equivalent to N3 for 5G).
+  It can be an arbitrary IP address. *Required*
+
+* ``uePools``: A list of subnets that are in use by the UEs. *Required*
+
+* ``dbufDrainAddr``: The IP address of the UPF data plane interface that the DBUF
+  service will drain packets towards. *Optional*
+
+* ``pscEncapEnabled``: Set whether the UPF should use GTP-U extension PDU Session Container
+  when doing encapsulation of downlink packets. *Optional*
+
+* ``defaultQfi``: The default QoS Flow Identifier to use when the PDU Session Container
+  encapsulation is enabled. *Optional*
+
+Here is an example of netcfg for UP4:
+
+.. code-block:: json
+
+    {
+        "apps": {
+            "org.omecproject.up4": {
+                "up4": {
+                  "devices": [
+                    "device:leaf1",
+                    "device:leaf2"
+                  ],
+                  "s1uAddr": "10.32.11.126",
+                  "uePools": [
+                    "10.240.0.0/16"
+                  ],
+                "dbufDrainAddr": "10.32.11.126",
+                "pscEncapEnabled": false,
+                "defaultQfi": 0
+                }
+            }
+        }
+    }
+
+The DBUF configuration is all *Optional*, we can use UP4 without the downlink
+buffering functionality.
+Here's a list of fields that you can configure via the UPF Network Configuration for DBUF:
+
+* ``serviceAddr``: The address DBUF service management interface in the form IP:port.
+  This address is used to communicate with the DBUF service via gRPC (for example, to trigger
+  the drain operation, or receive notification for buffered packets).
+
+* ``dataplaneAddr``: The address of the DBUF service data plane interface in the form IP:port.
+  Packets sent to this address by the UPF will be buffered by DBUF.
+  The IP address must be a routable fabric address.
+
+Here is an example of netcfg for DBUF:
+
+.. code-block:: json
+
+    {
+        "apps": {
+            "org.omecproject.up4": {
+                "dbuf": {
+                    "serviceAddr": "10.76.28.72:10000",
+                    "dataplaneAddr": "10.32.11.3:2152"
+                }
+          }
+        }
+    }
diff --git a/dict.txt b/dict.txt
index d992c3a..b57703f 100644
--- a/dict.txt
+++ b/dict.txt
@@ -4,3 +4,9 @@
 patchset
 reStructuredText
 virtualenv
+UPF
+netcfg
+gRPC
+routable
+downlink
+subnets