net/ice/base: use struct size helper
authorQi Zhang <qi.z.zhang@intel.com>
Mon, 23 Mar 2020 07:17:30 +0000 (15:17 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 21 Apr 2020 11:57:04 +0000 (13:57 +0200)
commit71fbaee92d4d7851e56cbeb8c6586040d95e7768
tree5367b25fe53ff2d84591f60d46433468effa54af
parent4a3c620f6126be5763a45daccb769a5efd1bceab
net/ice/base: use struct size helper

For structures using the common C "struct hack" technique to create a
flexible length structure member at the end of the structure, use the
ice_struct_size macro to determine the length of the structure instead
of open coding the calculation.

Signed-off-by: Bruce Allan <bruce.w.allan@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_common.c
drivers/net/ice/base/ice_flex_pipe.c
drivers/net/ice/base/ice_sched.c
drivers/net/ice/base/ice_type.h