}
/**
- * eficonfig_select_file() - construct the file selection menu
+ * eficonfig_show_file_selection() - construct the file selection menu
*
* @file_info: pointer to the file selection structure
* @root: pointer to the file handle
* Return: status code
*/
-static efi_status_t eficonfig_select_file(struct eficonfig_select_file_info *file_info,
- struct efi_file_handle *root)
+static efi_status_t eficonfig_show_file_selection(struct eficonfig_select_file_info *file_info,
+ struct efi_file_handle *root)
{
u32 count = 0, i;
efi_uintn_t len;
return EFI_SUCCESS;
}
-/**
- * eficonfig_process_select_file() - callback function for "Select File" entry
- *
- * @data: pointer to the data
- * Return: status code
- */
-efi_status_t eficonfig_process_select_file(void *data)
-{
- return EFI_SUCCESS;
-}
-
/**
* eficonfig_process_clear_file_selection() - callback function for "Clear" entry
*
{"Quit", eficonfig_process_quit},
};
-
/**
- * eficonfig_display_select_file_option() - display select file option
+ * eficonfig_process_show_file_option() - display select file option
*
* @file_info: pointer to the file information structure
* Return: status code
*/
-efi_status_t eficonfig_display_select_file_option(struct eficonfig_select_file_info *file_info)
+efi_status_t eficonfig_process_show_file_option(void *data)
{
efi_status_t ret;
struct efimenu *efi_menu;
- select_file_menu_items[1].data = file_info;
+ select_file_menu_items[0].data = data;
+ select_file_menu_items[1].data = data;
efi_menu = eficonfig_create_fixed_menu(select_file_menu_items,
ARRAY_SIZE(select_file_menu_items));
if (!efi_menu)
}
/**
- * eficonfig_select_file_handler() - handle user file selection
+ * eficonfig_process_select_file() - handle user file selection
*
* @data: pointer to the data
* Return: status code
*/
-efi_status_t eficonfig_select_file_handler(void *data)
+efi_status_t eficonfig_process_select_file(void *data)
{
size_t len;
efi_status_t ret;
struct eficonfig_select_file_info *tmp = NULL;
struct eficonfig_select_file_info *file_info = data;
- ret = eficonfig_display_select_file_option(file_info);
- if (ret != EFI_SUCCESS)
- return ret;
-
tmp = calloc(1, sizeof(struct eficonfig_select_file_info));
if (!tmp)
return EFI_OUT_OF_RESOURCES;
if (ret != EFI_SUCCESS)
goto out;
- ret = eficonfig_select_file(tmp, root);
+ ret = eficonfig_show_file_selection(tmp, root);
if (ret == EFI_ABORTED)
continue;
if (ret != EFI_SUCCESS)
utf8_utf16_strcpy(&p, devname);
u16_strlcat(file_name, file_info->current_path, len);
ret = create_boot_option_entry(efi_menu, title, file_name,
- eficonfig_select_file_handler, file_info);
+ eficonfig_process_show_file_option, file_info);
out:
free(devname);
free(file_name);
void eficonfig_destroy(struct efimenu *efi_menu);
efi_status_t eficonfig_process_quit(void *data);
efi_status_t eficonfig_process_common(struct efimenu *efi_menu, char *menu_header);
-efi_status_t eficonfig_select_file_handler(void *data);
+efi_status_t eficonfig_process_select_file(void *data);
efi_status_t eficonfig_get_unused_bootoption(u16 *buf,
efi_uintn_t buf_size, u32 *index);
efi_status_t eficonfig_append_bootorder(u16 index);