Skip to content

Commit

Permalink
[PATCH] Generic HID layer - USB API
Browse files Browse the repository at this point in the history
- 'dev' in struct hid_device changed from struct usb_device to
  struct device and fixed all the users
- renamed functions which are part of USB HID API from 'hid_*' to
  'usbhid_*'
- force feedback initialization moved from common part into USB-specific
  driver
- added usbhid.h header for USB HID API users
- removed USB-specific fields from struct hid_device and moved them
  to new usbhid_device, which is pointed to by hid_device->driver_data
- fixed all USB users to use this new structure

Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Jiri Kosina authored and Greg Kroah-Hartman committed Dec 8, 2006
1 parent 229695e commit 4916b3a
Show file tree
Hide file tree
Showing 10 changed files with 370 additions and 281 deletions.
10 changes: 2 additions & 8 deletions drivers/hid/hid-input.c
Original file line number Diff line number Diff line change
Expand Up @@ -798,8 +798,7 @@ int hidinput_connect(struct hid_device *hid)
input_dev->id.vendor = hid->vendor;
input_dev->id.product = hid->product;
input_dev->id.version = hid->version;
input_dev->cdev.dev = &hid->intf->dev;

input_dev->cdev.dev = hid->dev;
hidinput->input = input_dev;
list_add_tail(&hidinput->list, &hid->inputs);
}
Expand All @@ -821,13 +820,8 @@ int hidinput_connect(struct hid_device *hid)
}
}

/* This only gets called when we are a single-input (most of the
* time). IOW, not a HID_QUIRK_MULTI_INPUT. The hid_ff_init() is
* only useful in this case, and not for multi-input quirks. */
if (hidinput) {
hid_ff_init(hid);
if (hidinput)
input_register_device(hidinput->input);
}

return 0;
}
Expand Down
Loading

0 comments on commit 4916b3a

Please sign in to comment.