summaryrefslogtreecommitdiff
path: root/board/cr50/board.h
diff options
context:
space:
mode:
authorMary Ruthven <mruthven@google.com>2018-04-02 14:36:11 -0700
committerchrome-bot <chrome-bot@chromium.org>2018-04-13 21:37:47 -0700
commitcfcac78e626ce08ccc1c45c91c61127b6088e80f (patch)
tree3f1bff4c9cfa291c3b149d98e4a4de671e88d6ca /board/cr50/board.h
parentcdc9d417612275cdcc3b62f47c0a2cc6155b8c41 (diff)
downloadchrome-ec-cfcac78e626ce08ccc1c45c91c61127b6088e80f.tar.gz
cr50: add support for enabling terminations on ap suspend
rk3399 systems need terminations on the SPI signals in S3 and all other low power states. Add support for enabling the pulldowns and pullups on the correct pins. With this change, if BOARD_NEEDS_S3_TERM is set in the board properties, cr50 will enable a pulldown on the AP TX Cr50 RX signal and a pulldown on all of the SPS signals. To keep the pulldowns from interfering with the sps peripheral, s3_term will also disable the input for those signals. BUG=b:62200096 BRANCH=cr50 TEST=Flash onto bob. Make sure cr50 enables and disables terminations when the AP suspends/resumes. Flash onto reef. Make sure it doesn't do anything. Change-Id: I4adaf6d66160bab1eb3cf3d343d4a79524ccf883 Signed-off-by: Mary Ruthven <mruthven@google.com> Reviewed-on: https://chromium-review.googlesource.com/991338 Commit-Ready: Mary Ruthven <mruthven@chromium.org> Tested-by: Mary Ruthven <mruthven@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'board/cr50/board.h')
-rw-r--r--board/cr50/board.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/board/cr50/board.h b/board/cr50/board.h
index c87cd3e651..75f25cc533 100644
--- a/board/cr50/board.h
+++ b/board/cr50/board.h
@@ -262,6 +262,9 @@ int board_tpm_uses_spi(void);
int board_id_is_mismatched(void);
/* Allow for deep sleep to be enabled on AP shutdown */
int board_deep_sleep_allowed(void);
+int board_needs_s3_term(void);
+int board_s3_term_is_enabled(void);
+void board_s3_term(int enable);
void power_button_record(void);
@@ -282,6 +285,7 @@ void print_servo_state(void);
int ap_is_on(void);
int ap_uart_is_on(void);
+int ap_is_suspended(void);
int ec_is_on(void);
int ec_is_rx_allowed(void);
int servo_is_connected(void);