Re: [PATCH][next] RDMA/cm: Avoid -Wflex-array-member-not-at-end warning

2024-04-02 Thread Leon Romanovsky
On Mon, Mar 25, 2024 at 08:57:08PM -0600, Gustavo A. R. Silva wrote: > > > On 3/25/24 16:47, Jason Gunthorpe wrote: > > On Mon, Mar 25, 2024 at 02:24:07PM -0600, Gustavo A. R. Silva wrote: > > > -Wflex-array-member-not-at-end is coming in GCC-14, and we are getting > > > ready to enable it global

Re: [PATCH][next] RDMA/cm: Avoid -Wflex-array-member-not-at-end warning

2024-03-25 Thread Gustavo A. R. Silva
On 3/25/24 16:47, Jason Gunthorpe wrote: On Mon, Mar 25, 2024 at 02:24:07PM -0600, Gustavo A. R. Silva wrote: -Wflex-array-member-not-at-end is coming in GCC-14, and we are getting ready to enable it globally. Use the `struct_group_tagged()` helper to separate the flexible array from the res

Re: [PATCH][next] RDMA/cm: Avoid -Wflex-array-member-not-at-end warning

2024-03-25 Thread Jason Gunthorpe
On Mon, Mar 25, 2024 at 02:24:07PM -0600, Gustavo A. R. Silva wrote: > -Wflex-array-member-not-at-end is coming in GCC-14, and we are getting > ready to enable it globally. > > Use the `struct_group_tagged()` helper to separate the flexible array > from the rest of the members in flexible `struct

[PATCH][next] RDMA/cm: Avoid -Wflex-array-member-not-at-end warning

2024-03-25 Thread Gustavo A. R. Silva
-Wflex-array-member-not-at-end is coming in GCC-14, and we are getting ready to enable it globally. Use the `struct_group_tagged()` helper to separate the flexible array from the rest of the members in flexible `struct cm_work`, and avoid embedding the flexible-array member in `struct cm_timewait_