Re: [RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-10 Thread Richard Henderson
On 11/10/21 5:20 PM, Warner Losh wrote: Although I think we can fairly safely drop HAVE_SAFE_SYSCALL.  It is required for proper operation.  As with host-signal.h, really. Yes. The only possible use I can see for it is to allow people to bring up new platforms

Re: [RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-10 Thread Warner Losh
On Mon, Nov 8, 2021 at 9:39 AM Warner Losh wrote: > > > On Mon, Nov 8, 2021 at 8:07 AM Richard Henderson < > richard.hender...@linaro.org> wrote: > >> On 11/8/21 3:37 AM, Warner Losh wrote: >> > All instances of rewind_if_in_safe_syscall are the same, differing only >> > in how the instruction

Re: [RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-10 Thread Philippe Mathieu-Daudé
On 11/8/21 03:37, Warner Losh wrote: > All instances of rewind_if_in_safe_syscall are the same, differing only > in how the instruction point is fetched from the ucontext and the size > of the registers. Use host_signal_pc and new host_signal_set_pc > interfaces to fetch the pointer to the PC and

Re: [RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-08 Thread Warner Losh
On Mon, Nov 8, 2021 at 8:07 AM Richard Henderson < richard.hender...@linaro.org> wrote: > On 11/8/21 3:37 AM, Warner Losh wrote: > > All instances of rewind_if_in_safe_syscall are the same, differing only > > in how the instruction point is fetched from the ucontext and the size > > of the

Re: [RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-08 Thread Richard Henderson
On 11/8/21 3:37 AM, Warner Losh wrote: All instances of rewind_if_in_safe_syscall are the same, differing only in how the instruction point is fetched from the ucontext and the size of the registers. Use host_signal_pc and new host_signal_set_pc interfaces to fetch the pointer to the PC and

[RFC 2/4] linux-user/signal.c: Create a common rewind_if_in_safe_syscall

2021-11-07 Thread Warner Losh
All instances of rewind_if_in_safe_syscall are the same, differing only in how the instruction point is fetched from the ucontext and the size of the registers. Use host_signal_pc and new host_signal_set_pc interfaces to fetch the pointer to the PC and adjust if needed. Delete all the old copies