x86: 32-bit: set ENTRY properly

The entry point is at a physical memory location; use the
physical instead of virtual address of the start symbol.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2020-07-29 18:24:53 -07:00 committed by Anas Nashif
commit 4c7bde4311

View file

@ -40,6 +40,7 @@
#include <linker/linker-defs.h>
#include <offsets.h>
#include <sys/util.h>
#include <sys/mem_manage.h>
#include <linker/linker-tool.h>
@ -67,7 +68,8 @@
#define MMU_PAGE_ALIGN_PERM
#endif
ENTRY(CONFIG_KERNEL_ENTRY)
epoint = Z_MEM_PHYS_ADDR(CONFIG_KERNEL_ENTRY);
ENTRY(epoint)
/* SECTIONS definitions */
SECTIONS
@ -106,8 +108,9 @@ SECTIONS
*/
#include <snippets-rom-start.ld>
*(.text_start)
*(".text_start.*")
/* Needs KEEP() as ENTRY() is given a physical address */
KEEP(*(.text_start))
KEEP(*(".text_start.*"))
*(.text)
*(".text.*")
*(.gnu.linkonce.t.*)