Make the Basic pipeline more portable
This change makes the Basic pipeline compile better with different
compilers. One change is this: the type parameter for a v1model meter
instance cannot be a programmer-defined enum. This is because in P4_16,
enums don't necessarily have underlying bitstring types and the
language doesn't specify that enum members should be assigned a
numerical value in any given way.
Change-Id: Id2b758eb2b6e76aa708c2e03e7a001667efddb3d
diff --git a/pipelines/basic/src/main/resources/include/headers.p4 b/pipelines/basic/src/main/resources/include/headers.p4
index e45c915..1676646 100644
--- a/pipelines/basic/src/main/resources/include/headers.p4
+++ b/pipelines/basic/src/main/resources/include/headers.p4
@@ -22,11 +22,13 @@
@controller_header("packet_in")
header packet_in_header_t {
bit<9> ingress_port;
+ bit<7> _padding;
}
@controller_header("packet_out")
header packet_out_header_t {
bit<9> egress_port;
+ bit<7> _padding;
}
header ethernet_t {