Skip to content

Commit 5c76c79

Browse files
Dan Carpenterdianders
authored andcommitted
HID: i2c-hid: Fix test in i2c_hid_core_register_panel_follower()
Bitwise AND was intended instead of OR. With the current code the condition is always true. Fixes: cbdd16b ("HID: i2c-hid: Make elan touch controllers power on after panel is enabled") Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Pin-yen Lin <treapking@chromium.org> Acked-by: Jiri Kosina <jkosina@suse.com> Signed-off-by: Douglas Anderson <dianders@chromium.org> Link: https://lore.kernel.org/r/aK8Au3CgZSTvfEJ6@stanley.mountain
1 parent 1e00a12 commit 5c76c79

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/hid/i2c-hid/i2c-hid-core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1189,7 +1189,7 @@ static int i2c_hid_core_register_panel_follower(struct i2c_hid *ihid)
11891189
struct device *dev = &ihid->client->dev;
11901190
int ret;
11911191

1192-
if (ihid->hid->initial_quirks | HID_QUIRK_POWER_ON_AFTER_BACKLIGHT)
1192+
if (ihid->hid->initial_quirks & HID_QUIRK_POWER_ON_AFTER_BACKLIGHT)
11931193
ihid->panel_follower.funcs = &i2c_hid_core_panel_follower_enable_funcs;
11941194
else
11951195
ihid->panel_follower.funcs = &i2c_hid_core_panel_follower_prepare_funcs;

0 commit comments

Comments
 (0)