summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorMatthew Garrett <mjg@redhat.com>2009-12-11 22:00:57 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2009-12-11 23:55:42 -0800
commit967c9ef9b8c3bdec1bd3a380edac19e0b9fbeadc (patch)
tree03a3ba3fec91014adb5afbe78f40ffb429c3753e /include/linux
parent4e8d340daac46cec8a0f8b3b0f228274fac913ba (diff)
downloadop-kernel-dev-967c9ef9b8c3bdec1bd3a380edac19e0b9fbeadc.zip
op-kernel-dev-967c9ef9b8c3bdec1bd3a380edac19e0b9fbeadc.tar.gz
Input: i8042 - allow installing platform filters for incoming data
Some hardware (such as Dell laptops) signal a variety of events through the i8042 controller, even if these don't map to keyboard events. Add support for drivers to filter the i8042 event stream in order to respond to these events and (if appropriate) block them from entering the input stream. Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/i8042.h18
1 files changed, 17 insertions, 1 deletions
diff --git a/include/linux/i8042.h b/include/linux/i8042.h
index 60c3360..9bf6870 100644
--- a/include/linux/i8042.h
+++ b/include/linux/i8042.h
@@ -39,6 +39,10 @@ void i8042_lock_chip(void);
void i8042_unlock_chip(void);
int i8042_command(unsigned char *param, int command);
bool i8042_check_port_owner(const struct serio *);
+int i8042_install_filter(bool (*filter)(unsigned char data, unsigned char str,
+ struct serio *serio));
+int i8042_remove_filter(bool (*filter)(unsigned char data, unsigned char str,
+ struct serio *serio));
#else
@@ -52,7 +56,7 @@ void i8042_unlock_chip(void)
int i8042_command(unsigned char *param, int command)
{
- return -ENOSYS;
+ return -ENODEV;
}
bool i8042_check_port_owner(const struct serio *serio)
@@ -60,6 +64,18 @@ bool i8042_check_port_owner(const struct serio *serio)
return false;
}
+int i8042_install_filter(bool (*filter)(unsigned char data, unsigned char str,
+ struct serio *serio))
+{
+ return -ENODEV;
+}
+
+int i8042_remove_filter(bool (*filter)(unsigned char data, unsigned char str,
+ struct serio *serio))
+{
+ return -ENODEV;
+}
+
#endif
#endif
OpenPOWER on IntegriCloud