Allow the keypad device name to be customised via platform data.
Signed-off-by: Daniel Stone <daniel.stone@nokia.com>
Signed-off-by: Klaus Pedersen <klaus.k.pedersen@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
-1, /* Event for bit 15 */
},
.kp_rep = 0,
+ .keyb_name = "Internal keypad",
};
static void tsc2301_dev_init(void)
r = -ENOMEM;
goto err1;
}
- idev->name = "TSC2301 keypad";
+ if (pdata->keyb_name)
+ idev->name = pdata->keyb_name;
+ else
+ idev->name = "TSC2301 keypad";
snprintf(kp->phys, sizeof(kp->phys), "%s/input-kp", tsc->spi->dev.bus_id);
idev->phys = kp->phys;
s16 keyb_int;
s16 keymap[16]; /* Set a key to a negative value if not used */
unsigned kp_rep:1; /* Enable keypad repeating */
+ char *keyb_name; /* Keyboard device name */
/*
* Touchscreen