P4ELTE / t4p4s

Retargetable compiler for the P4 language
http://p4.elte.hu/
Apache License 2.0
119 stars 42 forks source link

[RFC] Simple implementation to synchronize control plane init table manipulations #10

Closed lkpdn closed 5 years ago

lkpdn commented 5 years ago

What this PR does / why we need it: Having data plane wait for the initial table manipulations done by control plane, we can get rid of the race between handling first arriving packets and installing default actions + user-defined portmaps.

This is quite naive implementation using global var ctrl_is_initialized just to make it simple and clarify the idea. If you would agree with the synchronization idea but not much for ctrl_is_initialized, please let me hear your suggestion.

Please review, thanks.