zinger: do not cut output on up voltage transitions

Update according to the current PD standard, a monotonic transition
seems mandatory in all cases, so keep the voltage output enabled
when increasing the output voltage.

Signed-off-by: Vincent Palatin <vpalatin@chromium.org>

BRANCH=none
BUG=chrome-os-partner:28331
TEST=connect Zinger to Fruitpie and probe the VBUS voltage during a
transition.

Change-Id: I3c728cc0049ca41536efd4f075139626b7d371da
Reviewed-on: https://chromium-review.googlesource.com/202657
Reviewed-by: Alec Berg <alecaberg@chromium.org>
Commit-Queue: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
This commit is contained in:
Vincent Palatin
2014-06-04 11:45:13 -07:00
committed by chrome-internal-fetch
parent 40ca542a0d
commit b170291c36

View File

@@ -148,7 +148,8 @@ int pd_request_voltage(uint32_t rdo)
((pdo >> 10) & 0x3ff) * 50, (pdo & 0x3ff) * 10,
((rdo >> 10) & 0x3ff) * 10, (rdo & 0x3ff) * 10);
output_disable();
if (idx - 1 < volt_idx) /* down voltage transition */
output_disable();
/* TODO discharge ? */
volt_idx = idx - 1;
set_output_voltage(voltages[volt_idx].select);