mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-05 22:41:44 +00:00
cr50: reenable ap uart on servo disconnect
The ap uart tx signal is disconnected if servo is attached, but it is never reconnected when servo is detached. The 'ccd uart enable' command only reconnects the EC uart tx signal, so if servo is detached the only way to reenable ap uart tx is to detach and reattach suzyq. This can cause cr50 to lose some ccd state. This change reconnects the ap uart when servo is detached. BUG=none BRANCH=none TEST=manual disconnect servo attach suzyq verify the ap console is read write attach servo verify the ap console is read only detach servo verify the ap console is read write Change-Id: I11cdd932b14d968ec77b18adf93dd0d3808fb2e9 Signed-off-by: Mary Ruthven <mruthven@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/439704 Reviewed-by: Scott Collyer <scollyer@chromium.org>
This commit is contained in:
@@ -725,7 +725,12 @@ static void servo_deferred(void)
|
||||
if (servo_state_unknown())
|
||||
return;
|
||||
|
||||
device_powered_off(DEVICE_SERVO);
|
||||
/*
|
||||
* If servo was detached reconnect the AP uart making it read write
|
||||
* again.
|
||||
*/
|
||||
if (device_powered_off(DEVICE_SERVO) == EC_SUCCESS)
|
||||
uartn_tx_connect(UART_AP);
|
||||
}
|
||||
DECLARE_DEFERRED(servo_deferred);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user