Lines Matching refs:input
258 struct input_dev *input; in surface3_spi_create_touch_input() local
261 input = devm_input_allocate_device(&data->spi->dev); in surface3_spi_create_touch_input()
262 if (!input) in surface3_spi_create_touch_input()
265 data->input_dev = input; in surface3_spi_create_touch_input()
267 input_set_abs_params(input, ABS_MT_POSITION_X, 0, 9600, 0, 0); in surface3_spi_create_touch_input()
268 input_abs_set_res(input, ABS_MT_POSITION_X, 40); in surface3_spi_create_touch_input()
269 input_set_abs_params(input, ABS_MT_POSITION_Y, 0, 7200, 0, 0); in surface3_spi_create_touch_input()
270 input_abs_set_res(input, ABS_MT_POSITION_Y, 48); in surface3_spi_create_touch_input()
271 input_set_abs_params(input, ABS_MT_WIDTH_MAJOR, 0, 1024, 0, 0); in surface3_spi_create_touch_input()
272 input_set_abs_params(input, ABS_MT_WIDTH_MINOR, 0, 1024, 0, 0); in surface3_spi_create_touch_input()
273 input_mt_init_slots(input, 10, INPUT_MT_DIRECT); in surface3_spi_create_touch_input()
275 input->name = "Surface3 SPI Capacitive TouchScreen"; in surface3_spi_create_touch_input()
276 input->phys = "input/ts"; in surface3_spi_create_touch_input()
277 input->id.bustype = BUS_SPI; in surface3_spi_create_touch_input()
278 input->id.vendor = 0x045e; /* Microsoft */ in surface3_spi_create_touch_input()
279 input->id.product = 0x0001; in surface3_spi_create_touch_input()
280 input->id.version = 0x0000; in surface3_spi_create_touch_input()
282 error = input_register_device(input); in surface3_spi_create_touch_input()
294 struct input_dev *input; in surface3_spi_create_pen_input() local
297 input = devm_input_allocate_device(&data->spi->dev); in surface3_spi_create_pen_input()
298 if (!input) in surface3_spi_create_pen_input()
301 data->pen_input_dev = input; in surface3_spi_create_pen_input()
304 __set_bit(INPUT_PROP_DIRECT, input->propbit); in surface3_spi_create_pen_input()
305 __set_bit(INPUT_PROP_POINTER, input->propbit); in surface3_spi_create_pen_input()
306 input_set_abs_params(input, ABS_X, 0, 9600, 0, 0); in surface3_spi_create_pen_input()
307 input_abs_set_res(input, ABS_X, 40); in surface3_spi_create_pen_input()
308 input_set_abs_params(input, ABS_Y, 0, 7200, 0, 0); in surface3_spi_create_pen_input()
309 input_abs_set_res(input, ABS_Y, 48); in surface3_spi_create_pen_input()
310 input_set_abs_params(input, ABS_PRESSURE, 0, 1024, 0, 0); in surface3_spi_create_pen_input()
311 input_set_capability(input, EV_KEY, BTN_TOUCH); in surface3_spi_create_pen_input()
312 input_set_capability(input, EV_KEY, BTN_STYLUS); in surface3_spi_create_pen_input()
313 input_set_capability(input, EV_KEY, BTN_TOOL_PEN); in surface3_spi_create_pen_input()
314 input_set_capability(input, EV_KEY, BTN_TOOL_RUBBER); in surface3_spi_create_pen_input()
316 input->name = "Surface3 SPI Pen Input"; in surface3_spi_create_pen_input()
317 input->phys = "input/ts"; in surface3_spi_create_pen_input()
318 input->id.bustype = BUS_SPI; in surface3_spi_create_pen_input()
319 input->id.vendor = 0x045e; /* Microsoft */ in surface3_spi_create_pen_input()
320 input->id.product = 0x0002; in surface3_spi_create_pen_input()
321 input->id.version = 0x0000; in surface3_spi_create_pen_input()
323 error = input_register_device(input); in surface3_spi_create_pen_input()