diff options
Diffstat (limited to 'arch/arm/mach-omap2/gpio.c')
-rw-r--r-- | arch/arm/mach-omap2/gpio.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/gpio.c b/arch/arm/mach-omap2/gpio.c index 9ad7d489b0de..e7b246da02d0 100644 --- a/arch/arm/mach-omap2/gpio.c +++ b/arch/arm/mach-omap2/gpio.c | |||
@@ -21,6 +21,7 @@ | |||
21 | #include <linux/slab.h> | 21 | #include <linux/slab.h> |
22 | #include <linux/interrupt.h> | 22 | #include <linux/interrupt.h> |
23 | #include <linux/of.h> | 23 | #include <linux/of.h> |
24 | #include <linux/platform_data/gpio-omap.h> | ||
24 | 25 | ||
25 | #include <plat/omap_hwmod.h> | 26 | #include <plat/omap_hwmod.h> |
26 | #include <plat/omap_device.h> | 27 | #include <plat/omap_device.h> |
@@ -60,6 +61,7 @@ static int __init omap2_gpio_dev_init(struct omap_hwmod *oh, void *unused) | |||
60 | pdata->regs = kzalloc(sizeof(struct omap_gpio_reg_offs), GFP_KERNEL); | 61 | pdata->regs = kzalloc(sizeof(struct omap_gpio_reg_offs), GFP_KERNEL); |
61 | if (!pdata->regs) { | 62 | if (!pdata->regs) { |
62 | pr_err("gpio%d: Memory allocation failed\n", id); | 63 | pr_err("gpio%d: Memory allocation failed\n", id); |
64 | kfree(pdata); | ||
63 | return -ENOMEM; | 65 | return -ENOMEM; |
64 | } | 66 | } |
65 | 67 | ||