On Thu, Jan 18, 2024 at 5:53 PM Stephen Hemminger <step...@networkplumber.org> wrote: > > This series fixes a couple places where expressions that could not > be evaluated as constant early in compiler passes were used. > Then converts RTE_BUILD_BUG_ON() with static_assert. > > static_assert() is more picky about the expression has to > be a constant, which also catches some existing undefined > behavior that pre-existed. > > The series requires a couple of workarounds to deal > with quirks in static_assert() in some toolchains. > > v6 - minor cleanups > handle missing macro in old FreeBSD > > Stephen Hemminger (6): > eal: introduce RTE_MIN_T() and RTE_MAX_T() macros > event/opdl: fix non-constant compile time assertion > net/sfc: fix non-constant expression in RTE_BUILD_BUG_ON() > net/i40e: avoid using const variable in assertion > mempool: avoid floating point expression in static assertion > eal: replace out of bounds VLA with static_assert > > drivers/event/opdl/opdl_ring.c | 2 +- > drivers/net/i40e/i40e_ethdev.h | 1 + > drivers/net/i40e/i40e_rxtx_vec_sse.c | 10 ++++------ > drivers/net/mlx5/mlx5_rxq.c | 2 +- > drivers/net/sfc/sfc_ef100_tx.c | 3 +-- > lib/eal/include/rte_common.h | 27 ++++++++++++++++++++++++++- > lib/mempool/rte_mempool.c | 7 ++++--- > 7 files changed, 38 insertions(+), 14 deletions(-)
Added a small RN and applied, thanks Stephen. -- David Marchand