[P4-dev] About DSCP INT value and masking operator
Eder Ollora Zaballa
eoza at fotonik.dtu.dk
Mon Jul 30 06:45:01 EDT 2018
We have been taking a look at the current INT spec (Working draft, 2018-05-08) and we have a question about the DSCP value used to identify the existence of INT headers ("0x17" according to Page 17 of the spec). Checking page 27 (of same spec document) there is an example code of INT where the value "0x17" is assigned to "DSCP_INT". Afterwards, in order to match against the DSCP value of packets, the code includes a "DSCP_INT &&& DSCP_INT" in the select statement of "parse_tcp". At first I thought that only the value 0x17 was matched against "DSCP_INT &&& DSCP_INT" but further tests (not related with INT) with masking operators show that there could actually be 4 values that match against "DSCP_INT &&& DSCP_INT": 0x17, 0x1F, 0x37 and 0x3F. Am I wrong on this? Was this the intended behavior? Any clarification on why the "DSCP_INT &&& DSCP_INT" was used is highly appreciated.
Thanks everyone for your help :)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the P4-dev