Input: gpio_keys_polled - fix dt pdata->nbuttons
pdata->nbuttons should be updated by the dt code. Signed-off-by: Alexandre Pereira da Silva <aletes.xgr@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
parent
caaa357dc0
commit
8757145af0
@ -129,6 +129,7 @@ gpio_keys_polled_get_devtree_pdata(struct device *dev)
|
||||
}
|
||||
|
||||
pdata->buttons = (struct gpio_keys_button *)(pdata + 1);
|
||||
pdata->nbuttons = nbuttons;
|
||||
|
||||
pdata->rep = !!of_get_property(node, "autorepeat", NULL);
|
||||
of_property_read_u32(node, "poll-interval", &pdata->poll_interval);
|
||||
|
Loading…
Reference in New Issue
Block a user