From: Kees Cook <kees@kernel.org>
To: "Gustavo A. R. Silva" <gustavo@embeddedor.com>,
Kees Cook <keescook@chromium.org>,
"Martin K. Petersen" <martin.petersen@oracle.com>
Cc: "Gustavo A. R. Silva" <gustavoars@kernel.org>,
"James E.J. Bottomley" <jejb@linux.ibm.com>,
Dick Kennedy <dick.kennedy@broadcom.com>,
James Smart <james.smart@broadcom.com>,
linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-hardening@vger.kernel.org
Subject: Re: [PATCH 1/2][next] scsi: lpfc: Replace one-element array with flexible-array member
Date: Tue, 23 May 2023 13:29:45 -0700 [thread overview]
Message-ID: <9ECC5C8E-D8E1-4444-BC47-D49FE015144D@kernel.org> (raw)
In-Reply-To: <3d298c36-cdd8-62bd-2fef-c2ce63e662ef@embeddedor.com>
On May 23, 2023 12:46:54 PM PDT, "Gustavo A. R. Silva" <gustavo@embeddedor.com> wrote:
>
>
>On 5/23/23 11:31, Kees Cook wrote:
>> On Mon, May 22, 2023 at 06:02:21PM -0400, Martin K. Petersen wrote:
>>>
>>> Gustavo,
>>>
>>>> One-element arrays are deprecated, and we are replacing them with flexible
>>>> array members instead. So, replace one-element arrays with flexible-array
>>>> members in a couple of structures, and refactor the rest of the code,
>>>> accordingly.
>>>>
>>>> This helps with the ongoing efforts to tighten the FORTIFY_SOURCE
>>>> routines on memcpy() and help us make progress towards globally
>>>> enabling -fstrict-flex-arrays=3 [1].
>>>>
>>>> This results in no differences in binary output.
>>>
>>> Applied to 6.5/scsi-staging, thanks!
>>
>> Martin, I think this patch is not right -- can you drop this from
>> staging for the moment?
>
>Martin just took patch 1/2, which is correct:
>
>https://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git/commit/?h=6.5/scsi-staging&id=e90644b0ce2d700a65579ac74ff594414e8ba30f
Oops, yes, I thought both got pulled. 1/2 is fine. :)
-Kees
--
Kees Cook
next prev parent reply other threads:[~2023-05-23 20:29 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-17 21:22 [PATCH 0/2][next] scsi: lpfc: Replace one-element array with flexible-array member Gustavo A. R. Silva
2023-05-17 21:22 ` [PATCH 1/2][next] " Gustavo A. R. Silva
2023-05-17 23:02 ` Kees Cook
2023-05-22 22:02 ` Martin K. Petersen
2023-05-22 22:12 ` Gustavo A. R. Silva
2023-05-23 17:31 ` Kees Cook
2023-05-23 19:46 ` Gustavo A. R. Silva
2023-05-23 20:29 ` Kees Cook [this message]
2023-05-17 21:23 ` [PATCH 2/2][next] scsi: lpfc: Use struct_size() helper Gustavo A. R. Silva
2023-05-17 23:01 ` Kees Cook
2023-05-23 14:41 ` Gustavo A. R. Silva
2023-05-23 17:27 ` Kees Cook
2023-06-01 0:43 ` [PATCH 0/2][next] scsi: lpfc: Replace one-element array with flexible-array member Martin K. Petersen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9ECC5C8E-D8E1-4444-BC47-D49FE015144D@kernel.org \
--to=kees@kernel.org \
--cc=dick.kennedy@broadcom.com \
--cc=gustavo@embeddedor.com \
--cc=gustavoars@kernel.org \
--cc=james.smart@broadcom.com \
--cc=jejb@linux.ibm.com \
--cc=keescook@chromium.org \
--cc=linux-hardening@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).