lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250825172020.GA2077724@nvidia.com>
Date: Mon, 25 Aug 2025 14:20:20 -0300
From: Jason Gunthorpe <jgg@...dia.com>
To: "Gustavo A. R. Silva" <gustavoars@...nel.org>
Cc: Leon Romanovsky <leon@...nel.org>, linux-rdma@...r.kernel.org,
	linux-kernel@...r.kernel.org, linux-hardening@...r.kernel.org
Subject: Re: [PATCH v2][next] RDMA/cm: Avoid -Wflex-array-member-not-at-end
 warning

On Wed, Aug 13, 2025 at 07:22:14PM +0900, Gustavo A. R. Silva wrote:

> @@ -1866,7 +1872,7 @@ static void cm_process_work(struct cm_id_private *cm_id_priv,
>  	int ret;

I think if you are going to do this restructing then these lower level
functions that never touch the path member should also have their
signatures updated to take in the cm_work_hdr not the cm_work struct
with the path, and we should never cast from a cm_work_hdr to a
cm_work.

Basically we should have more type clarity when the path touches are
to be sure the cm_timewait_info version never gets into there.

And to do that properly is going to need a preparing patch to untangle
cm_work_handler() a little bit, it shouldn't be the work function for
the cm_timewait_handler() which has a different ype.

Also did you look closely at which members needed to be in the hdr?
I think with the above it will turn out that some members can be moved
to cm_work..

Thanks,
Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ