arm64: Export useful functions from linux.c
Signed-off-by: Fu Wei <fu.wei@linaro.org>
This commit is contained in:
parent
cc699535e5
commit
f8451af825
5 changed files with 49 additions and 37 deletions
|
@ -23,6 +23,10 @@
|
|||
|
||||
#define GRUB_ARM64_LINUX_MAGIC 0x644d5241 /* 'ARM\x64' */
|
||||
|
||||
#define GRUB_EFI_PAGE_SHIFT 12
|
||||
#define BYTES_TO_PAGES(bytes) (((bytes) + 0xfff) >> GRUB_EFI_PAGE_SHIFT)
|
||||
#define GRUB_EFI_PE_MAGIC 0x5A4D
|
||||
|
||||
/* From linux/Documentation/arm64/booting.txt */
|
||||
struct grub_arm64_linux_kernel_header
|
||||
{
|
||||
|
@ -38,4 +42,11 @@ struct grub_arm64_linux_kernel_header
|
|||
grub_uint32_t hdr_offset; /* Offset of PE/COFF header */
|
||||
};
|
||||
|
||||
/* Declare the functions for getting dtb and checking/booting image */
|
||||
void *grub_linux_get_fdt (void);
|
||||
grub_err_t grub_arm64_uefi_check_image (struct grub_arm64_linux_kernel_header
|
||||
*lh);
|
||||
grub_err_t grub_arm64_uefi_boot_image (grub_addr_t addr, grub_size_t size,
|
||||
char *args);
|
||||
|
||||
#endif /* ! GRUB_LINUX_CPU_HEADER */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue