From: Kalle Valo <kvalo@codeaurora.org>
To: "Gustavo A. R. Silva" <gustavoars@kernel.org>
Cc: Len Baker <len.baker@gmx.com>,
Arend van Spriel <aspriel@gmail.com>,
Franky Lin <franky.lin@broadcom.com>,
Hante Meuleman <hante.meuleman@broadcom.com>,
Chi-hsien Lin <chi-hsien.lin@infineon.com>,
Wright Feng <wright.feng@infineon.com>,
Chung-hsien Hsu <chung-hsien.hsu@infineon.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
"Gustavo A. R. Silva" <gustavo@embeddedor.com>,
Kees Cook <keescook@chromium.org>,
Shawn Guo <shawn.guo@linaro.org>,
linux-wireless@vger.kernel.org,
brcm80211-dev-list.pdl@broadcom.com,
SHA-cyfmac-dev-list@infineon.com, netdev@vger.kernel.org,
linux-hardening@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] brcmfmac: Replace zero-length array with flexible array member
Date: Thu, 16 Sep 2021 18:17:31 +0300 [thread overview]
Message-ID: <87o88sy2gk.fsf@codeaurora.org> (raw)
In-Reply-To: <20210912191536.GB146608@embeddedor> (Gustavo A. R. Silva's message of "Sun, 12 Sep 2021 14:15:36 -0500")
"Gustavo A. R. Silva" <gustavoars@kernel.org> writes:
> On Sat, Sep 04, 2021 at 11:22:17AM +0200, Len Baker wrote:
>> There is a regular need in the kernel to provide a way to declare
>> having a dynamically sized set of trailing elements in a structure.
>> Kernel code should always use "flexible array members"[1] for these
>> cases. The older style of one-element or zero-length arrays should
>> no longer be used[2].
>>
>> Also, make use of the struct_size() helper in devm_kzalloc().
>>
>> [1] https://en.wikipedia.org/wiki/Flexible_array_member
>> [2] https://www.kernel.org/doc/html/v5.14/process/deprecated.html#zero-length-and-one-element-arrays
>>
>> Signed-off-by: Len Baker <len.baker@gmx.com>
>
> Reviewed-by: Gustavo A. R. Silva <gustavoars@kernel.org>
>
> I'll take this in my -next tree. :)
Why? It should go to wireless-drivers-next.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
next prev parent reply other threads:[~2021-09-16 15:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-04 9:22 [PATCH] brcmfmac: Replace zero-length array with flexible array member Len Baker
2021-09-12 19:15 ` Gustavo A. R. Silva
2021-09-16 15:17 ` Kalle Valo [this message]
2021-09-21 5:55 ` Kalle Valo
2021-09-21 17:37 ` Gustavo A. R. Silva
2021-09-24 11:20 ` Kalle Valo
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=87o88sy2gk.fsf@codeaurora.org \
--to=kvalo@codeaurora.org \
--cc=SHA-cyfmac-dev-list@infineon.com \
--cc=aspriel@gmail.com \
--cc=brcm80211-dev-list.pdl@broadcom.com \
--cc=chi-hsien.lin@infineon.com \
--cc=chung-hsien.hsu@infineon.com \
--cc=davem@davemloft.net \
--cc=franky.lin@broadcom.com \
--cc=gustavo@embeddedor.com \
--cc=gustavoars@kernel.org \
--cc=hante.meuleman@broadcom.com \
--cc=keescook@chromium.org \
--cc=kuba@kernel.org \
--cc=len.baker@gmx.com \
--cc=linux-hardening@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=shawn.guo@linaro.org \
--cc=wright.feng@infineon.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).