Skip to content

Commit 058279e

Browse files
Merge pull request #1060 from FrameworkComputer/marigold.modify_fw_update_flow
marigold: modify fw_update mode flow
2 parents a29fb97 + 8eeec2e commit 058279e

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

zephyr/program/framework/src/cypd_ccg6.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,14 @@ void entry_tbt_mode(int controller)
531531
{
532532
int rv;
533533
uint8_t force_tbt_mode = 0x01;
534+
int debug_ctl = 0x0100;
535+
536+
/* Write 0x0100 to address 0x0046 */
537+
rv = cypd_write_reg16(controller, CCG_ICL_BB_RETIMER_CMD_REG, debug_ctl);
538+
if (rv != EC_SUCCESS)
539+
CPRINTS("Write CYP5525_ICL_BB_RETIMER_CMD_REG fail");
534540

541+
/* Write 0x01 to address 0x0040 */
535542
rv = cypd_write_reg8(controller, CCG_ICL_CTRL_REG, force_tbt_mode);
536543
if (rv != EC_SUCCESS)
537544
CPRINTS("Write CYP5525_ICL_CTRL_REG fail");
@@ -541,10 +548,17 @@ void exit_tbt_mode(int controller)
541548
{
542549
int rv;
543550
uint8_t force_tbt_mode = 0x00;
551+
int debug_ctl = 0x0000;
544552

553+
/* Write 0x00 to address 0x0040 */
545554
rv = cypd_write_reg8(controller, CCG_ICL_CTRL_REG, force_tbt_mode);
546555
if (rv != EC_SUCCESS)
547556
CPRINTS("Write CYP5525_ICL_CTRL_REG fail");
557+
558+
/* Write 0x0000 to address 0x0046 */
559+
rv = cypd_write_reg16(controller, CCG_ICL_BB_RETIMER_CMD_REG, debug_ctl);
560+
if (rv != EC_SUCCESS)
561+
CPRINTS("Write CYP5525_ICL_BB_RETIMER_CMD_REG fail");
548562
}
549563

550564
int check_tbt_mode(int controller)

0 commit comments

Comments
 (0)