Lines Matching defs:hdev

33 	struct hid_device *hdev;
59 static __u8 *ms_report_fixup(struct hid_device *hdev, __u8 *rdesc,
62 struct ms_data *ms = hid_get_drvdata(hdev);
71 hid_info(hdev, "fixing up Microsoft Wireless Receiver Model 1028 report descriptor\n");
182 static int ms_input_mapping(struct hid_device *hdev, struct hid_input *hi,
186 struct ms_data *ms = hid_get_drvdata(hdev);
209 static int ms_input_mapped(struct hid_device *hdev, struct hid_input *hi,
213 struct ms_data *ms = hid_get_drvdata(hdev);
222 static int ms_event(struct hid_device *hdev, struct hid_field *field,
225 struct ms_data *ms = hid_get_drvdata(hdev);
229 if (!(hdev->claimed & HID_CLAIMED_INPUT) || !field->hidinput ||
284 struct hid_device *hdev = ms->hdev;
302 ret = hid_hw_output_report(hdev, (__u8 *)r, sizeof(*r));
304 hid_warn(hdev, "failed to send FF report\n");
326 static int ms_init_ff(struct hid_device *hdev)
330 struct ms_data *ms = hid_get_drvdata(hdev);
332 if (list_empty(&hdev->inputs)) {
333 hid_err(hdev, "no inputs found\n");
336 hidinput = list_entry(hdev->inputs.next, struct hid_input, list);
342 ms->hdev = hdev;
345 ms->output_report_dmabuf = devm_kzalloc(&hdev->dev,
355 static void ms_remove_ff(struct hid_device *hdev)
357 struct ms_data *ms = hid_get_drvdata(hdev);
365 static int ms_probe(struct hid_device *hdev, const struct hid_device_id *id)
371 ms = devm_kzalloc(&hdev->dev, sizeof(*ms), GFP_KERNEL);
377 hid_set_drvdata(hdev, ms);
380 hdev->quirks |= HID_QUIRK_NOGET;
383 hdev->quirks |= HID_QUIRK_INPUT_PER_APP;
385 ret = hid_parse(hdev);
387 hid_err(hdev, "parse failed\n");
391 ret = hid_hw_start(hdev, HID_CONNECT_DEFAULT | ((quirks & MS_HIDINPUT) ?
394 hid_err(hdev, "hw start failed\n");
398 ret = ms_init_ff(hdev);
400 hid_err(hdev, "could not initialize ff, continuing anyway");
407 static void ms_remove(struct hid_device *hdev)
409 hid_hw_stop(hdev);
410 ms_remove_ff(hdev);