mirror of
https://github.com/linuxboot/heads.git
synced 2025-01-02 11:16:41 +00:00
Move enable_usb earlier
It is going to be enabled later anyway (if CONFIG_HOTPKEY=y), so it can also be simplified by enabling it at the very beginning. This enables USB keyboard consistently during all boot menus, including the "No Bootable OS Found" prompt. It isn't a big deal for "normal" laptop usage, but it is important for automatic tests and also non-laptop systems.
This commit is contained in:
parent
3b99caa996
commit
13a12d157b
@ -202,7 +202,6 @@ update_hotp()
|
|||||||
{
|
{
|
||||||
if [ -x /bin/hotp_verification ]; then
|
if [ -x /bin/hotp_verification ]; then
|
||||||
HOTP=`unseal-hotp`
|
HOTP=`unseal-hotp`
|
||||||
enable_usb
|
|
||||||
if ! hotp_verification info ; then
|
if ! hotp_verification info ; then
|
||||||
if ! whiptail $BG_COLOR_WARNING --clear \
|
if ! whiptail $BG_COLOR_WARNING --clear \
|
||||||
--title "WARNING: Please Insert Your $HOTPKEY_BRANDING" \
|
--title "WARNING: Please Insert Your $HOTPKEY_BRANDING" \
|
||||||
@ -251,7 +250,6 @@ clean_boot_check()
|
|||||||
|
|
||||||
# check for USB security token
|
# check for USB security token
|
||||||
if [ "$CONFIG_HOTPKEY" = "y" ]; then
|
if [ "$CONFIG_HOTPKEY" = "y" ]; then
|
||||||
enable_usb
|
|
||||||
if ! gpg --card-status > /dev/null ; then
|
if ! gpg --card-status > /dev/null ; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
@ -543,6 +541,10 @@ else
|
|||||||
HOTPKEY_BRANDING="HOTP USB Security Dongle"
|
HOTPKEY_BRANDING="HOTP USB Security Dongle"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$CONFIG_HOTPKEY" = "y" ]; then
|
||||||
|
enable_usb
|
||||||
|
fi
|
||||||
|
|
||||||
if detect_boot_device ; then
|
if detect_boot_device ; then
|
||||||
# /boot device with installed OS found
|
# /boot device with installed OS found
|
||||||
clean_boot_check
|
clean_boot_check
|
||||||
|
Loading…
Reference in New Issue
Block a user