Skip to content

Commit

Permalink
Input: ads7846 - set input device bus type and product ID
Browse files Browse the repository at this point in the history
Set input device's bus type as BUS_SPI and use model as product ID.

Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Dmitry Torokhov <[email protected]>
  • Loading branch information
dtor committed Oct 16, 2021
1 parent 872e57a commit 9271cda
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/input/touchscreen/ads7846.c
Original file line number Diff line number Diff line change
Expand Up @@ -1304,6 +1304,9 @@ static int ads7846_probe(struct spi_device *spi)
input_dev->name = ts->name;
input_dev->phys = ts->phys;

input_dev->id.bustype = BUS_SPI;
input_dev->id.product = pdata->model;

input_dev->evbit[0] = BIT_MASK(EV_KEY) | BIT_MASK(EV_ABS);
input_dev->keybit[BIT_WORD(BTN_TOUCH)] = BIT_MASK(BTN_TOUCH);
input_set_abs_params(input_dev, ABS_X,
Expand Down

0 comments on commit 9271cda

Please sign in to comment.