vboot/vboot_kernel: change recovery behaviour on kernel failure

On load kernel failure, only call vb2api_fail when in normal

Previously, the behaviour here was to only call when attempting
to load a kernel from a fixed disk.  This maps to (1) normal
mode, and (2) developer mode when booting from an internal disk.

Excluding (2) creates a more consistent experience in developer
mode, and also prepares for a world where recovery kernels might
exist on disk.

This CL is part of a series to merge vboot1 and vboot2.0
kernel verification code; see b/181739551.

BUG=b:181739551, b:188121855
TEST=make clean && make runtests

Signed-off-by: Joel Kitching <kitching@google.com>
Change-Id: Ic2c55a073b036be98f4ce9b2e0c7fb3209de74c8
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/2917623
Tested-by: Joel Kitching <kitching@chromium.org>
Commit-Queue: Joel Kitching <kitching@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2 files changed