summaryrefslogtreecommitdiff
path: root/firmware/2lib/2misc.c
diff options
context:
space:
mode:
authorYu-Ping Wu <yupingso@chromium.org>2020-03-24 11:54:56 +0800
committerCommit Bot <commit-bot@chromium.org>2020-04-17 15:19:16 +0000
commit785cc5e9a84142fe84d0410e2f56f4aee65fbe65 (patch)
tree442cee07db8c31820ae90a25c689d90a19f331a7 /firmware/2lib/2misc.c
parent297ea05cf12ce31156f8648983431332b50c995c (diff)
downloadvboot-785cc5e9a84142fe84d0410e2f56f4aee65fbe65.tar.gz
vboot: decouple EC/AUXFW sync from UI
Since we don't always want to show a UI on EC sync (for example, in coreboot, where display hasn't been initialized), decouple vb2api_ec_sync() from VbDisplayScreen() by leaving screen display out of vboot and letting the caller (such as depthcharge) handle it. Similarly, stop calling screen display function from vb2api_auxfw_sync(). In order to display screen from depthcharge, it needs to know the locale. Therefore, add vb2api_get_locale() to vboot API, which returns the locale from nvdata. After this change, the constant EC_SLOW_UPDATE is no longer used, so remove it from Makefile. BRANCH=none BUG=chromium:1055125 TEST=make runtests Cq-Depend: chromium:2117776 Change-Id: I0e2e8ebdd26d48a2e94d36495c2e45a5734cdc5d Signed-off-by: Yu-Ping Wu <yupingso@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/2087016 Reviewed-by: Joel Kitching <kitching@chromium.org>
Diffstat (limited to 'firmware/2lib/2misc.c')
-rw-r--r--firmware/2lib/2misc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/firmware/2lib/2misc.c b/firmware/2lib/2misc.c
index 5411ad1e..2df4f2e1 100644
--- a/firmware/2lib/2misc.c
+++ b/firmware/2lib/2misc.c
@@ -453,6 +453,11 @@ uint32_t vb2api_get_recovery_reason(struct vb2_context *ctx)
return vb2_get_sd(ctx)->recovery_reason;
}
+uint32_t vb2api_get_locale_id(struct vb2_context *ctx)
+{
+ return vb2_nv_get(ctx, VB2_NV_LOCALIZATION_INDEX);
+}
+
void vb2api_export_vbsd(struct vb2_context *ctx, void *dest)
{
struct vb2_shared_data *sd = vb2_get_sd(ctx);