diff options
author | Judy Hsiao <judyhsiao@google.com> | 2022-08-12 02:06:44 +0000 |
---|---|---|
committer | Judy Hsiao <judyhsiao@google.com> | 2022-08-12 02:10:53 +0000 |
commit | caf0666a392c3601ec79e324d52187e17abbae61 (patch) | |
tree | 3160ba00fb2574cb4a584b5da95c782200a542e1 /common | |
parent | c1f5a5481f1121e2f408055f04906205b779dc91 (diff) | |
download | chrome-ec-caf0666a392c3601ec79e324d52187e17abbae61.tar.gz |
Revert "apro: add new return codes"stabilize-15054.98.B-cr50_stabstabilize-15054.26.B-cr50_stabstabilize-15054.115.B-cr50_stabrelease-R106-15054.B-cr50_stab
This reverts commit c1f5a5481f1121e2f408055f04906205b779dc91.
Reason for revert: b:242249503
```
gsctool.c:2382:2: error: duplicate case value
2382 | case AP_RO_UNSUPPORTED_NOT_TRIGGERED:
| ^~~~
gsctool.c:2373:2: note: previously used here
2373 | case AP_RO_UNSUPPORTED_NOT_TRIGGERED:
| ^~~~
```
Original change's description:
> apro: add new return codes
>
> Add new ap_ro_integrity_check return codes. The existing AP_RO_PASS (2)
> return code doesn't verify the GBB. Rename it to
> AP_RO_PASS_UNVERIFIED_GBB. Shimless RMA should only treat
> AP_RO_PASS (7) as a pass. Nothing returns this right now.
> This CL also adds AP_RO_FAIL_CLEARED(8) and AP_RO_IN_PROGRESS(9).
> AP_RO_IN_PROGRESS is used if AP RO verification is ongoing.
> AP_RO_FAIL_CLEARED will be used in a followup CL.
>
> old:
> 2 - AP_RO_PASS
>
> new:
> 2 - AP_RO_PASS_UNVERIFIED_GBB
> ...
> 7 - AP_RO_PASS
> 8 - AP_RO_FAIL_CLEARED
> 9 - AP_RO_IN_PROGRESS
>
> This saves 8 bytes since it also shortens a print message. The remaining
> space changes from 5804 to 5812 bytes.
>
> BUG=b:234497234
> TEST=make buildall -j
>
> Change-Id: I8d19a411c2534236c9defa82291872420c19a15b
> Signed-off-by: Mary Ruthven <mruthven@chromium.org>
> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3805819
> Reviewed-by: Andrey Pronin <apronin@chromium.org>
> Commit-Queue: Andrey Pronin <apronin@chromium.org>
Bug=b:234497234, b:242249503
Change-Id: I63ebc6a1343410e3b2a5ab0684a8a533553ec1ec
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3826713
Reviewed-by: Andrey Pronin <apronin@chromium.org>
Auto-Submit: Judy Hsiao <judyhsiao@google.com>
Tested-by: Judy Hsiao <judyhsiao@google.com>
Owners-Override: Judy Hsiao <judyhsiao@google.com>
Reviewed-by: Mary Ruthven <mruthven@chromium.org>
Commit-Queue: Andrey Pronin <apronin@chromium.org>
Commit-Queue: Mary Ruthven <mruthven@chromium.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/ap_ro_integrity_check.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/common/ap_ro_integrity_check.c b/common/ap_ro_integrity_check.c index 986fa8676f..8c12e851a4 100644 --- a/common/ap_ro_integrity_check.c +++ b/common/ap_ro_integrity_check.c @@ -497,8 +497,7 @@ static int verify_keyblock(const struct kb_container *kbc, /* Clear validate_ap_ro_boot state. */ void ap_ro_device_reset(void) { - if (apro_result == AP_RO_NOT_RUN || apro_result == AP_RO_IN_PROGRESS || - ec_rst_override()) + if (apro_result == AP_RO_NOT_RUN || ec_rst_override()) return; CPRINTS("%s: clear apro result", __func__); apro_result = AP_RO_NOT_RUN; @@ -1399,7 +1398,6 @@ static void keep_ec_in_reset(void) hook_call_deferred(&keep_ec_in_reset_data, 100 * MSEC); } - static void release_ec_reset_override(void) { hook_call_deferred(&keep_ec_in_reset_data, -1); @@ -1421,7 +1419,6 @@ static uint8_t do_ap_ro_check(void) enum ap_ro_check_vc_errors support_status; bool v1_record_found; - apro_result = AP_RO_IN_PROGRESS; support_status = ap_ro_check_unsupported(true); if ((support_status == ARCVE_BOARD_ID_BLOCKED) || (support_status == ARCVE_FLASH_READ_FAILED)) { @@ -1486,9 +1483,9 @@ static uint8_t do_ap_ro_check(void) return EC_ERROR_UNIMPLEMENTED; } - apro_result = AP_RO_PASS_UNVERIFIED_GBB; + apro_result = AP_RO_PASS; ap_ro_add_flash_event(APROF_CHECK_SUCCEEDED); - CPRINTS("AP RO PASS!"); + CPRINTS("AP RO verification SUCCEEDED!"); release_ec_reset_override(); return EC_SUCCESS; |