From bd0892ffd4fbb8a322f3f2f2872d8097b9dc15c9 Mon Sep 17 00:00:00 2001 From: Konstantin Belousov Date: Wed, 21 Sep 2016 10:55:28 +0000 Subject: [PATCH] Rename efi_systbl to efi_systbl_phys, the variable contains the physical address of the EFI System Table. Add _KERNEL guard around its declaration in sys/efi.h. Sponsored by: The FreeBSD Foundation MFC after: 1 week --- sys/amd64/amd64/machdep.c | 4 ++-- sys/sys/efi.h | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c index 864af76962e8..c814f6c796b6 100644 --- a/sys/amd64/amd64/machdep.c +++ b/sys/amd64/amd64/machdep.c @@ -188,7 +188,7 @@ struct msgbuf *msgbufp; * Physical address of the EFI System Table. Stashed from the metadata hints * passed into the kernel and used by the EFI code to call runtime services. */ -vm_paddr_t efi_systbl; +vm_paddr_t efi_systbl_phys; /* Intel ICH registers */ #define ICH_PMBASE 0x400 @@ -1501,7 +1501,7 @@ native_parse_preload_data(u_int64_t modulep) ksym_end = MD_FETCH(kmdp, MODINFOMD_ESYM, uintptr_t); db_fetch_ksymtab(ksym_start, ksym_end); #endif - efi_systbl = MD_FETCH(kmdp, MODINFOMD_FW_HANDLE, vm_paddr_t); + efi_systbl_phys = MD_FETCH(kmdp, MODINFOMD_FW_HANDLE, vm_paddr_t); return (kmdp); } diff --git a/sys/sys/efi.h b/sys/sys/efi.h index dda5ee7e85e0..68fc2816e494 100644 --- a/sys/sys/efi.h +++ b/sys/sys/efi.h @@ -163,5 +163,8 @@ struct efi_systbl { uint64_t st_cfgtbl; }; -extern vm_paddr_t efi_systbl; +#ifdef _KERNEL +extern vm_paddr_t efi_systbl_phys; +#endif /* _KERNEL */ + #endif /* _SYS_EFI_H_ */