aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/keyboard
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/keyboard')
-rw-r--r--drivers/input/keyboard/pxa27x_keypad.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c
index 5446ad4e4aeb..186138c720c7 100644
--- a/drivers/input/keyboard/pxa27x_keypad.c
+++ b/drivers/input/keyboard/pxa27x_keypad.c
@@ -787,10 +787,17 @@ static int pxa27x_keypad_probe(struct platform_device *pdev)
787 input_dev->evbit[0] = BIT_MASK(EV_KEY) | BIT_MASK(EV_REP); 787 input_dev->evbit[0] = BIT_MASK(EV_KEY) | BIT_MASK(EV_REP);
788 input_set_capability(input_dev, EV_MSC, MSC_SCAN); 788 input_set_capability(input_dev, EV_MSC, MSC_SCAN);
789 789
790 if (pdata) 790 if (pdata) {
791 error = pxa27x_keypad_build_keycode(keypad); 791 error = pxa27x_keypad_build_keycode(keypad);
792 else 792 } else {
793 error = pxa27x_keypad_build_keycode_from_dt(keypad); 793 error = pxa27x_keypad_build_keycode_from_dt(keypad);
794 /*
795 * Data that we get from DT resides in dynamically
796 * allocated memory so we need to update our pdata
797 * pointer.
798 */
799 pdata = keypad->pdata;
800 }
794 if (error) { 801 if (error) {
795 dev_err(&pdev->dev, "failed to build keycode\n"); 802 dev_err(&pdev->dev, "failed to build keycode\n");
796 goto failed_put_clk; 803 goto failed_put_clk;