Bitwidth change / adjust
This commit is contained in:
parent
8448e5121b
commit
bc63f5edcf
2 changed files with 2 additions and 9 deletions
|
@ -8,7 +8,7 @@
|
|||
typedef bit<48> mac_addr_t;
|
||||
typedef bit<32> ipv4_addr_t;
|
||||
typedef bit<128> ipv6_addr_t;
|
||||
typedef bit<16> port_t;
|
||||
typedef bit<9> port_t;
|
||||
typedef bit<16> mcast_t;
|
||||
typedef bit<8> task_t;
|
||||
|
||||
|
@ -112,8 +112,8 @@ header icmp_t {
|
|||
}
|
||||
|
||||
header cpu_t {
|
||||
port_t ingress_port;
|
||||
task_t task;
|
||||
bit<16> ingress_port;
|
||||
bit<16> ethertype;
|
||||
}
|
||||
|
||||
|
|
|
@ -229,11 +229,4 @@ MyDeparser()
|
|||
) main;
|
||||
|
||||
|
||||
/* set tcp header valid after modifying it -- keep this in mind*/
|
||||
// hdr.tcp.setValid();
|
||||
|
||||
|
||||
// hdr.cpu.srcAddr = hdr.ethernet.srcAddr;
|
||||
// hdr.cpu.ingress_port = (bit<16>)meta.ingress_port;
|
||||
|
||||
// truncate((bit<32>)22); //ether+cpu header
|
||||
|
|
Loading…
Reference in a new issue