ec/google/chromeec: Skip unnecessary call to TCSS `enter_dp_mode` cmd
Skip TCSS `enter_dp_mode` command when there is no USB device detected on the port. BUG=b:247670186 TEST=Verify display over TCSS and its impact on boot time for google/rex Signed-off-by: Kapil Porwal <kapilporwal@google.com> Change-Id: Ie6cd84cab3631596d4d7178dae2040e25c621f63 Reviewed-on: https://review.coreboot.org/c/coreboot/+/76352 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Subrata Banik <subratabanik@google.com>
This commit is contained in:
parent
ba7fee9159
commit
c2c5801dcd
|
@ -1213,9 +1213,16 @@ static int google_chromeec_usb_pd_get_info(int port, bool *ufp, bool *dbg_acc,
|
|||
|
||||
int google_chromeec_typec_control_enter_dp_mode(int port)
|
||||
{
|
||||
int ret;
|
||||
struct usbc_mux_info mux_info;
|
||||
|
||||
if (!google_chromeec_check_feature(EC_FEATURE_TYPEC_REQUIRE_AP_MODE_ENTRY))
|
||||
return 0;
|
||||
|
||||
ret = google_chromeec_get_usbc_mux_info(port, &mux_info);
|
||||
if ((ret < 0) || (!mux_info.usb))
|
||||
return -1;
|
||||
|
||||
const struct ec_params_typec_control typec_control = {
|
||||
.port = port,
|
||||
.command = TYPEC_CONTROL_COMMAND_ENTER_MODE,
|
||||
|
|
Loading…
Reference in New Issue