Commit 5975b85a authored by Jason Yan's avatar Jason Yan Committed by Greg Kroah-Hartman

staging: mt7621-pinctrl: Use correct pointer type argument for sizeof

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: default avatarJason Yan <yanaijie@huawei.com>
Link: https://lore.kernel.org/r/20200420133416.3087-1-yanaijie@huawei.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e955a071
......@@ -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);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment