Lines Matching defs:input
4 * This is a generic input driver that connects to an ADC
5 * given the channels in device tree, and reports events to the input
12 #include <linux/input.h>
13 #include <linux/input/touchscreen.h>
43 * @input: the input device structure that we register
53 struct input_dev *input;
94 input_report_key(st->input, BTN_TOUCH, 0);
95 input_sync(st->input);
100 touchscreen_report_pos(st->input, &st->prop, x, y, false);
102 input_report_abs(st->input, ABS_PRESSURE, press);
103 input_report_key(st->input, BTN_TOUCH, 1);
104 input_sync(st->input);
203 struct input_dev *input;
235 input = devm_input_allocate_device(dev);
236 if (!input) {
237 dev_err(dev, "failed to allocate input device.\n");
241 input->name = DRIVER_NAME;
242 input->id.bustype = BUS_HOST;
243 input->open = grts_open;
244 input->close = grts_close;
246 input_set_abs_params(input, ABS_X, 0, GRTS_MAX_POS_MASK - 1, 0, 0);
247 input_set_abs_params(input, ABS_Y, 0, GRTS_MAX_POS_MASK - 1, 0, 0);
249 input_set_abs_params(input, ABS_PRESSURE, st->pressure_min,
252 input_set_capability(input, EV_KEY, BTN_TOUCH);
255 touchscreen_parse_properties(input, false, &st->prop);
257 st->input = input;
258 input_set_drvdata(input, st);
260 error = input_register_device(input);
262 dev_err(dev, "failed to register input device.");