Re: [PATCH 01/10] dm snapshot: Use kmalloc_array() in init_origin_hash()

From: Paul Bolle
Date: Thu Sep 29 2016 - 17:15:12 EST


On Thu, 2016-09-29 at 13:56 -0700, Joe Perches wrote:
> It doesn't matter match either way to me.
>
> The case for the unnecessary multiply with <= gcc 4.8 was
> removed with:
>
> commit 91c6a05f72a996bee5133e76374ab3ad7d3b9b72
> Author: Alexey Dobriyan <adobriyan@xxxxxxxxx>
> Date:ÂÂÂTue Jul 26 15:22:08 2016 -0700
>
> ÂÂÂÂmm: faster kmalloc_array(), kcalloc()
> ÂÂÂÂ
> ÂÂÂÂWhen both arguments to kmalloc_array() or kcalloc() are known at compile
> ÂÂÂÂtime then their product is known at compile time but search for kmalloc
> ÂÂÂÂcache happens at runtime not at compile time.
> ÂÂÂÂ
> ÂÂÂÂLink: http://lkml.kernel.org/r/20160627213454.GA2440@xxxxxxxxxxxxxxx
> ÂÂÂÂSigned-off-by: Alexey Dobriyan <adobriyan@xxxxxxxxx>
> ÂÂÂÂCc: Christoph Lameter <cl@xxxxxxxxx>
> ÂÂÂÂCc: Pekka Enberg <penberg@xxxxxxxxxx>
> ÂÂÂÂCc: David Rientjes <rientjes@xxxxxxxxxx>
> ÂÂÂÂCc: Joonsoo Kim <iamjoonsoo.kim@xxxxxxx>
> ÂÂÂÂSigned-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
> ÂÂÂÂSigned-off-by: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>

You've lost me.

Why does this stop you fixing an apparently wrong checkpatch rule,
crude as parts of it are (ie, uppercase identifier must be a constant)?


Paul Bolle