OSDN Git Service

m68k: fix bFLT executable running on MMU enabled systems
authorGreg Ungerer <gerg@linux-m68k.org>
Thu, 21 Jul 2016 06:28:48 +0000 (16:28 +1000)
committerGreg Ungerer <gerg@linux-m68k.org>
Mon, 25 Jul 2016 04:40:28 +0000 (14:40 +1000)
commit89e6ffd9f03936d9f6f0332426e4a3cf379b90bd
tree0a889cd15af53bece41ba4997111809fa3f4be73
parent47ef4ad2684d380dd6d596140fb79395115c3950
m68k: fix bFLT executable running on MMU enabled systems

Even after recent changes to support running flat format executables on
MMU enabled systems (by nicolas.pitre@linaro.org) they still failed to
run on m68k/ColdFire MMU enabled systems. On trying to run a flat format
binary the application would immediately crash with a SIGSEGV.

Code to setup the D5 register with the base of the application data
region was only in the non-MMU code path, so it was not being set for
the MMU enabled case. Flat binaries on m68k/ColdFire use this to support
GOT/PIC flat built application code.

Fix this so that D5 is always setup when loading/running a bFLT executable
on m68k systems.

Signed-off-by: Greg Ungerer <gerg@linux-m68k.org>
arch/m68k/include/asm/flat.h
arch/m68k/include/asm/processor.h