aboutsummaryrefslogtreecommitdiff
path: root/sim/moxie
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-11-28 00:18:18 -0500
committerMike Frysinger <vapier@gentoo.org>2021-11-28 13:23:58 -0500
commite38330f8b00e641e397260e9cecb2070ac2d1477 (patch)
treec90b41f37cd4f9fd1139c8336ac0042d84d862da /sim/moxie
parent64ae70dde5bc8916800bbdb570d6281b700f7e84 (diff)
downloadfsf-binutils-gdb-e38330f8b00e641e397260e9cecb2070ac2d1477.zip
fsf-binutils-gdb-e38330f8b00e641e397260e9cecb2070ac2d1477.tar.gz
fsf-binutils-gdb-e38330f8b00e641e397260e9cecb2070ac2d1477.tar.bz2
sim: iq2000/lm32/m32c/moxie/rx: switch to new target-newlib-syscall.h
Use the new target-newlib-syscall.h to provide the target syscall defines. These code paths are written specifically for the newlib ABI rather than being generalized, so switching them to the defines rather than trying to go through the dynamic callback conversion seems like the best trade-off for now. Might have to reconsider this in the future.
Diffstat (limited to 'sim/moxie')
-rw-r--r--sim/moxie/interp.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sim/moxie/interp.c b/sim/moxie/interp.c
index 3aa6a3b..228e23c 100644
--- a/sim/moxie/interp.c
+++ b/sim/moxie/interp.c
@@ -35,7 +35,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include "sim-options.h"
#include "sim-io.h"
#include "sim-signal.h"
-#include "targ-vals.h"
+#include "target-newlib-syscall.h"
typedef int word;
typedef unsigned int uword;
@@ -935,13 +935,13 @@ sim_engine_run (SIM_DESC sd,
cpu.asregs.sregs[3] = inum;
switch (inum)
{
- case TARGET_SYS_exit:
+ case TARGET_NEWLIB_SYS_exit:
{
sim_engine_halt (sd, scpu, NULL, pc, sim_exited,
cpu.asregs.regs[2]);
break;
}
- case TARGET_SYS_open:
+ case TARGET_NEWLIB_SYS_open:
{
char fname[1024];
int mode = (int) convert_target_flags ((unsigned) cpu.asregs.regs[3]);
@@ -954,7 +954,7 @@ sim_engine_run (SIM_DESC sd,
cpu.asregs.regs[2] = fd;
break;
}
- case TARGET_SYS_read:
+ case TARGET_NEWLIB_SYS_read:
{
int fd = cpu.asregs.regs[2];
unsigned len = (unsigned) cpu.asregs.regs[4];
@@ -965,7 +965,7 @@ sim_engine_run (SIM_DESC sd,
free (buf);
break;
}
- case TARGET_SYS_write:
+ case TARGET_NEWLIB_SYS_write:
{
char *str;
/* String length is at 0x12($fp) */
@@ -978,7 +978,7 @@ sim_engine_run (SIM_DESC sd,
cpu.asregs.regs[2] = count;
break;
}
- case TARGET_SYS_unlink:
+ case TARGET_NEWLIB_SYS_unlink:
{
char fname[1024];
int fd;