SDFAB-193 Add packet-out routing feature to fabric-v1model

This is a port from fabric-tna:
https://github.com/stratum/fabric-tna/pull/262

By default, all packet-outs are sent straight to the egress port passed
as a controller packet-out metadata, bypassing the forwarding tables in
the ingress pipe. With this change, the control plane can set a new
packet-out metadata named `do_forwarding` to instruct the parser to
forward packet-outs as regular packets.

When handling `OutboundPacket` in ONOS, the pipeconf (interpreter) uses
the `OUTPUT` instruction with logical port `TABLE` to enable forwarding.
This is consistent with the OpenFlow behavior, from the spec:

    Required: TABLE: Represents the start of the OpenFlow pipeline (see
    5.1). This port is only valid in an output action in the action list
    of a packet-out message (see 7.3.7), and submits the packet to the
    first flow table so that the packet can be processed through the
    regular OpenFlow pipeline.

We also rename some test classes for consistency with main classes.
Before we had a FabricPipelinerTest class that was used for a different
purpose than testing FabricPipeliner.

Change-Id: I1b47c4b4f233df5b67d1a6dc743dea27c54772b2
(cherry picked from commit db347377bec8bf6f71fb9828f4dc552731e562f7)
diff --git a/pipelines/fabric/impl/src/main/resources/include/parser.p4 b/pipelines/fabric/impl/src/main/resources/include/parser.p4
index de0a76b..21032c7 100644
--- a/pipelines/fabric/impl/src/main/resources/include/parser.p4
+++ b/pipelines/fabric/impl/src/main/resources/include/parser.p4
@@ -28,13 +28,28 @@
 
     state start {
         transition select(standard_metadata.ingress_port) {
-            CPU_PORT: parse_packet_out;
+            CPU_PORT: check_packet_out;
             default: parse_ethernet;
         }
     }
 
-    state parse_packet_out {
+    state check_packet_out {
+        packet_out_header_t tmp = packet.lookahead<packet_out_header_t>();
+        transition select(tmp.do_forwarding) {
+            0: parse_packet_out_and_accept;
+            default: strip_packet_out;
+        }
+    }
+
+    state parse_packet_out_and_accept {
+        // Will transmit over requested egress port as-is. No need to parse further.
         packet.extract(hdr.packet_out);
+        transition accept;
+    }
+
+    state strip_packet_out {
+        // Remove packet-out header and process as a regular packet.
+        packet.advance(PACKET_OUT_HDR_SIZE * 8);
         transition parse_ethernet;
     }