loader.efi: efi_readkey_ex needs to key despite the shift status or toggle status
From UEFI specification 2.8, page 434: "It should also be noted that certain input devices may not be able to produce shift or toggle state information, and in those cases the high order bit in the respective Toggle and Shift state fields should not be active." But we still need to check for ScanCode and UnicodeChar. PR: 242660 Reported by: Trond Endrestol MFC after: 1 week
This commit is contained in:
parent
359e4dba07
commit
ade8a0f1d1
@ -1126,11 +1126,15 @@ efi_readkey_ex(void)
|
||||
kp->UnicodeChar++;
|
||||
}
|
||||
}
|
||||
if (kp->ScanCode == 0 && kp->UnicodeChar == 0)
|
||||
return (false);
|
||||
keybuf_inschar(kp);
|
||||
return (true);
|
||||
}
|
||||
/*
|
||||
* The shift state and/or toggle state may not be valid,
|
||||
* but we still can have ScanCode or UnicodeChar.
|
||||
*/
|
||||
if (kp->ScanCode == 0 && kp->UnicodeChar == 0)
|
||||
return (false);
|
||||
keybuf_inschar(kp);
|
||||
return (true);
|
||||
}
|
||||
return (false);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user