mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-21 14:41:31 +00:00
efi_loader: remove deprecated ConsoleControlProtocol
The console control protocol is not defined in the UEFI standard. It exists in EDK2's EdkCompatiblityPkg package. But this package is deprecated according to https://github.com/tianocore/tianocore.github.io/wiki/Differences-between-EDK-and-EDK-II Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
This commit is contained in:
parent
28a4fd46e7
commit
8396e3fd63
3 changed files with 0 additions and 69 deletions
|
@ -571,24 +571,6 @@ struct efi_simple_input_interface {
|
||||||
struct efi_event *wait_for_key;
|
struct efi_event *wait_for_key;
|
||||||
};
|
};
|
||||||
|
|
||||||
#define CONSOLE_CONTROL_GUID \
|
|
||||||
EFI_GUID(0xf42f7782, 0x12e, 0x4c12, \
|
|
||||||
0x99, 0x56, 0x49, 0xf9, 0x43, 0x4, 0xf7, 0x21)
|
|
||||||
#define EFI_CONSOLE_MODE_TEXT 0
|
|
||||||
#define EFI_CONSOLE_MODE_GFX 1
|
|
||||||
|
|
||||||
struct efi_console_control_protocol
|
|
||||||
{
|
|
||||||
efi_status_t (EFIAPI *get_mode)(
|
|
||||||
struct efi_console_control_protocol *this, int *mode,
|
|
||||||
char *uga_exists, char *std_in_locked);
|
|
||||||
efi_status_t (EFIAPI *set_mode)(
|
|
||||||
struct efi_console_control_protocol *this, int mode);
|
|
||||||
efi_status_t (EFIAPI *lock_std_in)(
|
|
||||||
struct efi_console_control_protocol *this,
|
|
||||||
uint16_t *password);
|
|
||||||
};
|
|
||||||
|
|
||||||
#define EFI_DEVICE_PATH_TO_TEXT_PROTOCOL_GUID \
|
#define EFI_DEVICE_PATH_TO_TEXT_PROTOCOL_GUID \
|
||||||
EFI_GUID(0x8b843e20, 0x8132, 0x4852, \
|
EFI_GUID(0x8b843e20, 0x8132, 0x4852, \
|
||||||
0x90, 0xcc, 0x55, 0x1a, 0x4e, 0x4a, 0x7f, 0x1c)
|
0x90, 0xcc, 0x55, 0x1a, 0x4e, 0x4a, 0x7f, 0x1c)
|
||||||
|
|
|
@ -1420,11 +1420,6 @@ efi_status_t efi_setup_loaded_image(
|
||||||
if (ret != EFI_SUCCESS)
|
if (ret != EFI_SUCCESS)
|
||||||
goto failure;
|
goto failure;
|
||||||
|
|
||||||
ret = efi_add_protocol(obj->handle, &efi_guid_console_control,
|
|
||||||
(void *)&efi_console_control);
|
|
||||||
if (ret != EFI_SUCCESS)
|
|
||||||
goto failure;
|
|
||||||
|
|
||||||
ret = efi_add_protocol(obj->handle,
|
ret = efi_add_protocol(obj->handle,
|
||||||
&efi_guid_device_path_to_text_protocol,
|
&efi_guid_device_path_to_text_protocol,
|
||||||
(void *)&efi_device_path_to_text);
|
(void *)&efi_device_path_to_text);
|
||||||
|
|
|
@ -45,7 +45,6 @@ static struct cout_mode efi_cout_modes[] = {
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const efi_guid_t efi_guid_console_control = CONSOLE_CONTROL_GUID;
|
|
||||||
const efi_guid_t efi_guid_text_output_protocol =
|
const efi_guid_t efi_guid_text_output_protocol =
|
||||||
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL_GUID;
|
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL_GUID;
|
||||||
const efi_guid_t efi_guid_text_input_protocol =
|
const efi_guid_t efi_guid_text_input_protocol =
|
||||||
|
@ -54,43 +53,6 @@ const efi_guid_t efi_guid_text_input_protocol =
|
||||||
#define cESC '\x1b'
|
#define cESC '\x1b'
|
||||||
#define ESC "\x1b"
|
#define ESC "\x1b"
|
||||||
|
|
||||||
static efi_status_t EFIAPI efi_cin_get_mode(
|
|
||||||
struct efi_console_control_protocol *this,
|
|
||||||
int *mode, char *uga_exists, char *std_in_locked)
|
|
||||||
{
|
|
||||||
EFI_ENTRY("%p, %p, %p, %p", this, mode, uga_exists, std_in_locked);
|
|
||||||
|
|
||||||
if (mode)
|
|
||||||
*mode = EFI_CONSOLE_MODE_TEXT;
|
|
||||||
if (uga_exists)
|
|
||||||
*uga_exists = 0;
|
|
||||||
if (std_in_locked)
|
|
||||||
*std_in_locked = 0;
|
|
||||||
|
|
||||||
return EFI_EXIT(EFI_SUCCESS);
|
|
||||||
}
|
|
||||||
|
|
||||||
static efi_status_t EFIAPI efi_cin_set_mode(
|
|
||||||
struct efi_console_control_protocol *this, int mode)
|
|
||||||
{
|
|
||||||
EFI_ENTRY("%p, %d", this, mode);
|
|
||||||
return EFI_EXIT(EFI_UNSUPPORTED);
|
|
||||||
}
|
|
||||||
|
|
||||||
static efi_status_t EFIAPI efi_cin_lock_std_in(
|
|
||||||
struct efi_console_control_protocol *this,
|
|
||||||
uint16_t *password)
|
|
||||||
{
|
|
||||||
EFI_ENTRY("%p, %p", this, password);
|
|
||||||
return EFI_EXIT(EFI_UNSUPPORTED);
|
|
||||||
}
|
|
||||||
|
|
||||||
struct efi_console_control_protocol efi_console_control = {
|
|
||||||
.get_mode = efi_cin_get_mode,
|
|
||||||
.set_mode = efi_cin_set_mode,
|
|
||||||
.lock_std_in = efi_cin_lock_std_in,
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Default to mode 0 */
|
/* Default to mode 0 */
|
||||||
static struct simple_text_output_mode efi_con_mode = {
|
static struct simple_text_output_mode efi_con_mode = {
|
||||||
.max_mode = 1,
|
.max_mode = 1,
|
||||||
|
@ -506,18 +468,10 @@ static void EFIAPI efi_console_timer_notify(struct efi_event *event,
|
||||||
int efi_console_register(void)
|
int efi_console_register(void)
|
||||||
{
|
{
|
||||||
efi_status_t r;
|
efi_status_t r;
|
||||||
struct efi_object *efi_console_control_obj;
|
|
||||||
struct efi_object *efi_console_output_obj;
|
struct efi_object *efi_console_output_obj;
|
||||||
struct efi_object *efi_console_input_obj;
|
struct efi_object *efi_console_input_obj;
|
||||||
|
|
||||||
/* Create handles */
|
/* Create handles */
|
||||||
r = efi_create_handle((efi_handle_t *)&efi_console_control_obj);
|
|
||||||
if (r != EFI_SUCCESS)
|
|
||||||
goto out_of_memory;
|
|
||||||
r = efi_add_protocol(efi_console_control_obj->handle,
|
|
||||||
&efi_guid_console_control, &efi_console_control);
|
|
||||||
if (r != EFI_SUCCESS)
|
|
||||||
goto out_of_memory;
|
|
||||||
r = efi_create_handle((efi_handle_t *)&efi_console_output_obj);
|
r = efi_create_handle((efi_handle_t *)&efi_console_output_obj);
|
||||||
if (r != EFI_SUCCESS)
|
if (r != EFI_SUCCESS)
|
||||||
goto out_of_memory;
|
goto out_of_memory;
|
||||||
|
|
Loading…
Add table
Reference in a new issue