summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl
diff options
context:
space:
mode:
authorMagnus Damm <damm@opensource.se>2013-02-14 13:23:47 +0100
committerSimon Horman <horms+renesas@verge.net.au>2013-02-16 02:58:50 +0100
commit8c43fcc7804fc4609ccd9fa021e21f5423db9d96 (patch)
treef60eb9aa77e185c743d86a9bdac8caa33b5b0b38 /drivers/pinctrl
parentsh-pfc: Move sh_pfc.h from include/linux/ to driver directory (diff)
downloadlinux-8c43fcc7804fc4609ccd9fa021e21f5423db9d96.tar.xz
linux-8c43fcc7804fc4609ccd9fa021e21f5423db9d96.zip
sh-pfc: sh_pfc_probe() sizeof() fix
Fix sizeof() usage in sh-pfc/core.c to allocate space for the full data structure instead of a pointer. Signed-off-by: Magnus Damm <damm@opensource.se> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r--drivers/pinctrl/sh-pfc/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pinctrl/sh-pfc/core.c b/drivers/pinctrl/sh-pfc/core.c
index d323c24fffaf..970ddff2b0b6 100644
--- a/drivers/pinctrl/sh-pfc/core.c
+++ b/drivers/pinctrl/sh-pfc/core.c
@@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_device *pdev)
if (info == NULL)
return -ENODEV;
- pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
+ pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
if (pfc == NULL)
return -ENOMEM;