examples/ip_pipeline: check VLAN and MPLS parameters
authorAnand B Jyoti <anand.b.jyoti@intel.com>
Sun, 8 Jan 2017 21:55:49 +0000 (03:25 +0530)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 17 Jan 2017 17:37:41 +0000 (18:37 +0100)
commit50c644fc1fada20715d1873cbc8db3388e5186da
tree36dc5ff0478315541399e5183fbcd875678287ee
parent45e1c8b78268271b942ab14088c3facda7cc1aa1
examples/ip_pipeline: check VLAN and MPLS parameters

This commit add to CLI command check for the following errors
1. SVLAN and CVLAN IDs greater than 12 bits
2. MPLS ID greater than 20 bits
3. max number of supported MPLS labels to avoid array overflow

It prevents running CLI commands with invalid parameters.

Signed-off-by: Anand B Jyoti <anand.b.jyoti@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
examples/ip_pipeline/pipeline/pipeline_routing.c