mirror of
https://git.proxmox.com/git/grub2
synced 2025-05-18 09:29:48 +00:00

xnu support * conf/i386-efi.rmk (kernel_mod_HEADERS): added i386/pit.h (pkglib_MODULES): add xnu.mod (xnu_mod_SOURCES): new variable (xnu_mod_CFLAGS): likewise (xnu_mod_LDFLAGS): likewise (xnu_mod_ASFLAGS): likewise * conf/i386-pc.rmk: likewise * conf/x86_64-efi.rmk: likewise * include/grub/efi/efi.h (grub_efi_finish_boot_services): new declaration * include/grub/i386/macho.h: new file * include/grub/i386/xnu.h: likewise * include/grub/macho.h: likewise * include/grub/machoload.h: likewise * include/grub/x86_64/macho.h: likewise * include/grub/x86_64/xnu.h: likewise * include/grub/xnu.h: likewise * kern/efi/efi.c (grub_efi_finish_boot_services): new function * kern/efi/mm.c (MAX_HEAP_SIZE): increase * loader/i386/efi/xnu.c: new file * loader/i386/pc/xnu.c: likewise * loader/i386/xnu.c: likewise * loader/i386/xnu_helper.S: likewise * loader/macho.c: likewise * loader/xnu.c: likewise * loader/xnu_resume.c: likewise * util/grub-dumpdevtree: likewise * include/grub/i386/pit.h: include grub/err.h (grub_pit_wait): export * util/grub.d/30_os-prober.in: support Darwin/Mac OS X
72 lines
2.8 KiB
C
72 lines
2.8 KiB
C
/* efi.h - declare variables and functions for EFI support */
|
|
/*
|
|
* GRUB -- GRand Unified Bootloader
|
|
* Copyright (C) 2006,2007,2008 Free Software Foundation, Inc.
|
|
*
|
|
* GRUB is free software: you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* GRUB is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with GRUB. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#ifndef GRUB_EFI_EFI_HEADER
|
|
#define GRUB_EFI_EFI_HEADER 1
|
|
|
|
#include <grub/types.h>
|
|
#include <grub/dl.h>
|
|
#include <grub/efi/api.h>
|
|
|
|
/* Functions. */
|
|
void *EXPORT_FUNC(grub_efi_locate_protocol) (grub_efi_guid_t *protocol,
|
|
void *registration);
|
|
grub_efi_handle_t *
|
|
EXPORT_FUNC(grub_efi_locate_handle) (grub_efi_locate_search_type_t search_type,
|
|
grub_efi_guid_t *protocol,
|
|
void *search_key,
|
|
grub_efi_uintn_t *num_handles);
|
|
void *EXPORT_FUNC(grub_efi_open_protocol) (grub_efi_handle_t handle,
|
|
grub_efi_guid_t *protocol,
|
|
grub_efi_uint32_t attributes);
|
|
int EXPORT_FUNC(grub_efi_set_text_mode) (int on);
|
|
void EXPORT_FUNC(grub_efi_stall) (grub_efi_uintn_t microseconds);
|
|
void *
|
|
EXPORT_FUNC(grub_efi_allocate_pages) (grub_efi_physical_address_t address,
|
|
grub_efi_uintn_t pages);
|
|
void EXPORT_FUNC(grub_efi_free_pages) (grub_efi_physical_address_t address,
|
|
grub_efi_uintn_t pages);
|
|
int
|
|
EXPORT_FUNC(grub_efi_get_memory_map) (grub_efi_uintn_t *memory_map_size,
|
|
grub_efi_memory_descriptor_t *memory_map,
|
|
grub_efi_uintn_t *map_key,
|
|
grub_efi_uintn_t *descriptor_size,
|
|
grub_efi_uint32_t *descriptor_version);
|
|
grub_efi_loaded_image_t *EXPORT_FUNC(grub_efi_get_loaded_image) (grub_efi_handle_t image_handle);
|
|
void EXPORT_FUNC(grub_efi_print_device_path) (grub_efi_device_path_t *dp);
|
|
char *EXPORT_FUNC(grub_efi_get_filename) (grub_efi_device_path_t *dp);
|
|
grub_efi_device_path_t *
|
|
EXPORT_FUNC(grub_efi_get_device_path) (grub_efi_handle_t handle);
|
|
int EXPORT_FUNC(grub_efi_exit_boot_services) (grub_efi_uintn_t map_key);
|
|
void EXPORT_FUNC (grub_reboot) (void);
|
|
void EXPORT_FUNC (grub_halt) (void);
|
|
int EXPORT_FUNC (grub_efi_finish_boot_services) (void);
|
|
|
|
void grub_efi_mm_init (void);
|
|
void grub_efi_mm_fini (void);
|
|
void grub_efi_init (void);
|
|
void grub_efi_fini (void);
|
|
void grub_efi_set_prefix (void);
|
|
|
|
/* Variables. */
|
|
extern grub_efi_system_table_t *EXPORT_VAR(grub_efi_system_table);
|
|
extern grub_efi_handle_t EXPORT_VAR(grub_efi_image_handle);
|
|
|
|
#endif /* ! GRUB_EFI_EFI_HEADER */
|