From 131c713fd96e251fcb18f4d2d05f263aa41bb11f Mon Sep 17 00:00:00 2001 From: Viresh Kumar Date: Mon, 26 Mar 2012 23:55:24 -0700 Subject: [PATCH] Input: tegra-kbc - allocate pdata before using it Following commit broke DT support for tegra-kbc by removing pdata allocation completely: commit 023cea0ecfa2df034096c3f4afa796a0b2d1188a Author: Shridhar Rasal Date: Fri Feb 3 00:27:30 2012 -0800 Input: tegra-kbc - allow skipping setting up some of GPIO pins This patch restores it. Signed-off-by: Viresh Kumar Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/tegra-kbc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/input/keyboard/tegra-kbc.c b/drivers/input/keyboard/tegra-kbc.c index 21c42f852343..fe4ac95ca6c8 100644 --- a/drivers/input/keyboard/tegra-kbc.c +++ b/drivers/input/keyboard/tegra-kbc.c @@ -630,6 +630,7 @@ tegra_kbc_dt_parse_pdata(struct platform_device *pdev) if (!np) return NULL; + pdata = kzalloc(sizeof(*pdata), GFP_KERNEL); if (!pdata) return NULL;