Skip to content

Commit

Permalink
staging: mt7621-pinctrl: Use correct pointer type argument for sizeof
Browse files Browse the repository at this point in the history
Fix the following coccicheck warning:

drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c:223:14-36: WARNING: Use
correct pointer type argument for sizeof

Signed-off-by: Jason Yan <yanaijie@huawei.com>
Link: https://lore.kernel.org/r/20200420133416.3087-1-yanaijie@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Jason Yan authored and Greg Kroah-Hartman committed Apr 23, 2020
1 parent e955a07 commit 5975b85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ static int rt2880_pinmux_index(struct rt2880_priv *p)
/* allocate our function and group mapping index buffers */
f = p->func = devm_kcalloc(p->dev,
p->func_count,
sizeof(struct rt2880_pmx_func),
sizeof(*p->func),
GFP_KERNEL);
gpio_func.groups = devm_kcalloc(p->dev, p->group_count, sizeof(int),
GFP_KERNEL);
Expand Down

0 comments on commit 5975b85

Please sign in to comment.