diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2012-10-05 05:37:38 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2012-10-15 14:50:13 -0400 |
commit | 086d585f13542de205c25fd225a37aa0cadc3be0 (patch) | |
tree | 728dcd90e31619e8498c35fe9809b98ae8911dcb /drivers | |
parent | 8944df726c7d2916764d18be8e944bd7ea3f2f51 (diff) |
gpio/gpio-omap: Use existing pointer to struct device
A pointer to "pdev->dev" is already stored in "dev", so use it in
devm_kzalloc.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Acked-by: Kevin Hilman <khilman@ti.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpio/gpio-omap.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index 94cbc842fbc3..eb73dee0ab33 100644 --- a/drivers/gpio/gpio-omap.c +++ b/drivers/gpio/gpio-omap.c | |||
@@ -1070,7 +1070,7 @@ static int __devinit omap_gpio_probe(struct platform_device *pdev) | |||
1070 | if (!pdata) | 1070 | if (!pdata) |
1071 | return -EINVAL; | 1071 | return -EINVAL; |
1072 | 1072 | ||
1073 | bank = devm_kzalloc(&pdev->dev, sizeof(struct gpio_bank), GFP_KERNEL); | 1073 | bank = devm_kzalloc(dev, sizeof(struct gpio_bank), GFP_KERNEL); |
1074 | if (!bank) { | 1074 | if (!bank) { |
1075 | dev_err(dev, "Memory alloc failed\n"); | 1075 | dev_err(dev, "Memory alloc failed\n"); |
1076 | return -ENOMEM; | 1076 | return -ENOMEM; |