mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-21 06:49:35 +00:00
efi: Drop all uses of efi_call_XX() wrappers
Now that GCC can generate function calls using the correct calling convention for us, we can stop using the efi_call_XX() wrappers, and just dereference the function pointers directly. This avoids the untyped variadic wrapper routines, which means better type checking for the method calls. Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
1 parent
6a080b9cde
commit
bb4aa6e06e
23 files changed
+165
-170
No files matched your search
@@ -51,16 +51,16 @@ grub_machine_init (void)
|
||||
grub_efi_uintn_t idx;
|
||||
grub_efi_init ();
|
||||
|
||||
efi_call_5 (grub_efi_system_table->boot_services->create_event,
|
||||
GRUB_EFI_EVT_TIMER, GRUB_EFI_TPL_CALLBACK, 0, 0, &event);
|
||||
grub_efi_system_table->boot_services->create_event (GRUB_EFI_EVT_TIMER,
|
||||
GRUB_EFI_TPL_CALLBACK,
|
||||
0, 0, &event);
|
||||
|
||||
before = get_itc ();
|
||||
efi_call_3 (grub_efi_system_table->boot_services->set_timer, event,
|
||||
GRUB_EFI_TIMER_RELATIVE, 200000);
|
||||
efi_call_3 (grub_efi_system_table->boot_services->wait_for_event, 1,
|
||||
&event, &idx);
|
||||
grub_efi_system_table->boot_services->set_timer (event, GRUB_EFI_TIMER_RELATIVE,
|
||||
200000);
|
||||
grub_efi_system_table->boot_services->wait_for_event (1, &event, &idx);
|
||||
after = get_itc ();
|
||||
efi_call_1 (grub_efi_system_table->boot_services->close_event, event);
|
||||
grub_efi_system_table->boot_services->close_event (event);
|
||||
divisor = (after - before + 5) / 20;
|
||||
if (divisor == 0)
|
||||
divisor = 800000;
|
||||
|
||||
Reference in new issue
Block a user