diff options
author | Ondrej Jirman <[email protected]> | 2021-11-08 11:28:32 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <[email protected]> | 2021-11-17 15:04:16 +0100 |
commit | 362468830dd5bea8bf6ad5203b2ea61f8a4e8288 (patch) | |
tree | 8d447e083b8793f48bd0c50a9666c2418d731d0f /net/lapb/lapb_timer.c | |
parent | 47ce45906ca9870cf5267261f155fb7c70307cf0 (diff) |
usb: typec: fusb302: Fix masking of comparator and bc_lvl interrupts
The code that enables either BC_LVL or COMP_CHNG interrupt in tcpm_set_cc
wrongly assumes that the interrupt is unmasked by writing 1 to the apropriate
bit in the mask register. In fact, interrupts are enabled when the mask
is 0, so the tcpm_set_cc enables interrupt for COMP_CHNG when it expects
BC_LVL interrupt to be enabled.
This causes inability of the driver to recognize cable unplug events
in host mode (unplug is recognized only via a COMP_CHNG interrupt).
In device mode this bug was masked by simultaneous triggering of the VBUS
change interrupt, because of loss of VBUS when the port peer is providing
power.
Fixes: 48242e30532b ("usb: typec: fusb302: Revert "Resolve fixed power role contract setup"")
Cc: stable <[email protected]>
Cc: Hans de Goede <[email protected]>
Reviewed-by: Hans de Goede <[email protected]>
Acked-by: Heikki Krogerus <[email protected]>
Signed-off-by: Ondrej Jirman <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'net/lapb/lapb_timer.c')
0 files changed, 0 insertions, 0 deletions