/* See the Unified Extensible Firmware Interface (UEFI) specification for details.  */
static efi_status_t EFIAPI efi_cin_read_key_stroke(struct efi_simple_text_input_protocol *this, struct efi_input_key *key)
/* See the Unified Extensible Firmware Interface (UEFI) specification for details.  */
static efi_status_t EFIAPI efi_cin_read_key_stroke(struct efi_simple_text_input_protocol *this, struct efi_input_key *key)
{
	efi_status_t ret = EFI_SUCCESS;
	EFI_ENTRY("%p, %p", this, key);
	if (!this || !key) {
		ret = EFI_INVALID_PARAMETER;
		goto out;
	}
	efi_timer_check();
	efi_cin_check();
	if (!key_available) {
		ret = EFI_NOT_READY;
		goto out;
	}
	*key = next_key.key;
	key_available = false;
	efi_con_in.wait_for_key->is_signaled = false;
out:
	return EFI_EXIT(ret);
}