summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Yan <yanaijie@huawei.com>2020-04-20 21:34:16 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-04-23 13:36:20 +0200
commit5975b85ae244dd607965518129e816e4072bc976 (patch)
tree4ee01f555449d7269b1f459f0fc5078ca9d34d6a
parente955a071b9b3e6b634b7ceda64025bfbd6529dcc (diff)
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: 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>
-rw-r--r--drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
index d0f06790d38f..caaf9e34f1ee 100644
--- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
+++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
@@ -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);