From: David Herrmann <dh.herrmann@gmail.com>
To: linux-input@vger.kernel.org
Cc: Jiri Kosina <jkosina@suse.cz>,
Benjamin Tissoires <benjamin.tissoires@gmail.com>,
Henrik Rydberg <rydberg@euromail.se>,
Oliver Neukum <oliver@neukum.org>,
David Herrmann <dh.herrmann@gmail.com>
Subject: [RFC 5/8] HID: i2c: use generic hidinput_input_event()
Date: Mon, 15 Jul 2013 19:10:14 +0200 [thread overview]
Message-ID: <1373908217-16748-6-git-send-email-dh.herrmann@gmail.com> (raw)
In-Reply-To: <1373908217-16748-1-git-send-email-dh.herrmann@gmail.com>
HID core provides the same functionality, so drop the custom handler.
Besides, the current handler doesn't schedule any outgoing report so it
did not work, anyway.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
---
drivers/hid/i2c-hid/i2c-hid.c | 24 ------------------------
1 file changed, 24 deletions(-)
diff --git a/drivers/hid/i2c-hid/i2c-hid.c b/drivers/hid/i2c-hid/i2c-hid.c
index 879b0ed..db2253b 100644
--- a/drivers/hid/i2c-hid/i2c-hid.c
+++ b/drivers/hid/i2c-hid/i2c-hid.c
@@ -756,29 +756,6 @@ static int i2c_hid_power(struct hid_device *hid, int lvl)
return ret;
}
-static int i2c_hid_hidinput_input_event(struct input_dev *dev,
- unsigned int type, unsigned int code, int value)
-{
- struct hid_device *hid = input_get_drvdata(dev);
- struct hid_field *field;
- int offset;
-
- if (type == EV_FF)
- return input_ff_event(dev, type, code, value);
-
- if (type != EV_LED)
- return -1;
-
- offset = hidinput_find_field(hid, type, code, &field);
-
- if (offset == -1) {
- hid_warn(dev, "event field not found\n");
- return -1;
- }
-
- return hid_set_field(field, offset, value);
-}
-
static struct hid_ll_driver i2c_hid_ll_driver = {
.parse = i2c_hid_parse,
.start = i2c_hid_start,
@@ -787,7 +764,6 @@ static struct hid_ll_driver i2c_hid_ll_driver = {
.close = i2c_hid_close,
.power = i2c_hid_power,
.request = i2c_hid_request,
- .hidinput_input_event = i2c_hid_hidinput_input_event,
};
static int i2c_hid_init_irq(struct i2c_client *client)
--
1.8.3.2
next prev parent reply other threads:[~2013-07-15 17:10 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-15 17:10 [RFC 0/8] HID: Transport Driver Cleanup David Herrmann
2013-07-15 17:10 ` [RFC 1/8] HID: usbhid: make usbhid_set_leds() static David Herrmann
2013-07-16 7:41 ` Benjamin Tissoires
2013-07-15 17:10 ` [RFC 2/8] HID: usbhid: update LED fields unlocked David Herrmann
2013-07-16 7:46 ` Benjamin Tissoires
2013-07-31 8:28 ` Jiri Kosina
2013-07-15 17:10 ` [RFC 3/8] HID: input: generic hidinput_input_event handler David Herrmann
2013-07-16 8:04 ` Benjamin Tissoires
2013-07-17 13:58 ` David Herrmann
2013-07-31 8:30 ` Jiri Kosina
2013-07-15 17:10 ` [RFC 4/8] HID: usbhid: use generic hidinput_input_event() David Herrmann
2013-07-16 8:06 ` Benjamin Tissoires
2013-07-15 17:10 ` David Herrmann [this message]
2013-07-16 8:08 ` [RFC 5/8] HID: i2c: " Benjamin Tissoires
2013-07-15 17:10 ` [RFC 6/8] HID: uhid: " David Herrmann
2013-07-16 8:10 ` Benjamin Tissoires
2013-07-18 19:53 ` rydberg
2013-07-18 20:49 ` David Herrmann
2013-07-15 17:10 ` [RFC 7/8] HID: add transport driver documentation David Herrmann
2013-07-16 10:32 ` Benjamin Tissoires
2013-07-17 15:05 ` David Herrmann
2013-07-18 8:16 ` Benjamin Tissoires
2013-07-15 17:10 ` [RFC 8/8] HID: implement new transport-driver callbacks David Herrmann
2013-07-15 18:55 ` [RFC 0/8] HID: Transport Driver Cleanup Benjamin Tissoires
2013-07-31 8:38 ` Jiri Kosina
2013-07-31 8:57 ` David Herrmann
2013-07-31 9:03 ` Jiri Kosina
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1373908217-16748-6-git-send-email-dh.herrmann@gmail.com \
--to=dh.herrmann@gmail.com \
--cc=benjamin.tissoires@gmail.com \
--cc=jkosina@suse.cz \
--cc=linux-input@vger.kernel.org \
--cc=oliver@neukum.org \
--cc=rydberg@euromail.se \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).