All of lore.kernel.org
 help / color / mirror / Atom feed
From: Herbert Xu <herbert@gondor.apana.org.au>
To: Julia Lawall <julia.lawall@inria.fr>
Cc: Megha Dey <megha.dey@intel.com>,
	labuser <labuser@ssp-romleySNB-cdi172.jf.intel.com>,
	Tomasz Kantecki <tomasz.kantecki@intel.com>,
	linux-crypto@vger.kernel.org, kbuild-all@lists.01.org
Subject: Re: [PATCH] crypto: fix flexible_array.cocci warnings
Date: Fri, 16 Jul 2021 15:26:21 +0800	[thread overview]
Message-ID: <20210716072621.GA7555@gondor.apana.org.au> (raw)
In-Reply-To: <alpine.DEB.2.22.394.2106291346290.4909@hadrien>

On Tue, Jun 29, 2021 at 01:48:01PM +0200, Julia Lawall wrote:
> From: kernel test robot <lkp@intel.com>
> 
> Zero-length and one-element arrays are deprecated, see
> Documentation/process/deprecated.rst
> Flexible-array members should be used instead.
> 
> Generated by: scripts/coccinelle/misc/flexible_array.cocci
> 
> Fixes: 7540b2861e52 ("crypto: aesni - AVX512 version of AESNI-GCM using VPCLMULQDQ")
> CC: Megha Dey <megha.dey@intel.com>
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
> ---
> 
> tree:   https://github.com/meghadey/crypto for_crypto_avx512
> head:   a89c5880f0d6260dd593bf579df26f2a2d56ac32
> commit: 7540b2861e5292b5993f8e693fc69510b2a7277a [5/6] crypto: aesni - AVX512 version of AESNI-GCM using VPCLMULQDQ
> :::::: branch date: 7 hours ago
> :::::: commit date: 7 hours ago
> 
>  aesni-intel_glue.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/arch/x86/crypto/aesni-intel_glue.c
> +++ b/arch/x86/crypto/aesni-intel_glue.c
> @@ -87,7 +87,7 @@ struct gcm_context_data {
>  	u64 partial_block_len;
>  	u64 unused;
>  	/* Allocate space for hash_keys later */
> -	u8 hash_keys[0];
> +	u8 hash_keys[];

Unfortunately this patch doesn't apply to the current crypto tree.
But the good news is that the current tree no longer has a zero-
length array in that struct.

Thanks,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

WARNING: multiple messages have this Message-ID (diff)
From: Herbert Xu <herbert@gondor.apana.org.au>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH] crypto: fix flexible_array.cocci warnings
Date: Fri, 16 Jul 2021 15:26:21 +0800	[thread overview]
Message-ID: <20210716072621.GA7555@gondor.apana.org.au> (raw)
In-Reply-To: <alpine.DEB.2.22.394.2106291346290.4909@hadrien>

[-- Attachment #1: Type: text/plain, Size: 1623 bytes --]

On Tue, Jun 29, 2021 at 01:48:01PM +0200, Julia Lawall wrote:
> From: kernel test robot <lkp@intel.com>
> 
> Zero-length and one-element arrays are deprecated, see
> Documentation/process/deprecated.rst
> Flexible-array members should be used instead.
> 
> Generated by: scripts/coccinelle/misc/flexible_array.cocci
> 
> Fixes: 7540b2861e52 ("crypto: aesni - AVX512 version of AESNI-GCM using VPCLMULQDQ")
> CC: Megha Dey <megha.dey@intel.com>
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
> ---
> 
> tree:   https://github.com/meghadey/crypto for_crypto_avx512
> head:   a89c5880f0d6260dd593bf579df26f2a2d56ac32
> commit: 7540b2861e5292b5993f8e693fc69510b2a7277a [5/6] crypto: aesni - AVX512 version of AESNI-GCM using VPCLMULQDQ
> :::::: branch date: 7 hours ago
> :::::: commit date: 7 hours ago
> 
>  aesni-intel_glue.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/arch/x86/crypto/aesni-intel_glue.c
> +++ b/arch/x86/crypto/aesni-intel_glue.c
> @@ -87,7 +87,7 @@ struct gcm_context_data {
>  	u64 partial_block_len;
>  	u64 unused;
>  	/* Allocate space for hash_keys later */
> -	u8 hash_keys[0];
> +	u8 hash_keys[];

Unfortunately this patch doesn't apply to the current crypto tree.
But the good news is that the current tree no longer has a zero-
length array in that struct.

Thanks,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

  reply	other threads:[~2021-07-16  7:26 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-29 11:48 [PATCH] crypto: fix flexible_array.cocci warnings Julia Lawall
2021-06-29 11:48 ` Julia Lawall
2021-07-16  7:26 ` Herbert Xu [this message]
2021-07-16  7:26   ` Herbert Xu
  -- strict thread matches above, loose matches on Subject: below --
2021-11-12 10:56 Julia Lawall
2021-11-12 10:56 ` Julia Lawall
2021-11-20  4:06 ` Herbert Xu
2021-11-20  4:06   ` Herbert Xu
2021-11-24  3:17   ` Chen, Rong A
2021-11-11  5:41 [meghadey-crypto:crypto-avx512 5/6] arch/x86/crypto/aesni-intel_glue.c:90:4-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) kernel test robot
2021-11-11  5:41 ` [PATCH] crypto: fix flexible_array.cocci warnings kernel test robot
2021-10-25  1:52 [meghadey-crypto:crypto-avx512 5/6] arch/x86/crypto/aesni-intel_glue.c:90:4-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) kernel test robot
2021-10-25  1:52 ` [PATCH] crypto: fix flexible_array.cocci warnings kernel test robot
2021-10-01  2:46 [meghadey-crypto:crypto-avx512 5/6] arch/x86/crypto/aesni-intel_glue.c:90:4-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) kernel test robot
2021-10-01  2:47 ` [PATCH] crypto: fix flexible_array.cocci warnings kernel test robot
2021-06-29  0:14 [meghadey-crypto:for_crypto_avx512 5/6] arch/x86/crypto/aesni-intel_glue.c:90:4-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) kernel test robot
2021-06-29  0:14 ` [PATCH] crypto: fix flexible_array.cocci warnings kernel test robot
2021-01-22  2:24 [km13park-linux-1:master 7/7] arch/x86/crypto/aesni-intel_glue.c:90:4-13: WARNING use flexible-array member instead (https://www.kernel.org/doc/html/latest/process/deprecated.html#zero-length-and-one-element-arrays) kernel test robot
2021-01-22  2:24 ` [PATCH] crypto: fix flexible_array.cocci warnings kernel test robot

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=20210716072621.GA7555@gondor.apana.org.au \
    --to=herbert@gondor.apana.org.au \
    --cc=julia.lawall@inria.fr \
    --cc=kbuild-all@lists.01.org \
    --cc=labuser@ssp-romleySNB-cdi172.jf.intel.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=megha.dey@intel.com \
    --cc=tomasz.kantecki@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.