platform/chrome: cros_ec_typec: Decouple partner removal
authorPrashant Malani <pmalani@chromium.org>
Tue, 2 Feb 2021 22:40:01 +0000 (14:40 -0800)
committerBenson Leung <bleung@chromium.org>
Tue, 2 Feb 2021 23:00:45 +0000 (15:00 -0800)
commitd9f12f9e6c3695c32e681e9d266c4dc1c9016f66
tree0a51047f651c8cd93f32cb243b719058a1e81a02
parent4daeb395f1754340927d8d58269593e4e3b6afcd
platform/chrome: cros_ec_typec: Decouple partner removal

Currently, we return if there is no partner present when
!PD_CTRL_RESP_ENABLED_CONNECTED, without proceeding further. This ties
partner removal to cable removal, whereas the two should be independent.

Update the check to remove a partner if one was registered, but continue
after that instead of returning.

Signed-off-by: Prashant Malani <pmalani@chromium.org>
Link: https://lore.kernel.org/r/20210202224001.3810274-1-pmalani@chromium.org
Signed-off-by: Benson Leung <bleung@chromium.org>
drivers/platform/chrome/cros_ec_typec.c