Minor refactor fabric.p4

Remove origin_ether_type from fabric.p4
We can use ether_type from VLAN header since ingress_port_vlan table
always push a VLAN header to the packet if there is no VLAN header.

For configured interface, there exists flow rules to push VLAN.
For ports which not configured (infrastructure ports), the segment routing
application installs a rule which pushed internal VLAN to the packet (4094)

Change-Id: Ifae0b79a9d92b73a2a22cb33864e5bd5b6c95bfb
diff --git a/pipelines/fabric/src/main/resources/p4c-out/fabric-full/bmv2/default/bmv2.json b/pipelines/fabric/src/main/resources/p4c-out/fabric-full/bmv2/default/bmv2.json
index 62d1361..9d4a06b 100644
--- a/pipelines/fabric/src/main/resources/p4c-out/fabric-full/bmv2/default/bmv2.json
+++ b/pipelines/fabric/src/main/resources/p4c-out/fabric-full/bmv2/default/bmv2.json
@@ -23,7 +23,6 @@
         ["fabric_metadata_t.ip_proto", 8, false],
         ["fabric_metadata_t.l4_src_port", 16, false],
         ["fabric_metadata_t.l4_dst_port", 16, false],
-        ["fabric_metadata_t.original_ether_type", 16, false],
         ["_padding_1", 6, false]
       ]
     },
@@ -403,19 +402,6 @@
                 }
               ],
               "op" : "extract"
-            },
-            {
-              "parameters" : [
-                {
-                  "type" : "field",
-                  "value" : ["scalars", "fabric_metadata_t.original_ether_type"]
-                },
-                {
-                  "type" : "field",
-                  "value" : ["ethernet", "ether_type"]
-                }
-              ],
-              "op" : "set"
             }
           ],
           "transitions" : [
@@ -474,19 +460,6 @@
                 }
               ],
               "op" : "extract"
-            },
-            {
-              "parameters" : [
-                {
-                  "type" : "field",
-                  "value" : ["scalars", "fabric_metadata_t.original_ether_type"]
-                },
-                {
-                  "type" : "field",
-                  "value" : ["vlan_tag", "ether_type"]
-                }
-              ],
-              "op" : "set"
             }
           ],
           "transitions" : [
@@ -967,7 +940,7 @@
       "id" : 0,
       "source_info" : {
         "filename" : "include/parser.p4",
-        "line" : 165,
+        "line" : 163,
         "column" : 8,
         "source_fragment" : "FabricDeparser"
       },
@@ -3828,25 +3801,6 @@
             "column" : 31,
             "source_fragment" : "0x0800; ..."
           }
-        },
-        {
-          "op" : "assign",
-          "parameters" : [
-            {
-              "type" : "field",
-              "value" : ["scalars", "fabric_metadata_t.original_ether_type"]
-            },
-            {
-              "type" : "hexstr",
-              "value" : "0x0800"
-            }
-          ],
-          "source_info" : {
-            "filename" : "include/control/../define.p4",
-            "line" : 69,
-            "column" : 31,
-            "source_fragment" : "0x0800; ..."
-          }
         }
       ]
     },
@@ -5699,8 +5653,8 @@
             },
             {
               "match_type" : "exact",
-              "name" : "fabric_metadata.original_ether_type",
-              "target" : ["scalars", "fabric_metadata_t.original_ether_type"],
+              "name" : "hdr.vlan_tag.ether_type",
+              "target" : ["vlan_tag", "ether_type"],
               "mask" : null
             }
           ],
@@ -6022,12 +5976,6 @@
             },
             {
               "match_type" : "ternary",
-              "name" : "fabric_metadata.original_ether_type",
-              "target" : ["scalars", "fabric_metadata_t.original_ether_type"],
-              "mask" : null
-            },
-            {
-              "match_type" : "ternary",
               "name" : "hdr.ethernet.dst_addr",
               "target" : ["ethernet", "dst_addr"],
               "mask" : null
@@ -6046,6 +5994,12 @@
             },
             {
               "match_type" : "ternary",
+              "name" : "hdr.vlan_tag.ether_type",
+              "target" : ["vlan_tag", "ether_type"],
+              "mask" : null
+            },
+            {
+              "match_type" : "ternary",
               "name" : "hdr.ipv4.src_addr",
               "target" : ["ipv4", "src_addr"],
               "mask" : null
@@ -6071,7 +6025,7 @@
           ],
           "match_type" : "ternary",
           "type" : "simple",
-          "max_size" : 256,
+          "max_size" : 128,
           "with_counters" : true,
           "support_timeout" : false,
           "direct_meters" : null,
@@ -6821,7 +6775,7 @@
           "id" : 11,
           "source_info" : {
             "filename" : "include/control/forwarding.p4",
-            "line" : 239,
+            "line" : 238,
             "column" : 17,
             "source_fragment" : "fabric_metadata.fwd_type == FWD_IPV4_UNICAST"
           },
@@ -6847,7 +6801,7 @@
           "id" : 12,
           "source_info" : {
             "filename" : "include/control/forwarding.p4",
-            "line" : 241,
+            "line" : 240,
             "column" : 17,
             "source_fragment" : "fabric_metadata.fwd_type == FWD_IPV4_MULTICAST"
           },
@@ -6873,7 +6827,7 @@
           "id" : 13,
           "source_info" : {
             "filename" : "include/control/forwarding.p4",
-            "line" : 244,
+            "line" : 243,
             "column" : 17,
             "source_fragment" : "fabric_metadata.fwd_type == FWD_IPV6_UNICAST"
           },
@@ -6899,7 +6853,7 @@
           "id" : 14,
           "source_info" : {
             "filename" : "include/control/forwarding.p4",
-            "line" : 246,
+            "line" : 245,
             "column" : 17,
             "source_fragment" : "fabric_metadata.fwd_type == FWD_IPV6_MULTICAST"
           },