Commit 98280374 authored by Giedrius Statkevičius's avatar Giedrius Statkevičius Committed by Darren Hart

drivers: platform: change 0x20 to I8042_STR_AUXDATA in i8042 filters

Instead of using a magic constant 0x20 in some drivers to get data only
from the KBC port we should use the constant defined in i8042.h with
the same value. Also, this makes these drivers uniform with what
constant the only other filter function uses in
drivers/input/misc/ideapad_slidebar.c.
Signed-off-by: default avatarGiedrius Statkevičius <giedriuswork@gmail.com>
Signed-off-by: default avatarDarren Hart <dvhart@linux.intel.com>
parent fc14f9c1
...@@ -564,7 +564,7 @@ static bool dell_laptop_i8042_filter(unsigned char data, unsigned char str, ...@@ -564,7 +564,7 @@ static bool dell_laptop_i8042_filter(unsigned char data, unsigned char str,
{ {
static bool extended; static bool extended;
if (str & 0x20) if (str & I8042_STR_AUXDATA)
return false; return false;
if (unlikely(data == 0xe0)) { if (unlikely(data == 0xe0)) {
......
...@@ -821,7 +821,7 @@ static bool msi_laptop_i8042_filter(unsigned char data, unsigned char str, ...@@ -821,7 +821,7 @@ static bool msi_laptop_i8042_filter(unsigned char data, unsigned char str,
{ {
static bool extended; static bool extended;
if (str & 0x20) if (str & I8042_STR_AUXDATA)
return false; return false;
/* 0x54 wwan, 0x62 bluetooth, 0x76 wlan, 0xE4 touchpad toggle*/ /* 0x54 wwan, 0x62 bluetooth, 0x76 wlan, 0xE4 touchpad toggle*/
......
...@@ -1589,7 +1589,7 @@ static umode_t toshiba_sysfs_is_visible(struct kobject *kobj, ...@@ -1589,7 +1589,7 @@ static umode_t toshiba_sysfs_is_visible(struct kobject *kobj,
static bool toshiba_acpi_i8042_filter(unsigned char data, unsigned char str, static bool toshiba_acpi_i8042_filter(unsigned char data, unsigned char str,
struct serio *port) struct serio *port)
{ {
if (str & 0x20) if (str & I8042_STR_AUXDATA)
return false; return false;
if (unlikely(data == 0xe0)) if (unlikely(data == 0xe0))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment