summaryrefslogtreecommitdiffstats
path: root/arch/m68k/include/asm
diff options
context:
space:
mode:
authorGreg Ungerer <gerg@linux-m68k.org>2022-04-27 15:32:15 +0200
committerGreg Ungerer <gerg@linux-m68k.org>2022-05-16 05:18:30 +0200
commit67b660b1f7e5611108e05ca97bd387e141fc61b6 (patch)
tree094527ad51e6bed9e77a385b81de64b77c6ccdb2 /arch/m68k/include/asm
parentm68knommu: implement minimal regset support (diff)
downloadlinux-67b660b1f7e5611108e05ca97bd387e141fc61b6.tar.xz
linux-67b660b1f7e5611108e05ca97bd387e141fc61b6.zip
m68knommu: add definitions to support elf_fdpic program loader
Add a few required defines to support using the binfmt_elf_fdpic loader on the m68k architecture. The values are defined to be consistent with those used on arm and sh which support this too. The most important m68k specific change is the register initialization. The pt_reg structure only contains a subset of the architecture general registers, so we are more limited than to be expected on what can be used. Signed-off-by: Greg Ungerer <gerg@linux-m68k.org>
Diffstat (limited to 'arch/m68k/include/asm')
-rw-r--r--arch/m68k/include/asm/elf.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/m68k/include/asm/elf.h b/arch/m68k/include/asm/elf.h
index 3d387ceaea3f..2def06a99b08 100644
--- a/arch/m68k/include/asm/elf.h
+++ b/arch/m68k/include/asm/elf.h
@@ -60,6 +60,13 @@ typedef struct user_m68kfp_struct elf_fpregset_t;
is actually used on ASV. */
#define ELF_PLAT_INIT(_r, load_addr) _r->a1 = 0
+#define ELF_FDPIC_PLAT_INIT(_r, _exec_map_addr, _interp_map_addr, dynamic_addr) \
+ do { \
+ (_r)->d3 = _exec_map_addr; \
+ (_r)->d4 = _interp_map_addr; \
+ (_r)->d5 = dynamic_addr; \
+ } while(0)
+
#if defined(CONFIG_SUN3) || defined(CONFIG_COLDFIRE)
#define ELF_EXEC_PAGESIZE 8192
#else
@@ -114,4 +121,6 @@ typedef struct user_m68kfp_struct elf_fpregset_t;
#define ELF_PLATFORM (NULL)
+#define ELF_FDPIC_CORE_EFLAGS 0
+
#endif