Revert "gop: Allow user to select which GOP to use in config. Addresses #233"
This reverts commit d82dc64b93
.
This commit is contained in:
parent
d07ddd1ce2
commit
9e76687b42
@ -58,7 +58,6 @@ Some keys take *URIs* as values; these are described in the next section.
|
||||
* `SERIAL` - If set to `yes`, enable serial I/O for the bootloader.
|
||||
* `DEFAULT_ENTRY` - 1-based entry index of the entry which will be automatically selected at startup. If unspecified, it is `1`.
|
||||
* `GRAPHICS` - If set to `no`, force CGA text mode for the boot menu, else use a video mode. Ignored with Limine UEFI.
|
||||
* `GOP_INDEX` - Select which UEFI Graphics Output Protocol to use. Decimal, 0-based index. Ignored with Limine BIOS.
|
||||
* `VERBOSE` - If set to `yes`, print additional information during boot. Defaults to not verbose.
|
||||
* `RANDOMISE_MEMORY` - If set to `yes`, randomise the contents of RAM at bootup in order to find bugs related to non zeroed memory or for security reasons. This option will slow down boot time significantly. For the BIOS port of Limine, this will only randomise memory below 4GiB.
|
||||
* `RANDOMIZE_MEMORY` - Alias of `RANDOMISE_MEMORY`.
|
||||
|
@ -162,25 +162,13 @@ struct fb_info *gop_get_mode_list(size_t *count) {
|
||||
|
||||
handles = ext_mem_alloc(handles_size);
|
||||
|
||||
size_t handles_count = handles_size / sizeof(EFI_HANDLE);
|
||||
|
||||
status = gBS->LocateHandle(ByProtocol, &gop_guid, NULL, &handles_size, handles);
|
||||
if (status != EFI_SUCCESS) {
|
||||
pmm_free(handles, handles_size);
|
||||
return false;
|
||||
}
|
||||
|
||||
size_t gop_index = 0;
|
||||
char *gop_index_s = config_get_value(NULL, 0, "GOP_INDEX");
|
||||
if (gop_index_s != NULL) {
|
||||
gop_index = strtoui(gop_index_s, NULL, 10);
|
||||
}
|
||||
|
||||
if (gop_index > handles_count - 1) {
|
||||
gop_index = handles_count - 1;
|
||||
}
|
||||
|
||||
EFI_HANDLE gop_handle = handles[gop_index];
|
||||
EFI_HANDLE gop_handle = handles[0];
|
||||
pmm_free(handles, handles_size);
|
||||
|
||||
EFI_GRAPHICS_OUTPUT_PROTOCOL *gop;
|
||||
|
Loading…
Reference in New Issue
Block a user