]> git.baikalelectronics.ru Git - kernel.git/commit
staging: greybus: light: Use kzalloc for allocating only one thing
authorZheng Yongjun <zhengyongjun3@huawei.com>
Wed, 30 Dec 2020 01:37:06 +0000 (09:37 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 5 Jan 2021 14:26:43 +0000 (15:26 +0100)
commitedb0d7f24f721b7ddb5cc56dd5fadb7551d338a7
treeabe9c6cd090cd71def3d93f36df3d57723c3457e
parent32de242b4f8c08ca58bb78c22822bf05fb817deb
staging: greybus: light: Use kzalloc for allocating only one thing

Use kzalloc rather than kcalloc(1,...)

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
@@

- kcalloc(1,
+ kzalloc(
          ...)
// </smpl>

Reviewed-by: Alex Elder <elder@linaro.org>
Reviewed-by: Rui Miguel Silva <rmfrfs@gmail.com>
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Link: https://lore.kernel.org/r/20201230013706.28698-1-zhengyongjun3@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/greybus/light.c