summaryrefslogtreecommitdiff
path: root/driver/charger
diff options
context:
space:
mode:
authoralvishsu <alvishsu@google.com>2022-10-13 18:09:27 +0800
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-11-11 05:42:20 +0000
commit3f2554177bd70e760a722f8f252a267b4f097ba7 (patch)
tree3a78e364bf80a2b6133bf51031808fdd30c35e20 /driver/charger
parentd81db5fe71e650a998a82a6208f61339cee057ef (diff)
downloadchrome-ec-3f2554177bd70e760a722f8f252a267b4f097ba7.tar.gz
rt9490: disable special TA detection
ChromeOS doesn't support any non-standard TA other than SDP/CDP/DCP, so disable this feature to make behavior consistent. BUG=b:249226376 TEST=zmake BRANCH=corsola Change-Id: I86bffc94f8ef36b5119f471618955ab77ea16bf2 Signed-off-by: Ting Shen <phoenixshen@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3949344 Reviewed-by: Eric Yilun Lin <yllin@google.com> Code-Coverage: Zoss <zoss-cl-coverage@prod.google.com> Commit-Queue: Ting Shen <phoenixshen@chromium.org> Tested-by: Ting Shen <phoenixshen@chromium.org> Code-Coverage: Eric Yilun Lin <yllin@google.com>
Diffstat (limited to 'driver/charger')
-rw-r--r--driver/charger/rt9490.c4
-rw-r--r--driver/charger/rt9490.h3
2 files changed, 7 insertions, 0 deletions
diff --git a/driver/charger/rt9490.c b/driver/charger/rt9490.c
index 8bf418a065..c0bf873e43 100644
--- a/driver/charger/rt9490.c
+++ b/driver/charger/rt9490.c
@@ -359,6 +359,10 @@ static int rt9490_init_setting(int chgnum)
RT9490_EN_FON_PP_BAT_TRACK);
RETURN_ERROR(rt9490_enable_hidden_mode(chgnum, false));
+ /* Disable non-standard TA detection */
+ RETURN_ERROR(rt9490_clr_bit(chgnum, RT9490_REG_ADD_CTRL2,
+ RT9490_SPEC_TA_EN));
+
return EC_SUCCESS;
}
diff --git a/driver/charger/rt9490.h b/driver/charger/rt9490.h
index ea1d6cfcfb..135c3271be 100644
--- a/driver/charger/rt9490.h
+++ b/driver/charger/rt9490.h
@@ -248,6 +248,9 @@ struct rt9490_init_setting {
/* ADD CTRL1 */
#define RT9490_PWM_1MHZ_EN BIT(4)
+/* ADD CTRL2 */
+#define RT9490_SPEC_TA_EN BIT(2)
+
/* HD_ADD_CTRL 2 */
#define RT9490_EN_FON_PP_BAT_TRACK BIT(5)