mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-23 01:37:44 +00:00
hv: further fix to configurable relocatoin
commit ia23549aa915e7dc2c ("build: make relocation-related code configurable") adds CONFIG_RELOC to make relocation configurable This patch corrects the behavior when CONFIG_RELOC is disabled - Don't use "CFLAGS += -fpie" and put back "LDFLAGS += -static" - __emalloc(): forced to allocate exactly the asked address, which is CONFIG_RAM_START
This commit is contained in:
@@ -268,7 +268,11 @@ EFI_STATUS __emalloc(UINTN size, UINTN min_addr, EFI_PHYSICAL_ADDRESS *addr,
|
||||
continue;
|
||||
}
|
||||
|
||||
#ifndef CONFIG_RELOC
|
||||
aligned = start;
|
||||
#else
|
||||
aligned = min_addr;
|
||||
#endif
|
||||
err = allocate_pages(AllocateAddress, mem_type,
|
||||
nr_pages, &aligned);
|
||||
if (err == EFI_SUCCESS) {
|
||||
|
Reference in New Issue
Block a user