aboutsummaryrefslogtreecommitdiff
path: root/drivers/i2c/muxes
diff options
context:
space:
mode:
authorLaurent Navet <laurent.navet@gmail.com>2013-01-08 14:40:09 +0100
committerWolfram Sang <w.sang@pengutronix.de>2013-01-22 09:54:32 +0100
commit43a2bd42d077de6ad40b00a2abfc4677e24d239c (patch)
tree780659f4b05f32586cded38efbee30e5e789302f /drivers/i2c/muxes
parentbfd059da9503e0091541285cb0481f66b95c0296 (diff)
downloadlinux-linaro-stable-43a2bd42d077de6ad40b00a2abfc4677e24d239c.tar.gz
i2c: muxes: fix wrong use of sizeof(ptr)
sizeof when applied to a pointer typed expression gives the size of the pointer The semantic patch that makes this output is available in scripts/coccinelle/misc/noderef.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Laurent Navet <laurent.navet@gmail.com> Acked-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Diffstat (limited to 'drivers/i2c/muxes')
-rw-r--r--drivers/i2c/muxes/i2c-mux-pinctrl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/muxes/i2c-mux-pinctrl.c b/drivers/i2c/muxes/i2c-mux-pinctrl.c
index 1e44d04d1b22..a43c0ce5e3d8 100644
--- a/drivers/i2c/muxes/i2c-mux-pinctrl.c
+++ b/drivers/i2c/muxes/i2c-mux-pinctrl.c
@@ -167,7 +167,7 @@ static int i2c_mux_pinctrl_probe(struct platform_device *pdev)
}
mux->busses = devm_kzalloc(&pdev->dev,
- sizeof(mux->busses) * mux->pdata->bus_count,
+ sizeof(*mux->busses) * mux->pdata->bus_count,
GFP_KERNEL);
if (!mux->busses) {
dev_err(&pdev->dev, "Cannot allocate busses\n");