Lines Matching refs:input_dev
158 struct mousevsc_dev *input_dev; in mousevsc_alloc_device() local
160 input_dev = kzalloc(sizeof(struct mousevsc_dev), GFP_KERNEL); in mousevsc_alloc_device()
162 if (!input_dev) in mousevsc_alloc_device()
165 input_dev->device = device; in mousevsc_alloc_device()
166 hv_set_drvdata(device, input_dev); in mousevsc_alloc_device()
167 init_completion(&input_dev->wait_event); in mousevsc_alloc_device()
168 input_dev->init_complete = false; in mousevsc_alloc_device()
170 return input_dev; in mousevsc_alloc_device()
254 struct mousevsc_dev *input_dev = hv_get_drvdata(device); in mousevsc_on_receive() local
280 memcpy(&input_dev->protocol_resp, pipe_msg, in mousevsc_on_receive()
283 complete(&input_dev->wait_event); in mousevsc_on_receive()
293 mousevsc_on_receive_device_info(input_dev, in mousevsc_on_receive()
299 if (!input_dev->init_complete) in mousevsc_on_receive()
303 (u32)sizeof(input_dev->input_buf)); in mousevsc_on_receive()
304 memcpy(input_dev->input_buf, input_report->buffer, len); in mousevsc_on_receive()
305 hid_input_report(input_dev->hid_device, HID_INPUT_REPORT, in mousevsc_on_receive()
306 input_dev->input_buf, len, 1); in mousevsc_on_receive()
308 pm_wakeup_hard_event(&input_dev->device->device); in mousevsc_on_receive()
345 struct mousevsc_dev *input_dev = hv_get_drvdata(device); in mousevsc_connect_to_vsp() local
349 reinit_completion(&input_dev->wait_event); in mousevsc_connect_to_vsp()
351 request = &input_dev->protocol_req; in mousevsc_connect_to_vsp()
370 t = wait_for_completion_timeout(&input_dev->wait_event, 5*HZ); in mousevsc_connect_to_vsp()
376 response = &input_dev->protocol_resp; in mousevsc_connect_to_vsp()
385 t = wait_for_completion_timeout(&input_dev->wait_event, 5*HZ); in mousevsc_connect_to_vsp()
395 ret = input_dev->dev_info_status; in mousevsc_connect_to_vsp()
404 struct mousevsc_dev *input_dev = hv_get_drvdata(dev); in mousevsc_hid_parse() local
406 return hid_parse_report(hid, input_dev->report_desc, in mousevsc_hid_parse()
407 input_dev->report_desc_size); in mousevsc_hid_parse()
452 struct mousevsc_dev *input_dev; in mousevsc_probe() local
455 input_dev = mousevsc_alloc_device(device); in mousevsc_probe()
457 if (!input_dev) in mousevsc_probe()
478 if (input_dev->report_desc[14] == 0x25) in mousevsc_probe()
479 input_dev->report_desc[14] = 0x29; in mousevsc_probe()
490 hid_dev->vendor = input_dev->hid_dev_info.vendor; in mousevsc_probe()
491 hid_dev->product = input_dev->hid_dev_info.product; in mousevsc_probe()
492 hid_dev->version = input_dev->hid_dev_info.version; in mousevsc_probe()
493 input_dev->hid_device = hid_dev; in mousevsc_probe()
519 input_dev->connected = true; in mousevsc_probe()
520 input_dev->init_complete = true; in mousevsc_probe()
531 mousevsc_free_device(input_dev); in mousevsc_probe()
539 struct mousevsc_dev *input_dev = hv_get_drvdata(dev); in mousevsc_remove() local
543 hid_hw_stop(input_dev->hid_device); in mousevsc_remove()
544 hid_destroy_device(input_dev->hid_device); in mousevsc_remove()
545 mousevsc_free_device(input_dev); in mousevsc_remove()