From 8c43fcc7804fc4609ccd9fa021e21f5423db9d96 Mon Sep 17 00:00:00 2001 From: Magnus Damm Date: Thu, 14 Feb 2013 21:23:47 +0900 Subject: 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 Acked-by: Laurent Pinchart Acked-by: Linus Walleij Signed-off-by: Simon Horman --- drivers/pinctrl/sh-pfc/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/pinctrl') diff --git a/drivers/pinctrl/sh-pfc/core.c b/drivers/pinctrl/sh-pfc/core.c index d323c24fffa..970ddff2b0b 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; -- cgit v1.2.3-18-g5258