net/ice/base: refactor data structure
authorQi Zhang <qi.z.zhang@intel.com>
Mon, 23 Sep 2019 07:44:28 +0000 (15:44 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 7 Oct 2019 13:00:56 +0000 (15:00 +0200)
commita4b14d3939ace114a67ad507ee99b988f957a207
treecc8097607e0988d10b160fdd663b89f5cba915ca
parent50374442032ed9cf1d5d9069dfd856bb4c9008c5
net/ice/base: refactor data structure

When declaring the ice_prot_ext, and ice_prot_id_tbl structure,
we can use a fixed length array instead of a variable length one
which helps us catch future code changes that might desynchronize
the enum ice_protocol_type and the structs.  This change also
necessitates removing the last member of the structs which was
just there to be a placeholder.

Also reorder the ice_prot_ext struct to match the ordering in the
associated enum ice_protocol_type.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Paul M Stillwell Jr <paul.m.stillwell.jr@intel.com>
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Qiming Yang <qiming.yang@intel.com>
drivers/net/ice/base/ice_switch.c