summaryrefslogtreecommitdiff
path: root/lib/efi_loader/efi_console.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-05-19 16:46:24 -0400
committerTom Rini <trini@konsulko.com>2019-05-19 16:46:24 -0400
commitab487c8568fe35e97943d121e9b9192884cc0d1d (patch)
tree2615e6d8b29b7dae50854381509a049e6d2c2ced /lib/efi_loader/efi_console.c
parente14d9ca4919e5bc987fc628135104f2b2c91af90 (diff)
parentb31ca6bf8484ca10bab4ae544698294a4197bef9 (diff)
Merge tag 'efi-2019-07-rc3-2' of git://git.denx.de/u-boot-efi
Pull request for UEFI sub-system for v2019.07-rc3 (2) Minor patches to improve UEFI specification compliance are provided. To allow running the UEFI self compliance tests an outdated version of the Unicode collation protocol has been added as a configuration option (disabled by default).
Diffstat (limited to 'lib/efi_loader/efi_console.c')
-rw-r--r--lib/efi_loader/efi_console.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/efi_loader/efi_console.c b/lib/efi_loader/efi_console.c
index 051fc1d339..b2cb18e6d6 100644
--- a/lib/efi_loader/efi_console.c
+++ b/lib/efi_loader/efi_console.c
@@ -136,6 +136,11 @@ static efi_status_t EFIAPI efi_cout_output_string(
EFI_ENTRY("%p, %p", this, string);
+ if (!this || !string) {
+ ret = EFI_INVALID_PARAMETER;
+ goto out;
+ }
+
buf = malloc(utf16_utf8_strlen(string) + 1);
if (!buf) {
ret = EFI_OUT_OF_RESOURCES;
@@ -825,7 +830,7 @@ out:
* efi_cin_set_state() - set toggle key state
*
* @this: instance of the EFI_SIMPLE_TEXT_INPUT_PROTOCOL
- * @key_toggle_state: key toggle state
+ * @key_toggle_state: pointer to key toggle state
* Return: status code
*
* This function implements the SetState service of the
@@ -836,9 +841,9 @@ out:
*/
static efi_status_t EFIAPI efi_cin_set_state(
struct efi_simple_text_input_ex_protocol *this,
- u8 key_toggle_state)
+ u8 *key_toggle_state)
{
- EFI_ENTRY("%p, %u", this, key_toggle_state);
+ EFI_ENTRY("%p, %p", this, key_toggle_state);
/*
* U-Boot supports multiple console input sources like serial and
* net console for which a key toggle state cannot be set at all.