NORMAL (0x0) and IDLE (0x4) are really two different states. Hence you
cannot check for both using a bitmask, as that checks for IDLE only,
breaking operation for devices that are in NORMAL state.
Fix the wait function to report either state as ready.
Fixes: 6524d8eac258452e ("Input: st1232 - add IDLE state as ready condition")
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
drivers/input/touchscreen/st1232.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
From: Michael Tretter <m.tretter@pengutronix.de> Date: 2021-02-23 10:30:17
On Tue, 23 Feb 2021 10:02:01 +0100, Geert Uytterhoeven wrote:
NORMAL (0x0) and IDLE (0x4) are really two different states. Hence you
cannot check for both using a bitmask, as that checks for IDLE only,
breaking operation for devices that are in NORMAL state.
Thanks. I missed that the state is actually a value and not a bitfield.
Fix the wait function to report either state as ready.
Fixes: 6524d8eac258452e ("Input: st1232 - add IDLE state as ready condition")
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Michael Tretter <m.tretter@pengutronix.de>
On Tue, Feb 23, 2021 at 11:29:00AM +0100, Michael Tretter wrote:
On Tue, 23 Feb 2021 10:02:01 +0100, Geert Uytterhoeven wrote:
quoted
NORMAL (0x0) and IDLE (0x4) are really two different states. Hence you
cannot check for both using a bitmask, as that checks for IDLE only,
breaking operation for devices that are in NORMAL state.
Thanks. I missed that the state is actually a value and not a bitfield.
quoted
Fix the wait function to report either state as ready.
Fixes: 6524d8eac258452e ("Input: st1232 - add IDLE state as ready condition")
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Michael Tretter <m.tretter@pengutronix.de>