input: kbd_matrix: clear unstable state correctly on release
The state variable to tracking the unstable state of a key is currently being cleared based on the bit value, which means that on release it's not being cleared at all. Fix that by clearing using the bit mask instead. Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
This commit is contained in:
parent
71e5c66ea4
commit
f4bf74e402
|
@ -174,7 +174,7 @@ static void input_kbd_matrix_update_state(const struct device *dev)
|
|||
continue;
|
||||
}
|
||||
|
||||
cfg->matrix_unstable_state[c] &= ~row_bit;
|
||||
cfg->matrix_unstable_state[c] &= ~mask;
|
||||
|
||||
/* Check if there was a change in the stable state */
|
||||
if ((cfg->matrix_stable_state[c] & mask) == row_bit) {
|
||||
|
|
Loading…
Reference in a new issue