RE: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Morten Brørup
> From: Stephen Hemminger [mailto:step...@networkplumber.org] > Sent: Tuesday, 14 November 2023 01.22 > > On Mon, 13 Nov 2023 16:16:35 -0800 > Stephen Hemminger wrote: > > > _Static_assert(!(0 != 0), "RTE_MBUF_F_RX_IP_CKSUM_UNKNOWN != 0"); > > Looks like a clang bug, or something about the ot

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Stephen Hemminger
On Mon, 13 Nov 2023 16:16:35 -0800 Stephen Hemminger wrote: > _Static_assert(!(0 != 0), "RTE_MBUF_F_RX_IP_CKSUM_UNKNOWN != 0"); Looks like a clang bug, or something about the other compiler flags because compiling just this part is fine.

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Stephen Hemminger
On Mon, 13 Nov 2023 14:28:55 -0800 Tyler Retzlaff wrote: > On Mon, Nov 13, 2023 at 02:13:26PM -0800, Stephen Hemminger wrote: > > On Mon, 13 Nov 2023 09:06:04 -0800 > > Stephen Hemminger wrote: > > > > > The macro RTE_MIN has some hidden assignments to provide type > > > safety which means th

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Stephen Hemminger
On Mon, 13 Nov 2023 14:28:55 -0800 Tyler Retzlaff wrote: > On Mon, Nov 13, 2023 at 02:13:26PM -0800, Stephen Hemminger wrote: > > On Mon, 13 Nov 2023 09:06:04 -0800 > > Stephen Hemminger wrote: > > > > > The macro RTE_MIN has some hidden assignments to provide type > > > safety which means th

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Tyler Retzlaff
On Mon, Nov 13, 2023 at 02:13:26PM -0800, Stephen Hemminger wrote: > On Mon, 13 Nov 2023 09:06:04 -0800 > Stephen Hemminger wrote: > > > The macro RTE_MIN has some hidden assignments to provide type > > safety which means the statement can not be fully evaluted in > > first pass of compiler. Repl

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Stephen Hemminger
On Mon, 13 Nov 2023 09:06:04 -0800 Stephen Hemminger wrote: > The macro RTE_MIN has some hidden assignments to provide type > safety which means the statement can not be fully evaluted in > first pass of compiler. Replace RTE_MIN() with equivalent macro. > > This will cause errors from checkpatc

Re: [PATCH v2 2/3] net/sfc: fix non-constant expression inr RTE_BUILD_BUG_ON()

2023-11-13 Thread Tyler Retzlaff
On Mon, Nov 13, 2023 at 09:06:04AM -0800, Stephen Hemminger wrote: > The macro RTE_MIN has some hidden assignments to provide type > safety which means the statement can not be fully evaluted in > first pass of compiler. Replace RTE_MIN() with equivalent macro. > > This will cause errors from chec