Some power delivery source send the source capability by 2 stages:
1st stage send the source capability message with only basic 5V
PDO, after the 5V power session setup, 2nd stage it will send full
source capabilities with all PDOs it can support, in this case, we
should go on to process the following PD source cap to have a new
power session setup.
Signed-off-by: Li Jun <jun.li@nxp.com>
switch (pd_state) {
case WAIT_SOURCE_CAP:
+ case SINK_READY:
if (msgtype != PD_DATA_SOURCE_CAP)
continue;
continue;
if (msgtype == PD_CTRL_PS_RDY) {
- tcpc_log(port, "PD source ready! \n");
- pd_state = SINK_READY;
- return;
+ tcpc_log(port, "PD source ready!\n");
+ pd_state = SINK_READY;
}
break;