On 6/16/26 11:54 AM, Ales Musil via dev wrote:
> The existing OpenFlow table layout left zero free
> slots between regions: the ingress pipeline occupied
> tables 8-41, the output implementation tables started
> immediately at 42, the egress pipeline at 48, and the
> post-egress auxiliary tables at 64.  Adding even a
> single new ingress stage would cause a collision with
> the output tables, requiring a cascade of renumbering.
> 
> Introduce comfortable gaps between the four table
> regions so that future stages can be added without
> disturbing the rest of the layout:
> 
>   Tables 8-41:    ingress pipeline (34 stages, unchanged)
>   Tables 42-51:   gap (10 free slots)
>   Tables 52-57:   output implementation (6 tables)
>   Tables 58-61:   gap (4 free slots)
>   Tables 62-77:   egress pipeline (16 stages)
>   Tables 78-87:   gap (10 free slots)
>   Tables 88-112:  post-egress auxiliary tables (25 tables)
>   Tables 113-254: unused (142 free slots)
> 
> Add BUILD_ASSERT_DECL guards to catch any future
> overlap at compile time.
> 
> Assisted-by: Claude Opus 4.6, Claude Code
> Signed-off-by: Ales Musil <[email protected]>
> ---

Hi Ales,

Aside from Xavier's comments I only have a remark below.

> +
> +/* Verify that table regions do not overlap. */
> +BUILD_ASSERT_DECL(OFTABLE_LOG_INGRESS_PIPELINE + LOG_PIPELINE_INGRESS_LEN
> +                  <= OFTABLE_OUTPUT_LARGE_PKT_DETECT);
> +BUILD_ASSERT_DECL(OFTABLE_CHECK_LOOPBACK < OFTABLE_LOG_EGRESS_PIPELINE);
> +BUILD_ASSERT_DECL(OFTABLE_LOG_EGRESS_PIPELINE + LOG_PIPELINE_EGRESS_LEN
> +                  <= OFTABLE_SAVE_INPORT);
>  
We currently don't validate the values of LOG_PIPELINE_INGRESS_LEN and
LOG_PIPELINE_EGRESS_LEN in any way.  I'm thinking of adding a build time
assertion, I'll post a separate patch.

Regards,
Dumitru

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to