summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpoornima tom <poornima.tom@intel.com>2022-08-25 00:07:06 +0530
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-09-28 22:42:54 +0000
commitc8c28408a4da48c4d6bb9571ef540e99f20ecc95 (patch)
treea0c90e37f7812cf944c0585fa27fb1df4dc75183
parente14fbc4d38217ca6fd9bca4ef072e8a84a16fd8b (diff)
downloadchrome-ec-c8c28408a4da48c4d6bb9571ef540e99f20ecc95.tar.gz
adlrvp: Set the DRP state as SOURCE in S0
Setting the DRP state as PD_DRP_TOGGLE_OFF in RVP as part of CL:3690048 had an impact for bus powered devices like pendrive to go undectected. As default pd state is sink, self powered devices like TBT/USB4 didnot have any issue in detection. Selecting the default DRP state as SOURCE, would ensure that any device(both source and sink based) connected on typec port would starts as source and gets detected fine. BUG=None BRANCH=None TEST=Verify on bus powered and self powered devices on RVP Verified both hotpluggin and coldboot scenario of both bus powered (pendrive, DP dongle) and self powered devices(TBT, USB4) on all ports. In NDA case, all ports entering low power mode as well. ex: Pendrive on P0: pd 0 state Port C0 CC1, Enable - Role: SRC-DFP-VC TC State: Attached.SRC, Flags: 0x8011 PE State: PE_SRC_Disabled, Flags: 0x1000000 TBT on P1: pd 1 state Port C1 CC1, Enable - Role: SNK-DFP-VC TC State: Attached.SNK, Flags: 0x9001 PE State: PE_SNK_Ready, Flags: 0x0201 NDA: pd 2 state Port C2 CC1, Disable - Role: SRC-UFP TC State: LowPowerMode, Flags: 0x0010 PE State:, Flags: 0x8400000 Signed-off-by: poornima tom <poornima.tom@intel.com> Change-Id: I465ff23377058a35a545015c192f804414c57534 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3855157 Tested-by: Poornima Tom <poornima.tom@intel.corp-partner.google.com> Reviewed-by: Diana Z <dzigterman@chromium.org> Reviewed-by: Vijay P Hiremath <vijay.p.hiremath@intel.com>
-rw-r--r--baseboard/intelrvp/adlrvp.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/baseboard/intelrvp/adlrvp.c b/baseboard/intelrvp/adlrvp.c
index 6f301be986..ed1a848708 100644
--- a/baseboard/intelrvp/adlrvp.c
+++ b/baseboard/intelrvp/adlrvp.c
@@ -568,16 +568,20 @@ __override void board_pre_task_i2c_peripheral_init(void)
/*
* ADL RVP has both ITE and FUSB based TCPC chips. By default, the PD
* state of a non-attached port remains in PD_DRP_TOGGLE_ON in active
- * state. Also, FUSB TCPC chip does not support dual role auto toggle
+ * state. Also, FUSB TCPC chip does not support 'dual role auto toggle'
* which contradicts the default set S0 state of PD_DRP_TOGGLE_ON,
* while ITE based TCPC can support dual role auto toggle. The
* default PD_DRP_TOGGLE_ON state in Active state doesnot allow TCPC
- * ports to enter Low power mode. To fix the issue, added board
- * specific code to disable the dual role toggle in S0.
+ * ports to enter Low power mode. To fix the issue, added board specific
+ * code to remove the default DRP state - PD_DRP_TOGGLE_ON in S0. Also,
+ * eventhough 'dual role auto toggle' is not supported by FUSB, the ports
+ * supports both source and sink. Hence, setting the default DRP state
+ * as PD_DRP_FORCE_SOURCE in S0, would be the ideal board based solution to
+ * support for both source and sink devices for this RVP.
* Note:For ITE based TCPC, low power mode entry does makes no
* difference, as it is controlled by ITE TCPC clk in deep sleepmode.
*/
__override enum pd_dual_role_states pd_get_drp_state_in_s0(void)
{
- return PD_DRP_TOGGLE_OFF;
+ return PD_DRP_FORCE_SOURCE;
}