summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2018-10-19 20:42:46 -0600
committerMartin Roth <martinroth@chromium.org>2018-11-14 18:57:27 +0000
commit09df2b1ff13025617b737073ee3db5e5bfc4a6b5 (patch)
tree0791f7ef06634905703310049760824435f836d4
parent0d10f5726bf27fdd74da4e87ebea44276f1c4982 (diff)
downloadvboot-09df2b1ff13025617b737073ee3db5e5bfc4a6b5.tar.gz
Unify the rest of the beeps
In some cases we use a a single high beep to signal an error. It does not seem important to distinguish this from any other kind of error, so just use the existing case. All beeping now goes through vb2_error_beep(), except for one beep in vboot_audio.c. We could move vb2_error_beep() to vboot_audio.c, but the beeps seem to be a part of the UI rather than the audio system. Of course, vb2_audio_looping() arguable is also... BUG=chromium:837018 BRANCH=none TEST=FEATURES=test emerge-grunt --nodeps vboot_reference Change-Id: I55807b4548987a621e8bbced97e7710d6cd6d5fb Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1292247 Reviewed-by: Julius Werner <jwerner@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/1335658 Reviewed-by: Martin Roth <martinroth@chromium.org> Tested-by: Martin Roth <martinroth@chromium.org>
-rw-r--r--firmware/lib/vboot_ui.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/firmware/lib/vboot_ui.c b/firmware/lib/vboot_ui.c
index b7555cd0..9d2c4fd2 100644
--- a/firmware/lib/vboot_ui.c
+++ b/firmware/lib/vboot_ui.c
@@ -162,7 +162,7 @@ int VbUserConfirms(struct vb2_context *ctx, uint32_t confirm_flags)
*/
if (confirm_flags & VB_CONFIRM_MUST_TRUST_KEYBOARD &&
!(key_flags & VB_KEY_FLAG_TRUSTED_KEYBOARD)) {
- VbExBeep(120, 400);
+ vb2_error_beep(VB_BEEP_NOT_ALLOWED);
break;
}
VB2_DEBUG("Yes (1)\n");
@@ -321,7 +321,7 @@ VbError_t vb2_developer_ui(struct vb2_context *ctx)
VbExDisplayDebugInfo(
"WARNING: TONORM prohibited by "
"GBB FORCE_DEV_SWITCH_ON.\n\n");
- VbExBeep(120, 400);
+ vb2_error_beep(VB_BEEP_NOT_ALLOWED);
break;
}
VbDisplayScreen(ctx,
@@ -543,7 +543,7 @@ static VbError_t recovery_ui(struct vb2_context *ctx)
*/
VB2_DEBUG("^D but rec switch "
"is pressed\n");
- VbExBeep(120, 400);
+ vb2_error_beep(VB_BEEP_NOT_ALLOWED);
continue;
}