aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid
diff options
context:
space:
mode:
authorAxel Lin <axel.lin@gmail.com>2012-09-07 03:11:50 -0400
committerJiri Kosina <jkosina@suse.cz>2012-09-07 08:55:38 -0400
commit8b61513b86a221760389237c039105b5a5a332b3 (patch)
tree2cfc7fea3c3946816c4cf20b8c06d723edfad946 /drivers/hid
parent751e5ed350ac3f8dff9fd63ce01405da9472a034 (diff)
HID: primax: Remove px_probe() and px_remove() functions
The px_probe() and px_remove() functions do not have any special initialization and cleanup. Remove them and let HID core handle the default probe/remove actions. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid')
-rw-r--r--drivers/hid/hid-primax.c25
1 files changed, 0 insertions, 25 deletions
diff --git a/drivers/hid/hid-primax.c b/drivers/hid/hid-primax.c
index 4d3c60d88318..c15adb0c98a1 100644
--- a/drivers/hid/hid-primax.c
+++ b/drivers/hid/hid-primax.c
@@ -64,29 +64,6 @@ static int px_raw_event(struct hid_device *hid, struct hid_report *report,
64 return 0; 64 return 0;
65} 65}
66 66
67static int px_probe(struct hid_device *hid, const struct hid_device_id *id)
68{
69 int ret;
70
71 ret = hid_parse(hid);
72 if (ret) {
73 hid_err(hid, "parse failed\n");
74 goto fail;
75 }
76
77 ret = hid_hw_start(hid, HID_CONNECT_DEFAULT);
78 if (ret)
79 hid_err(hid, "hw start failed\n");
80
81fail:
82 return ret;
83}
84
85static void px_remove(struct hid_device *hid)
86{
87 hid_hw_stop(hid);
88}
89
90static const struct hid_device_id px_devices[] = { 67static const struct hid_device_id px_devices[] = {
91 { HID_USB_DEVICE(USB_VENDOR_ID_PRIMAX, USB_DEVICE_ID_PRIMAX_KEYBOARD) }, 68 { HID_USB_DEVICE(USB_VENDOR_ID_PRIMAX, USB_DEVICE_ID_PRIMAX_KEYBOARD) },
92 { } 69 { }
@@ -97,8 +74,6 @@ static struct hid_driver px_driver = {
97 .name = "primax", 74 .name = "primax",
98 .id_table = px_devices, 75 .id_table = px_devices,
99 .raw_event = px_raw_event, 76 .raw_event = px_raw_event,
100 .probe = px_probe,
101 .remove = px_remove,
102}; 77};
103 78
104static int __init px_init(void) 79static int __init px_init(void)