diff options
author | Mike Frysinger <vapier@gentoo.org> | 2021-04-24 14:02:07 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2021-05-14 01:23:06 -0400 |
commit | 64654371d6324794d11131fc95c1bc4caaaf173d (patch) | |
tree | 95a743743948415e76aba391cecc4fa68746a943 /include/sim | |
parent | 7fb6dc36bb515f39f332707b85f7e1cb5129eed8 (diff) | |
download | binutils-64654371d6324794d11131fc95c1bc4caaaf173d.zip binutils-64654371d6324794d11131fc95c1bc4caaaf173d.tar.gz binutils-64654371d6324794d11131fc95c1bc4caaaf173d.tar.bz2 |
sim: callback: inline PTR define
We require C11 now, so no need for these pre-ANSI C hacks.
PTR is simply void*, so use that directly.
Diffstat (limited to 'include/sim')
-rw-r--r-- | include/sim/ChangeLog | 5 | ||||
-rw-r--r-- | include/sim/callback.h | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/include/sim/ChangeLog b/include/sim/ChangeLog index 3098bb9..a70d8f0 100644 --- a/include/sim/ChangeLog +++ b/include/sim/ChangeLog @@ -1,5 +1,10 @@ 2021-05-14 Mike Frysinger <vapier@gentoo.org> + * callback.h (p1, p2): Change PTR to void*. + (cb_host_to_target_stat): Likewise. + +2021-05-14 Mike Frysinger <vapier@gentoo.org> + * callback.h (error): Replace __attribute__ with ATTRIBUTE_NORETURN. 2021-05-14 Mike Frysinger <vapier@gentoo.org> diff --git a/include/sim/callback.h b/include/sim/callback.h index d8dfd81..87a61df 100644 --- a/include/sim/callback.h +++ b/include/sim/callback.h @@ -249,8 +249,8 @@ typedef struct cb_syscall { int errcode; /* Working space to be used by memory read/write callbacks. */ - PTR p1; - PTR p2; + void *p1; + void *p2; long x1,x2; /* Callbacks for reading/writing memory (e.g. for read/write syscalls). @@ -320,7 +320,7 @@ const char *cb_target_str_signal (host_callback *, int); /* Translate host stat struct to target. If stat struct ptr is NULL, just compute target stat struct size. Result is size of target stat struct or 0 if error. */ -int cb_host_to_target_stat (host_callback *, const struct stat *, PTR); +int cb_host_to_target_stat (host_callback *, const struct stat *, void *); /* Translate a value to target endian. */ void cb_store_target_endian (host_callback *, char *, int, long); |