diff options
author | Zheng Yongjun <zhengyongjun3@huawei.com> | 2020-12-29 14:51:47 +0100 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2021-03-24 12:44:04 +0100 |
commit | d995d3d025bbd2d89abf12418f20d19bc0cb0130 (patch) | |
tree | 091f89d9cf1b7e2cbb164d51cc538ffae5dc4468 /drivers/bus | |
parent | bus: ti-sysc: remove unneeded semicolon (diff) | |
download | linux-d995d3d025bbd2d89abf12418f20d19bc0cb0130.tar.xz linux-d995d3d025bbd2d89abf12418f20d19bc0cb0130.zip |
bus: ti-sysc: 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>
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'drivers/bus')
-rw-r--r-- | drivers/bus/ti-sysc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/bus/ti-sysc.c b/drivers/bus/ti-sysc.c index cd32eaff3d83..8880259b41ae 100644 --- a/drivers/bus/ti-sysc.c +++ b/drivers/bus/ti-sysc.c @@ -288,7 +288,7 @@ static int sysc_add_named_clock_from_child(struct sysc *ddata, * limit for clk_get(). If cl ever needs to be freed, it should be done * with clkdev_drop(). */ - cl = kcalloc(1, sizeof(*cl), GFP_KERNEL); + cl = kzalloc(sizeof(*cl), GFP_KERNEL); if (!cl) return -ENOMEM; |