Fix EFI compilation
This commit is contained in:
parent
27a8ee52b4
commit
731ffd8773
1 changed files with 32 additions and 4 deletions
|
@ -693,13 +693,41 @@ grub_cmd_linux (grub_command_t cmd __attribute__ ((unused)),
|
|||
params->ext_mem = ((32 * 0x100000) >> 10);
|
||||
params->alt_mem = ((32 * 0x100000) >> 10);
|
||||
|
||||
params->video_cursor_x = grub_getxy () >> 8;
|
||||
params->video_cursor_y = grub_getxy () & 0xff;
|
||||
{
|
||||
grub_term_output_t term;
|
||||
int found = 0;
|
||||
FOR_ACTIVE_TERM_OUTPUTS(term)
|
||||
if (grub_strcmp (term->name, "vga_text") == 0)
|
||||
{
|
||||
grub_uint16_t pos = grub_term_getxy (term);
|
||||
params->video_cursor_x = pos >> 8;
|
||||
params->video_cursor_y = pos & 0xff;
|
||||
params->video_width = grub_term_width (term);
|
||||
params->video_height = grub_term_height (term);
|
||||
found = 1;
|
||||
}
|
||||
if (!found)
|
||||
FOR_ACTIVE_TERM_OUTPUTS(term)
|
||||
if (grub_strcmp (term->name, "console") == 0)
|
||||
{
|
||||
grub_uint16_t pos = grub_term_getxy (term);
|
||||
params->video_cursor_x = pos >> 8;
|
||||
params->video_cursor_y = pos & 0xff;
|
||||
params->video_width = grub_term_width (term);
|
||||
params->video_height = grub_term_height (term);
|
||||
found = 1;
|
||||
}
|
||||
if (!found)
|
||||
{
|
||||
params->video_cursor_x = 0;
|
||||
params->video_cursor_y = 0;
|
||||
params->video_width = 80;
|
||||
params->video_height = 25;
|
||||
}
|
||||
}
|
||||
params->video_page = 0; /* ??? */
|
||||
params->video_mode = grub_efi_system_table->con_out->mode->mode;
|
||||
params->video_width = (grub_getwh () >> 8);
|
||||
params->video_ega_bx = 0;
|
||||
params->video_height = (grub_getwh () & 0xff);
|
||||
params->have_vga = 0;
|
||||
params->font_size = 16; /* XXX */
|
||||
|
||||
|
|
Loading…
Reference in a new issue