[P4-dev] add and remove header of P4-14 in bmv2

Antonin Bas antonin at barefootnetworks.com
Wed Jun 28 13:53:37 EDT 2017


I'm not aware of any issue with add_header or remove_header. If you send
your code, I can look into it and see if I can reproduce the problem.
A lot of P4 code online uses these primitives: switch.p4 or smaller
examples (
https://github.com/p4lang/tutorials/blob/master/examples/copy_to_cpu/p4src/copy_to_cpu.p4#L90
).

On Wed, Jun 28, 2017 at 4:02 AM, Salvatore Signorello <
salvatore.signorello at uni.lu> wrote:

> apologies, in the previous I forgot to tell you that no header stacks are
> involved, I am only passing normal header instances to those primitives.
>
> Just, because I have seen a couple of related github issues.
>
>
>
> On 06/28/2017 12:43 PM, Salvatore Signorello wrote:
>
>> Hi all,
>>
>> before adding any code snippets to this thread, I would like to be sure
>> that the two primitive actions add_header and remove_header are supported
>> by the current bmv2. Are they?
>>
>> According to the nanolog, my header is added and deserialized correctly
>> at the output. However, when sniffing the output interface the packet is
>> identical to the input.
>>
>> Could please anyone confirm that the primitives work fine? If so, could
>> you please point me to some code containing the right sequence of calls to
>> use them?
>>
>>
>> Back in time, I remember they were working fine with the source_routing
>> example proposed by Antonin in one of the old tutorials on P4. Any changes
>> since then?
>>
>>
>> Best regards,
>>
>> Salvatore
>>
>>
>>
> --
> Salvatore Signorello
> PhD student of the SEDAN research group at SnT
>
> Interdisciplinary Centre for Security, Reliability and Trust
> University of Luxembourg
> http://wwwen.uni.lu/snt/people/salvatore_signorello
>
>
> _______________________________________________
> P4-dev mailing list
> P4-dev at lists.p4.org
> http://lists.p4.org/mailman/listinfo/p4-dev_lists.p4.org
>



-- 
Antonin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.p4.org/pipermail/p4-dev_lists.p4.org/attachments/20170628/897ae082/attachment-0002.html>


More information about the P4-dev mailing list